Thanks to Jean-Baptiste on the dev list...
OK, now I realise what I missed (bangs head on monitor!)
The datasource is called as follows from flow:
function getIndDB() { if (indDatabase == null) { this.indDatabase = new IndDB("inddb"); //get from the cocoon.xconf file } return indDatabase; } and in the cocoon.xconf file I have: <jdbc name="inddb_user"> <!-- should match name in flow --> <pool-controller min="5" max="50"/> <auto-commit>true</auto-commit> <dburl>jdbc:mysql://localhost:3306/indicators</dburl> <user>user</user> <password>password</password> </jdbc> The problem was that on my development machine
I *also* had an entry: <jdbc name="inddb">
<pool-controller min="5" max="50"/> <auto-commit>true</auto-commit> <dburl>jdbc:mysql://localhost:3306/indicators</dburl> <user>user</user> <password>password</password> </jdbc> So the development machine worked (two datasources)
but the target machine did not (wrong datasource). >>> [EMAIL PROTECTED] 2006/01/30 01:36 PM >>> So far no helpful ideas on this problem...
I really need help interpreting what the error means, and what the likely cause could be? The best idea seems to be: "Key-to-component mappings are generally defined in cocoon.xconf." What key-to-component mapping is likely to be on my development PC but not be on the server, and therefore contributing to the problem? Thanks Derek PS Please note that I can read data from my target datasource with SQLTransformer; its just flow that seems problematic... >>> [EMAIL PROTECTED] 2006/01/23 04:48 PM >>> Jason Johnston wrote: > Derek Hohls wrote: > >> I have an app that works fine on a development machine >> (Cocoon 2.1.5, WindowsXP, Tomcat 4.1.x, JDK 1.4.x) >> >> But when I upload it and try and run it on the server: >> (Cocoon 2.1.5, UNIX, Tomcat 4.1.x, JDK 1.4.x) >> >> I get the error: >> >> ERROR (2006-01-23) 11:38.25:783 [sitemap.handled-errors] >> (/cocoon215/inddb/db/editUser.do) Thread-20/PipelineNode: >> "resource://org/apache/cocoon/components/flow/_javascript_/Database.js", >> line 33: uncaught _javascript_ exception: at editUser >> (file:/opt/jakarta-tomcat-4.1.18/webapps/cocoon215/inddb/script/user.js, >> Line 46) >> at >> (file:/opt/jakarta-tomcat-4.1.18/webapps/cocoon215/inddb/script/user.js, >> Line 6) >> at >> (resource://org/apache/cocoon/components/flow/_javascript_/Database.js, >> Line 33): >> org.apache.avalon.framework.service.ServiceException: datasources: >> ComponentSelector could not find the component for hint [inddb] (key >> [inddb]) >> (Key='org.apache.avalon.excalibur.datasource.DataSourceComponentSelector/inddb') >> >> >> How to interpret the "ComponentSelector could not find the component" >> error message - what is the software looking for?? > > > This means it is trying to look up the Avalon component for that key, > and failing for some reason. Key-to-component mappings are generally > defined in cocoon.xconf. > >> >> (I am also not sure where the : >> org/apache/cocoon/components/flow/_javascript_/Database.js >> file is located... its not under WEB-INF/classes/... ?) > > > Doing a quick search it looks like Database.js is part of the Petstore > sample block: > /src/blocks/petstore/trunk/java/org/apache/cocoon/components/flow/_javascript_/Database.js > > > Is your application perhaps relying on this file for some reason, but > the Petstore block didn't get built in the version on your server? Bah, nevermind that, of course the file is there if the error is occurring within it. ;-) My guess now is that your datasource configuration from cocoon.xconf did not get copied over to the server. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- This message is subject to the CSIR's copyright, terms and conditions and e-mail legal notice. Views expressed herein do not necessarily represent the views of the CSIR. CSIR E-mail Legal Notice http://mail.csir.co.za/CSIR_eMail_Legal_Notice.html CSIR Copyright, Terms and Conditions http://mail.csir.co.za/CSIR_Copyright.html For electronic copies of the CSIR Copyright, Terms and Conditions and the CSIR Legal Notice send a blank message with REQUEST LEGAL in the subject line to [EMAIL PROTECTED] This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- This message is subject to the CSIR's copyright, terms and conditions and e-mail legal notice. Views expressed herein do not necessarily represent the views of the CSIR. CSIR E-mail Legal Notice CSIR Copyright, Terms and Conditions For electronic copies of the CSIR Copyright, Terms and Conditions and the CSIR Legal Notice send a blank message with "REQUEST LEGAL" in the subject line to CSIR HelpDesk
|