I sympathize on the double init issue.. When I was writing the compositeconfig object, I learned the hard way that the order of component inialization was important, but it was very hard to find. I think what we need is to patch Turbine so that it hands back a more informative error. Even something like "It appears that your initialization of components is bad" would help!
If you want to provide a patch, I'll provide a unit test! Eric > -----Original Message----- > From: David Wynter [mailto:[EMAIL PROTECTED] > Sent: Saturday, September 06, 2003 1:51 PM > To: Turbine Users List > Subject: RE: Torque as an Avalon Component [was: Re: Turbine Error] > > > Hi, > > The Avalon support in Turbine appears to cause some very > difficult to find > problems. In my case I have a Avalon component that uses the Quartz > scheduler. When I configure it incorrectly for datasource it > fails in the > initialization of that component but does not catch the > exception thrown by > the component. So you have to trace all the way down through > Excalibur into > your component config and init to work out what is going on. > In my case the > Quartz component is throwing an SQLException when the Quartz > PoolingConnectionProvider class calls into the commons dbcp. > > public Connection getConnection() throws SQLException > { > return this.datasource.getConnection(); > } > > Which throws to a couple of Quartz methods until > recoverjobs() throws a > JobPersistenceException which is not caught by anything and > you are thrown > out completely with no idea what happened. A problem with > Quartz 1.1.6 I > realize. > > The point being that you are exposed to your components > weaknesses. Also > because of the design of Turbine that you can end up with a double > initialization just because a component failed to init. To > reproduce, you > need a component that does not catch an exception it throws > during init, > then put a breakpoint on line 230 of turbine.java. Step over > this line, it > will never return. > > It seems that the apache CVS server does not support the -D > option so I can > get the source code for commons-pool and commons-dbcp that is > being used > (2003-08-25 20:45). Will have to try mocking up a use for > dbcp in Turbine to > use the properties I am using for my Quartz setup. > > Not sure what can be done about this fragile Avalon support? > > David > > > -----Original Message----- > > From: Henning Schmiedehausen [mailto:[EMAIL PROTECTED] > > Sent: 05 September 2003 16:49 > > To: Turbine Users List > > Subject: RE: Torque as an Avalon Component [was: Re: Turbine Error] > > > > > > On Thu, 2003-09-04 at 21:13, David Wynter wrote: > > > > [...] > > > etc. up to 100 errors before it craps out. Just checked > it again and it > > > behaves exactly the same. > > > > > > Then I had a look and found that it had copied the entire src > > tree into the > > > target tree. > > > > No. You didn't look close enough. Copying the tree from src/java to > > target/src is a necessary first step to actually compile the tree. > > Because the tree in target/src does not only contain the > classes from > > src/java but also some additional files and especially the torque > > generated peers. The tree from src/java simply does not compile > > standalone as all the "I want to use a graphical IDE and > not stinking > > maven" users noticed pretty fast. ;-) > > > > >From looking at the error messages, it seems to me that you did > > completely broke the build process by doing changes to the > tree when you > > didn't actually understand how it is built. As it broke, > you're free to > > keep both pieces. ;-) > > > > > > > > So then I pointed to the src but used the jar downloaded > for JDK 1.4.2 > > > (which I have switched to from 1.4.1_01 to be able to use the > > ready built > > > jar). Still no joy with my TorqueComponent.configure problem. > > Interestingly > > > I have another directory with HEAD (2.4 dev) in it and it > > builds fine on the > > > same PC. > > > > You can use the JDK 1.3 or the 1.4 jar with JSDK 1.4.1_01. > It is only, > > that you should _not_ use the JDK 1.4.2 jar with JDK 1.3. I'm sorry, > > this should be more clear on the download site. I will fix this up. > > > > > Now I am the point where the Avalon components load and > > configure OK but I > > > have exactly the same problem as Jurgen, see his email and my > > last one for > > > details. > > > > > > That adds up to about 3 days work, bit at least I am > closer now and know > > > more about Avalon. I am on W2K server > > > > I'm working exclusively on Linux, but actually I got a > decent (> 2 GHz) > > Windows system yesterday, so I will give it a spin to see if I can > > reproduce the error. If yes, expect a patch till sunday. > > > > Regards > > Henning > > > > > > -- > > Dipl.-Inf. (Univ.) Henning P. Schmiedehausen INTERMETA GmbH > > [EMAIL PROTECTED] +49 9131 50 654 0 http://www.intermeta.de/ > > > > Java, perl, Solaris, Linux, xSP Consulting, Web Services > > freelance consultant -- Jakarta Turbine Development -- > hero for hire > > > > "Dominate!! Dominate!! Eat your young and aggregate! I have > > grotty silicon!" > > -- AOL CD when played backwards (User Friendly - 200-10-15) > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: > [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
