Target - Catalog desgin solutions for web services Aims to produce design concepts in reference servicesDescribe patterns known to recurring problems
splitted on seven parts
why use:Web services are easy to use and to share with various types of applicationscan be independent of technologyhow to reduce Coupling:forms of coupling que service designers must consider.Function coupling, Data structure coupling: Temporal coupling: coupling URI:
API -RPC: when you define a URL with remote procedures with fixed set of elements and cliente callMESSAGES API: are defined messages and these messages execute specific tasks, the serverr examine the contents and execute the correct procedureRESOURCES API: you define urls with procedures that can return many of media type, status,codes
this chapter presents fundaments design patterns regardless API stylelearn when use and why
The classic request/responseRequest/ Acknowledge - when a request is process on backgroung and is recived by unique request identifier on other momentMedia Type Negotiation - for receive the response on diferents formatsLinked Service – this pattern return other url
Request and ResponseManagementThischapter identifies the common Service Layer entities that areused to manage web requests and responses.
Servicecontroler - works with routung of the expressions or callsData Transfer Object - Distinct classes to represent request and response data structures.Request Mapper - mapper based on key content found in the request.Response Mapper - mapper based on key content found in the response.
This chapter looks at the ramifications of the ORM ( Object Relational Mapper) and direct calls to legacy API
TS – Pattern for Write custom logic for database access,DS - this pattern show how a web service provide access to internal resources like database with a minimum amount of custom codeOP- talk about how reuse common domain logic without duplicating codeCI - how use diferents APIs and how can you process request synchronousand asynchronous
this chapter talke about the basic infrastructure concerns pertinet to client and server developers
SC - talk about high-level interface that abstracts the details of this logic, thereby making the classes easier to use.SD-Produce a standardized and machinereadable description of related servicesand usage policies.ASY -talk about how a client avoid blocking when sending a requestSI -how Encapsulate cross-cutting behaviors within individual classes.IR – talk about how ensure that requests are delivered to a web service despite temporary network or server failures.
WEB service EvolutionThis chapter reviews the factors that cause clients to break and discusses two common versioning strategies.
• Moving services to different domains• Changing the URI patterns clients use to address services* Structural changes to media types or messages• And Service Descriptor changes
* Removing or renaming qualified elements or attributes• Changing the data types of qualified elements or attributes• Changing elements or attributes from being optional to being required• Changing the order in which elements occur in a data structure• Changing the hierarchical relationships between complex data structures
SMA- each service operation should receives a single message parameter thatcontains all of the data for a request.DS-how Append optional data toexisting request and responsedata structuresTR- you should Design the client or service to extract only what is needed, ignore unknown contentCDC- its a good idea developers write integration tests that express the client’s expectations of a service AP