wcf - Service Oriented Architecture and evolving objects shared between applications -
i'm begin writing suite of wcf services variety of business applications. soa immature begin , evolve strong middle-ware layer.
unfortunately not have luxury of writing full set of services , re-factoring applications use them, iterative process done on time. question have around evolving (changing, adding, removing properties) business objects.
for example: if have soa exposing service returns obj1. service being consumed app1, app2, app3. imagine object changed app1, don't want have update app2 , app3 changes made app1. if change add property work fine, not mapped happens when remove property? or change property string int? how manage change?
thanks in advance help?
ps: did little picture apparently need reputation of 10 have use imagination...
the goal limit changes force clients have make immediately. may have make changes, under unavoidable circumstances multiple versions behind , phasing out altogether.
non-breaking changes can be:
- adding optional properties
- adding new operations
breaking changes include:
- adding required properties
- removing properties
- changing data types of properties
- changing name of properties
- removing operations
- renaming operations
- changing order of properties if explicitly specified
- changing bindings
- changing service namespace
- changing meaning of operation. mean this, example, if operation returned records changed return records. break clients expected response.
options:
- add new operation handle updated properties , logic. modify code behind original operation set new properties , refactor service logic if can. remember not change meaning of operation.
- if wanting remove operation no longer want support. forcing client have change @ point. add documentation in wsdl let client know being deprecated. if letting client use contract dll use [obsolete] attribute (it not generated in final wsdl that's why can't use all)
- if big change altogether, new version of service and/or interface , endpoint can created easily. ie v2, v3, etc. can have clients upgrade new version when time right
here flowchart “apress - pro wcf4: practical microsoft soa implementation” may help.
Comments
Post a Comment