On 17/03/2015 12:21, Clebert wrote:
> I didn't propose a static method. I just proposed a factory similar to what Jdbc uses. You use the class loader to
> load the class and use it non statically. Just like Jdbc.
>
You proposed
>>> JMSDriver dirver = Class.forName("MyProvider");
>>> ConnectionFactory factory = driver.newConnectionFactory(connectionString / URI / something we all agree upon);
which means newConnectionFactory has to be a static method.
All the methods on javax.sql.DriverManager are static.
I'm not saying this is a bad thing, but I'd like to understand why we need to introduce another level of
provider-specific factory. The main benefit I can see is that allows the provider to choose the connection factory
implementation class depending on the specified properties. Is that a requirement?
Nigel