Hi,
Seem to be having a small problem accessing some data stored in a back end mysql data without much usable logging ( this with 4.2 CE) from the log file I get 2013-06-28 13:38:09,587 ERROR PageFlowControllerProcessor - error caught {controller: "oxf:/apps/location-info/page-flow.xml", m ethod: "GET", path: "/location-info/"} 2013-06-28 13:38:09,842 ERROR PageFlowControllerProcessor - +----------------------------------------------------------------------------------------------------------------------+ |An Error has Occurred | |----------------------------------------------------------------------------------------------------------------------| |No suitable driver | |----------------------------------------------------------------------------------------------------------------------| |Application Call Stack | |----------------------------------------------------------------------------------------------------------------------| |oxf:/apps/location-info/test.xpl | 32| | | |oxf:/apps/location-info/test.xpl | 32| | | |oxf:/apps/location-info/test.xpl | 49| 65|reading processor output | |oxf:/apps/location-info/test.xpl | 54| 45|reading processor output | |oxf:/apps/location-info/page-flow.xml | 8| 73|reading page model data output | |oxf:/apps/location-info/page-flow.xml | 8| 73|reading page view data output | |----------------------------------------------------------------------------------------------------------------------| |Exception: java.sql.SQLException | |----------------------------------------------------------------------------------------------------------------------| |java.sql.DriverManager |getDriver |DriverManager.java | 279| |org.apache.commons.dbcp.BasicDataSource |createConnectionFactory |BasicDataSource.java |1437| |----------------------------------------------------------------------------------------------------------------------| |Exception: org.apache.commons.dbcp.SQLNestedException | |----------------------------------------------------------------------------------------------------------------------| |org.apache.commons.dbcp.BasicDataSource |createConnectionFactory |BasicDataSource.java |1452| |org.apache.commons.dbcp.BasicDataSource |createDataSource |BasicDataSource.java |1371| |org.apache.commons.dbcp.BasicDataSource |getConnection |BasicDataSource.java |1044| |org.orbeon.oxf.processor.DatabaseContext |getConnection |DatabaseContext.java | 60| |----------------------------------------------------------------------------------------------------------------------| So … in /etc/tomcat6/server.xml I've got <Resource name="jdbc/mysql" auth="Container" type="javax.sql.DataSource" initialSize="3" maxActive="10" maxIdle="20" maxWait="30000" driverClassName="com.mysql.jdbc.Driver" poolPreparedStatements="true" username="something" password="something else" url="jdbc:mysql://144.32.126.92:3306/freeradius"/> In /var/lib/tomcat6/xformapps/orbeon-4.2/WEB-INF/web.xml I've got <resource-ref> <description>FreeRadius DB Connection</description> <res-ref-name>jdbc/freeradius</res-ref-name> <res-type>javax.sql.DataSource</res-type> <res-auth>Container</res-auth> </resource-ref> /var/lib/tomcat6/common/lib has mysql-connector-java-5.1.25-bin.jar in it and I've restarted the server In my forms app page-flow.xml has <page path-info="/location-info/" model="test.xpl" view="entry.xsl"> and test.xpl has <p:config xmlns:p="http://www.orbeon.com/oxf/pipeline" xmlns:sql="http://orbeon.org/oxf/xml/sql" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:oxf="http://www.orbeon.com/oxf/processors" xmlns:xi="http://www.w3.org/2001/XInclude"> <p:param name="data" type="output"/> <p:processor name="oxf:sql"> <p:input name="config"> <sql:config> <locations> <sql:connection> <sql:datasource>freeradius</sql:datasource> <sql:execute> <sql:query> select york_loc_id from york_locations </sql:query> <sql:result-set> <sql:row-iterator> <location> <location_ptr> <sql:get-column-value type="xs:string" column="york_loc_id"/> </location_ptr> </location> </sql:row-iterator> </sql:result-set> </sql:execute> </sql:connection> </locations> </sql:config> </p:input> <p:output name="data" id="location-data" debug="alexs"/> </p:processor> <p:processor name="oxf:identity"> <p:input name="data" href="aggregate('netdev',#location-data)"/> <p:output name="data" ref="data"/> </p:processor> </p:config> q -- You received this message because you are subscribed to the Google Groups "Orbeon Forms" group. To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email]. To post to this group, send email to [hidden email]. |
Sorted, you need to put the mysql driver jar file in $CATALINA_HOME/lib and not in ...common/lib :-((
Rgds Alex On 28 Jun 2013, at 13:53, alex sharaz <[hidden email]> wrote: > Hi, > Seem to be having a small problem accessing some data stored in a back end mysql data without much usable logging ( this with 4.2 CE) > > from the log file I get > > 2013-06-28 13:38:09,587 ERROR PageFlowControllerProcessor - error caught {controller: "oxf:/apps/location-info/page-flow.xml", m > ethod: "GET", path: "/location-info/"} > 2013-06-28 13:38:09,842 ERROR PageFlowControllerProcessor - > +----------------------------------------------------------------------------------------------------------------------+ > |An Error has Occurred | > |----------------------------------------------------------------------------------------------------------------------| > |No suitable driver | > |----------------------------------------------------------------------------------------------------------------------| > |Application Call Stack | > |----------------------------------------------------------------------------------------------------------------------| > |oxf:/apps/location-info/test.xpl | 32| | | > |oxf:/apps/location-info/test.xpl | 32| | | > |oxf:/apps/location-info/test.xpl | 49| 65|reading processor output | > |oxf:/apps/location-info/test.xpl | 54| 45|reading processor output | > |oxf:/apps/location-info/page-flow.xml | 8| 73|reading page model data output | > |oxf:/apps/location-info/page-flow.xml | 8| 73|reading page view data output | > |----------------------------------------------------------------------------------------------------------------------| > |Exception: java.sql.SQLException | > |----------------------------------------------------------------------------------------------------------------------| > |java.sql.DriverManager |getDriver |DriverManager.java | 279| > |org.apache.commons.dbcp.BasicDataSource |createConnectionFactory |BasicDataSource.java |1437| > |----------------------------------------------------------------------------------------------------------------------| > |Exception: org.apache.commons.dbcp.SQLNestedException | > |----------------------------------------------------------------------------------------------------------------------| > |org.apache.commons.dbcp.BasicDataSource |createConnectionFactory |BasicDataSource.java |1452| > |org.apache.commons.dbcp.BasicDataSource |createDataSource |BasicDataSource.java |1371| > |org.apache.commons.dbcp.BasicDataSource |getConnection |BasicDataSource.java |1044| > |org.orbeon.oxf.processor.DatabaseContext |getConnection |DatabaseContext.java | 60| > |----------------------------------------------------------------------------------------------------------------------| > > So … > > in /etc/tomcat6/server.xml I've got > > <Resource name="jdbc/mysql" auth="Container" type="javax.sql.DataSource" > initialSize="3" maxActive="10" maxIdle="20" maxWait="30000" > driverClassName="com.mysql.jdbc.Driver" > poolPreparedStatements="true" > username="something" password="something else" > url="jdbc:mysql://144.32.126.92:3306/freeradius"/> > > In /var/lib/tomcat6/xformapps/orbeon-4.2/WEB-INF/web.xml I've got > > <resource-ref> > <description>FreeRadius DB Connection</description> > <res-ref-name>jdbc/freeradius</res-ref-name> > <res-type>javax.sql.DataSource</res-type> > <res-auth>Container</res-auth> > </resource-ref> > > /var/lib/tomcat6/common/lib has mysql-connector-java-5.1.25-bin.jar in it and I've restarted the server > > In my forms app page-flow.xml has > > <page path-info="/location-info/" model="test.xpl" view="entry.xsl"> > > and test.xpl has > > <p:config xmlns:p="http://www.orbeon.com/oxf/pipeline" > xmlns:sql="http://orbeon.org/oxf/xml/sql" > xmlns:xs="http://www.w3.org/2001/XMLSchema" > xmlns:xsl="http://www.w3.org/1999/XSL/Transform" > xmlns:oxf="http://www.orbeon.com/oxf/processors" > xmlns:xi="http://www.w3.org/2001/XInclude"> > > <p:param name="data" type="output"/> > > > <p:processor name="oxf:sql"> > <p:input name="config"> > <sql:config> > <locations> > <sql:connection> > <sql:datasource>freeradius</sql:datasource> > <sql:execute> > <sql:query> > select york_loc_id from york_locations > </sql:query> > <sql:result-set> > <sql:row-iterator> > <location> > <location_ptr> > <sql:get-column-value type="xs:string" column="york_loc_id"/> > </location_ptr> > </location> > </sql:row-iterator> > </sql:result-set> > </sql:execute> > </sql:connection> > </locations> > </sql:config> > </p:input> > <p:output name="data" id="location-data" debug="alexs"/> > </p:processor> > > <p:processor name="oxf:identity"> > <p:input name="data" href="aggregate('netdev',#location-data)"/> > <p:output name="data" ref="data"/> > </p:processor> > </p:config> > q > > > > > -- > You received this message because you are subscribed to the Google Groups "Orbeon Forms" group. > To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email]. > To post to this group, send email to [hidden email]. > > -- You received this message because you are subscribed to the Google Groups "Orbeon Forms" group. To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email]. To post to this group, send email to [hidden email]. |
Free forum by Nabble | Edit this page |