I'm working with the managers and realize it's still in flux, but the
documentation doesn't mention that you have to put the
"torque.managers..." in your TurbineResources.properties file.
I'll submit a patch for adding it to the documentation, but I want to
make sure I'm using all of the manager stuff correctly. Until then,
here's a patch that at least logs an error message when a user tries
using a manager that isn't configured.
I might explore moving this from the configuration file to the OM
objects. E.g. instead of calling Torque.getManager() the base
object/peer has a default manager which can be over-ridden in the
extension class. Does this sound like a good idea?
Thanks,
Stephen
cvs diff src\java\org\apache\torque\Torque.java (in directory
C:\cvs\jakarta-turbine-torque\)
Index: src/java/org/apache/torque/Torque.java
===================================================================
RCS file:
/home/cvspublic/jakarta-turbine-torque/src/java/org/apache/torque/Torque.java,v
retrieving revision 1.61
diff -r1.61 Torque.java
597a598
> * @throws TorqueException if there is not a configured manager for the name
602c603,608
< return (AbstractBaseManager) managers.get(name);
---
> AbstractBaseManager m = (AbstractBaseManager) managers.get(name);
> if (m == null)
> {
> category.error("No configured manager for key " + name + ".");
> }
> return m;
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>