Jan 7th, 2009, 07:31 AM
Dynamically exporting services using HTTP Invoker
I'm currently exposing some services using Spring's HTTP Invoker Service Exporter..
I have a few situations where the service may not be available at start but subsequently, based on several availability criteria, the service becomes available.
How can I export the service when the web-container has been initialized?
Jan 20th, 2009, 12:16 PM
Though a bit late reply, but I think in your service implementation class you could check if a request can be processed when a service operation is invoked. If a request can not be serviced by your bean, e.g. due to some resources not available, then respond accordingly - perhaps by throwing an exception to the client.
As long as Spring can initialize your service bean, you should be good. Initializing a bean doesn't have to guarantee service-readiness by the bean (again, it depends on your requirements too).
Tags for this Thread