On 01/02/2013 01:13, Danny Coward wrote:
> * Client API implementation bootstrapping
> (http://java.net/jira/browse/WEBSOCKET_SPEC-83)
>
> Currently (as a stopgap) the ContainerProvider API has used an
> undocumented system property to load the implementation class under
> getWebSocketContainer(). Instead, I'm planning on switching this over to
> use the ServiceLoader.load() mechanism. So provided the API classloader
> can see a JAR containing the appropriate Manifest, the runtime will load
> the implementation class. I don't think this should be controversial,
> but I have a dim memory that this came up before, so I am putting it out
> there in case I've missed something.
I think I mentioned this before but I suggest looking at how the EL spec
does this and using the same approach . It is the same situation (may be
used stand-alone or in a container) and provides a way for multiple
implementations to sit alongside one another and for the developer to
choose which one they want to use.
Mark