You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Derek Hohls <DH...@csir.co.za> on 2001/08/30 13:09:24 UTC

C1: ESQL: Pooling with mySQL?

When I try to use connection pooling rather than "in page" logic, I get an error.

I had:
  <esql:driver>org.gjt.mm.mysql.Driver</esql:driver>
  <esql:dburl><xsp:expr>DBName</xsp:expr></esql:dburl>
  <esql:username><xsp:expr>DBUser</xsp:expr></esql:username>
  <esql:password><xsp:expr>DBPass</xsp:expr></esql:password>
which worked fine...

and now have changed to:

<esql:pool>mydb</esql:pool>

where mydb is specified in the cocoon.properties file as:

processor.xsp.pool.database.mydb.driver=org.gjt.mm.mysql.Driver
processor.xsp.pool.database.mydb.url=jdbc:mysql:localhost/mydb
processor.xsp.pool.database.mydb.username=user
processor.xsp.pool.database.mydb.password=pass
processor.xsp.pool.database.mydb.maxConnections=10
processor.xsp.pool.database.mydb.expiryTime=3600000

The error I get is :

java.lang.RuntimeException: 
Error opening pooled connection: mydb: 
Database type org.gjt.mm.mysql.Driver not implemented.

What do I need to do??

Thanks
Derek

Re: C1: ESQL: Pooling with mySQL?

Posted by Sébastien Lefebvre <sl...@i2m.fr>.
You need to add a line in your cocoon.properties file. Check this and 
compare with your cocoon.properties file


# These are the supported jdbc-drivers and their adaptors.
# These properties are used by the DBFactory.
processor.xsp.pool.database.adaptor=DBWeblogic,DBOracle,DBInstantDB,DBPostgres,DBSybase,DBInformix,DBMM
processor.xsp.pool.database.adaptor.DBWeblogic=weblogic.jdbc.pool.Driver
processor.xsp.pool.database.adaptor.DBOracle=oracle.jdbc.driver.OracleDriver
processor.xsp.pool.database.adaptor.DBInstantDB=org.enhydra.instantdb.jdbc.idbDriver
processor.xsp.pool.database.adaptor.DBPostgres=postgresql.Driver
processor.xsp.pool.database.adaptor.DBInformix=com.informix.jdbc.IfxDriver
processor.xsp.pool.database.adaptor.DBSybase=com.sybase.jdbc.SybDriver
processor.xsp.pool.database.adaptor.DBMM=org.gjt.mm.mysql.Driver

> When I try to use connection pooling rather than "in page" logic, I 
> get an error.
>
>  
>
> I had:
>
>   <esql:driver>org.gjt.mm.mysql.Driver</esql:driver>
>   <esql:dburl><xsp:expr>DBName</xsp:expr></esql:dburl>
>   <esql:username><xsp:expr>DBUser</xsp:expr></esql:username>
>   <esql:password><xsp:expr>DBPass</xsp:expr></esql:password>
>
> which worked fine...
>
>  
>
> and now have changed to:
>
>  
>
> <esql:pool>mydb</esql:pool>
>
>  
>
> where mydb is specified in the cocoon.properties file as:
>
>  
>
> processor.xsp.pool.database.mydb.driver=org.gjt.mm.mysql.Driver
> processor.xsp.pool.database.mydb.url=jdbc:mysql:localhost/mydb
> processor.xsp.pool.database.mydb.username=user
> processor.xsp.pool.database.mydb.password=pass
> processor.xsp.pool.database.mydb.maxConnections=10
> processor.xsp.pool.database.mydb.expiryTime=3600000
>
>  
>
> The error I get is :
>
>  
>
> java.lang.RuntimeException:
>
> Error opening pooled connection: mydb:
>
> Database type org.gjt.mm.mysql.Driver not implemented.
>
> What do I need to do??
>
>  
>
> Thanks
>
> Derek
>




---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>