I'm trying to establish the mutability needs of the [Keyed]ObjectPoolFactory implementations, i.e.
Generic[Keyed]ObjectPoolFactory I've looked at DBCP 1.4, which uses POOL 1.x. DBCP 1.4 currently creates an instance of GenericKeyedObjectPoolFactory, which it then uses via the interface KeyedObjectPoolFactory. [This is in the class BasicDataSource.] The additional GKOPF getters, and the protected mutable variables are not actually used by DBCP; it only needs to create the instance of KeyedObjectPoolFactory. There is no indication that DBCP needs to change or even inspect the factory settings once it is created. The factory setters were added in POOL2; if they were not needed for DBCP in POOL 1.X, so are they really needed in POOL 2.x? I already removed them as part of making the classes thread-safe; the question is, are the setters now needed in POOL 2? If so, they can be restored, but synch./volatile will need to be added, as I assume the factories must be thread-safe. Indeed, are the getters even needed? The Pool 1.x code did provide getters, but AFAICT they were not used by DBCP. The calling code knows what it used to create the factory, and the factory is subsequently used as an instance of the interface - which only provides the createPool() method. Is there really a need for other code to find out what the original factory settings were? Can the getters be removed? Do the setters have to be restored? --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org For additional commands, e-mail: dev-h...@commons.apache.org