[jboss-as7-dev] Missing dependencies in Web & EJB3 AS7 modules

Alessio Soldano asoldano at redhat.com
Tue Feb 15 15:25:09 EST 2011


On 02/15/2011 05:26 PM, Jason T. Greene wrote:
> In pricipal user code should only need to import an API. Then the
> container impl takes care of passing a ref that is castable to the API.
> The one exception is of course, static factories, which are more complex
> to solve. I assume thats why we have service loader imports on those.
Sorry, while I agree on the general idea of limiting as much as possible 
the implementation details user code can see, I'm still missing what's 
the exact boundary between what we're going / want to hide and what is 
to be visible. Yes, API (jaxws, jws, saaj, jaxb, ...) should be visible, 
so far so good. Let's assume we add them (if they're not there yet) for 
all ejb3 & servlet deployments through a DUP that does

 > deploymentUnit.addToAttachmentList(Attachments.MODULE_DEPENDENCIES, 
new ModuleDependency(moduleLoader, moduleIdentifier, ...));

Then, once the user tries to create a JAXWS client, he basically goes 
through the javax.xml.ws.spi.Provider class that act as a service 
loader, looking for the a property named the same as the class and 
return the implementation specified in the property. In our 
(jbossws-cxf) case, that a class living in jbossws-cxf-client, that of 
course heavily leverage Apache CXF (which is all in a single module -at 
least for now- included in the jbossws-cxf-client dependencies). Let's 
assume for now the user is not allowed to use any jbossws and/or cxf 
specific stuff, just the standard jaxws/jws/etc. api; as far as I 
understand, at a minimum, we'd need the jbossws-cxf-client module to be 
added the same as above, so that it contributes to defining the module 
classloader, which will later be visible to the user. Is this correct / 
is there a better approach / solution ? (this is of course just an 
example of many similar issues)

> We should keep in the back of our mind that users may want to override
> this, and go with some different JAX-WS client (sacraficing EE
> integration features).
mmh... override at what level? changing module dependencies?

>   Until we have the custom classloading deployment
> config its hard to say how this will be accomplished.
when is this planned to be worked / in which release/milestone ?
Thanks

-- 
Alessio Soldano
Web Service Lead, JBoss




More information about the jboss-as7-dev mailing list