db-torque-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thomas Fischer <tfisc...@apache.org>
Subject initialisation of id brokers
Date Sat, 04 Mar 2006 14:44:52 GMT
Hi everybody,

I have tried to resolve the bug
which says that no IDBroker thread should be started if it is 
not needed. IdBrokers live in the Database Map, but the IdMethod can be 
set per table. The information whether a 
table's idMethod is IdBroker is only available when its TableMap is 
available, which is created upon loading of the corresponding Peer class. 
So when a DatabaseMap is created, it is not known whether an IdBroker is 
needed because it is not sure that all Peer classes are loaded (in almost 
all cases, they are not loaded). So the solution until now was to start an 
IdBroker thread for all Database Maps, whether needed or not.
I'd like to change that behaviour to the following: When a Peer class is 
loaded, it checks whether its IdMethod is IdBroker. If yes, it prompts the 
DatabaseMap to start an IdBroker if there is not already one started.

Does anybody see any drawbacks / faults in this ?


To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org

View raw message