Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

You can browse the source code for service context over here.

Service Context

A service context captures the service request context. It is created when a request is received in the CollectionSpace service layer. The service layer populates the service context with the meta data for the service for the tenant that is invoking the request as well as request context.

If the service consumer (of e.g. vocabulary service) is another CollectionSpace service (e.g. collectionobjects) colocated in the same server, a local service context is created. If the service consumer is invoking the service using RESTful APIs remotely, a remote service context is created. The remote service context also provides utility functions to unmarshall the multipart request as well as to marshal the multipart response. It is possible to create a local service context from the remote context in case the service receiving the request is calling another CollectionSpace service locally.

Following diagram shows the ServiceContext hierarchy.

Unknown macro: {gliffy}

Source could be found here : ServiceContext.java.

  • No labels