In what a sense? In the current realization, a pojo read the configuration from a database and lunch a thread for each webservice exposing a new endpoint (the website is always the same, what is changing is only the webserver name and tcp port).
What i'd like to do is us an application server glassfish to do some similar, for example instantiating a new session bean for each endpoint.
Sorry if I am a little slow, but I am still trying to figure out what is different about these custom webservices that the client can request.
It sounds like a RESTful architecture because the URL designates a resource, but apparently the resource is a named SOAP message handler.
A "root" servlet that gets all requests could look at the URL and decide if it already knows this name - if so locate instance of the SOAP handler and forward the request and response objects. If it does not recognize the name, create a new instance (with some custom parameters?), remember the name and instance, and forward the request and response.
No problem, It's me. My English is poor and I can't exlpain the problem very well, so thanks for the effort.
What I'm doing is:
1) read the configuration from a database (where the user enter the endpoints needed for accept incoming messages)
2) foreach endpoint needed, istantiate a new javax.xml.ws.Endpoint with Endpoint.create(SOAPBinding.SOAP11HTTP_BINDING, implementator);
implementor is a @WebService annotated java class corresponding to the wsdl I want to expose, initialized through an init(Configuration configurationFromPoint1)
3) publish the endpoint calling e.publish("DESIDERED URL READ FROM POINT 1)");
4) when the webservice receive a message (the client call the webservice) the webservice store the message and the parameters stored in configuration.
All this work but in a J2SE6 environment.
I'm wandering how to realize the same in a J2EE environment using JTA, JPA, EJBs and so on...
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop