You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Götz Botterweck <bo...@iwi.uni-koblenz.de> on 2000/11/01 16:13:35 UTC
Connect Cocoon 1.8 to SQL-Server? How to switch of connection poo
ling?
Hi Folks!
WHAT I WANT TO DO
Use Cocoon to connect to an Microsoft SQL-Server
database and display it's contents.
WHAT I TRIED ALREADY
Downloaded and installed Cocoon 1.8 (on top of
Win2K, Apache 1.3.12, Tomcat 3.1)
First http://server/Cocoon.xml resulted in some
turbine error, which was solved after downloading
version 1.5 of turbine-pool.jar from CVS.
Then I copied and modified /samples/sql/esql.xml
to use Sun's JDBC-ODBC-Bridge:
...
<esql:driver>sun.jdbc.odbc.JdbcOdbcDriver</esql:driver>
<esql:dburl>jdbc:odbc:MyDataSourceName</esql:dburl>
...
PROBLEM
When accessing /samples/esql.xml I get:
java.lang.Exception: XSP Java Compiler: Compilation failed for _esql2.java
45: Incompatible type for method. Explicit cast needed to convert
org.apache.turbine.services.db.PoolBrokerService to
org.apache.turbine.util.db.pool.DBBroker.
static DBBroker _esql_pool = DBBroker.getInstance();
^
Note:
C:\apps\apache\tomcat\bin\repository\_C_\_projects\_wwwroot\_samples\_sql\_e
sql2.java
uses or overrides a deprecated API. Recompile with "-deprecation" for
details.
1 error, 1 warning
at
org.apache.cocoon.processor.xsp.language.java.XSPJavaProcessor.compile(XSPJa
vaProcessor.java, Compiled Code)
at java.lang.Exception.(Exception.java, Compiled Code)
at
org.apache.cocoon.processor.xsp.language.java.XSPJavaProcessor.compile(XSPJa
vaProcessor.java, Compiled Code)
at
org.apache.cocoon.processor.xsp.XSPProcessor.process(XSPProcessor.java,
Compiled Code)
at org.apache.cocoon.Engine.handle(Engine.java, Compiled Code)
at org.apache.cocoon.Cocoon.service(Cocoon.java:167)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:865)
at
org.apache.tomcat.core.ServletWrapper.handleRequest(ServletWrapper.java,
Compiled Code)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:559)
at
org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConnection
(Ajp12ConnectionHandler.java:156)
at
org.apache.tomcat.service.TcpConnectionThread.run(SimpleTcpEndpoint.java:338
)
at java.lang.Thread.run(Thread.java:479)
QUESTION
When looking at cocoon.properties, I understand that SQLServer
is current not supported by the new "connection pooling" feature.
Does the error come from this fact?
Is it possible to somehow switch of connection pooling for
SQLServer?
MANY Thanks in advance
Goetz