You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Enke Michael <Mi...@wincor-nixdorf.com> on 2002/03/29 09:20:42 UTC

SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin, please read this

Hi,
Tonight I found the solution:
We have a ClassCastException. To solve this for jdk1.4:
Get the daily build from excalibur,
change both JdbcConnection to Jdbc3Connection in line 106 in
scratchpad/org/apache/avalon/excalibur/datasource/ResourceLimitingJdbcConnectionPool.java
Thats it. But - THIS IS ONLY FOR JDK1.4, this doesn't wor for jdk < 1.4
To make it relly nice to work for all, Berin will sourround it with
if(instance of JdbcConnection) ... else if(instance of Jdbc3Connection) or something like this,
won't you Berin?

Happy easter again,
Michael

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin, please read this

Posted by Enke Michael <Mi...@wincor-nixdorf.com>.
Christopher Watson wrote:
> ...
> and I can see the port connections getting dropped
> 
> Hit refresh and it works again.
> Hit refresh and it fails again as above.
> 
> Eventually, I get nothing back at all
> 
> :-{
> 
> Is this just me?
> If not, is it something that could be fixed soon, or would you advise me to
> go back to jdk1.3 for the while ??
> ...

As of Thursday after midnight I was happy to see that it works one time.
I didn't try it a second time. Found the same behavior as you today.
Will investigate further and hope to get the solution today.
But I have read a posting (bugzilla) concerning about errors in the usage of
use-limit-clause. I don't know if this is related to jdk1.4 or
to the DB-driver or the esql.xsl. I will report in the evening.

Regards,
Michael

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin, please read this

Posted by Enke Michael <Mi...@wincor-nixdorf.com>.
Christopher Watson wrote:
> 
> Michael,
> Well done, many thanks.

You are welcome ;-)

> I've meantime gone back to jdk1.3 ! Now, dare I go back forward again to
> jdk1.4 ? (Guess that's my problem to decide!)

No other limitations known.

> I'm guessing your excellent work is so far a kind of temporary workaround?
> Do you see this getting incorporated into a new excalibur jar in cocoon CVS
> in the near future?
> Would that be someting Berin would do?

Yes, he will do this (if he is yet following this thread).
He is a committer and can check in.

> If not, could you advise me which excalibur sources to edit (CVS - which
> branch, or dist, or what)
> and also which jars to build excalibur against, and where to get them?

I also have the problem with logkit but this is not urgent to me.

http://jakarta.apache.org/builds/jakarta-avalon/nightly/2002-03-27/jakarta-avalon-excalibur-src.tar.gz
untar, cd jakarta-avalon-excalibur
(
  cd all/src/scratchpad/org/apache/avalon/excalibur/datasource
  vi ResourceLimitingJdbcConnectionPool.java
  line 106 and 156: change JdbcConnection to Jdbc3Connection (both)
  -> ONLY FOR JDK1.4 <-
)
./build.sh (in jakarta-avalon-excalibur) will do the job, creates excalibur-all.jar
Remove in cocoon/WEB-INF/lib avalon-excalibur-4.1.jar and avalon-excalibur-scratchpad-20020212.jar and
copy excalibur-all.jar to this location.

But: Berin wrote: He will change it in both classes.
I don't know what he means with "both classes".
I guess he means
jakarta-avalon-excalibur/all/src/java/org/apache/avalon/excalibur/datasource/JdbcConnectionPool.java
there are also references to JdbcConnection, but changing this to Jdbc3Connection has no effect
because "my cocoon configuration" uses ResourceLimitingJdbcConnectionPool instead of JdbcConnectionPool.

Happy cocooning,
Michael

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


RE: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin, please read this

Posted by Berin Loritsch <bl...@apache.org>.
> -----Original Message-----
> From: Christopher Watson [mailto:cwatson@taraserv.demon.co.uk] 
> 
> Michael,
> Well done, many thanks.
> 
> I've meantime gone back to jdk1.3 ! Now, dare I go back 
> forward again to jdk1.4 ? (Guess that's my problem to decide!)
> 
> I'm guessing your excellent work is so far a kind of 
> temporary workaround? Do you see this getting incorporated 
> into a new excalibur jar in cocoon CVS in the near future? 
> Would that be someting Berin would do?

Excalibur is almost in its new format (somewhat akin to Commons).
It will be in the new version--someone will release it when we
are ready.  We are addressing some serious user issues with Avalon,
and we want the site to be accessible, along with the code.

> If not, could you advise me which excalibur sources to edit 
> (CVS - which branch, or dist, or what) and also which jars to 
> build excalibur against, and where to get them?
> 
> I'm a bit new to the above (cocoon itself usually builds so 
> nicely without
> tweaking!)
> and when I tried it, the resulting jars I built did not sit 
> well with logkit when I subsequently rebuilt cocoon :-{ Any 
> ideas on this ?

I put the changes into the default Pool implementation for
DataSources.  It is in Excalibur CVS.


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


RE: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin, please read this

Posted by Christopher Watson <cw...@taraserv.demon.co.uk>.
Michael,
Well done, many thanks.

I've meantime gone back to jdk1.3 ! Now, dare I go back forward again to
jdk1.4 ? (Guess that's my problem to decide!)

I'm guessing your excellent work is so far a kind of temporary workaround?
Do you see this getting incorporated into a new excalibur jar in cocoon CVS
in the near future?
Would that be someting Berin would do?

If not, could you advise me which excalibur sources to edit (CVS - which
branch, or dist, or what)
and also which jars to build excalibur against, and where to get them?

I'm a bit new to the above (cocoon itself usually builds so nicely without
tweaking!)
and when I tried it, the resulting jars I built did not sit well with logkit
when I subsequently rebuilt cocoon :-{
Any ideas on this ?

Thanks again. Guess I'm not the only one who will benefit!
Christopher.
> -----Original Message-----
> From: Enke Michael [mailto:Michael.Enke@wincor-nixdorf.com]
> Sent: 02 April 2002 11:36
> To: cocoon-dev@xml.apache.org
> Subject: Re: SOLVED: Pool: NoValidConnectionException on jdk1.4 ->
> Berin, please read this
>
>
> Hello again,
> one snippet more:
> in the same file (ResourceLimitingJdbcConnectionPool.java
> also in line 156
> you must insert the "3" -> Jdbc3Connection conn =
> (Jdbc3Connection)poolable;
> Now you will get your page every time you reload.
>
> Berin: What did you mean with "I will change it in both classes"?
>                                                    ^^^^^^^^^^^^
>
> Regards,
> Michael
>
> Christopher Watson wrote:
> >
> > > -----Original Message-----
> > > From: Enke Michael [mailto:Michael.Enke@wincor-nixdorf.com]
> > > Sent: 29 March 2002 08:21
> > > To: cocoon-dev@xml.apache.org
> > > Subject: SOLVED: Pool: NoValidConnectionException on
> jdk1.4 -> Berin,
> > > please read this
> > >
> > >
> > > Hi,
> > > Tonight I found the solution:
> > > We have a ClassCastException. To solve this for jdk1.4:
> > > Get the daily build from excalibur,
> > > change both JdbcConnection to Jdbc3Connection in line 106 in
> > > scratchpad/org/apache/avalon/excalibur/datasource/ResourceLimi
> > > tingJdbcConnectionPool.java
> > > Thats it. But - THIS IS ONLY FOR JDK1.4, this doesn't wor for
> > > jdk < 1.4
> >
> > I tried this. I had a bit of fun getting the daily build to
> build - I'm
> > assuming you do this from build in the all directory?
> > I had to drop log4j out of logger, move cli and instrument
> to under all, use
> > the latest development jars for logkit and framework etc, blah blah
> > Eventually got it to compile, put all the jars into cocoon,
> rebuilt that ...
> >
> > Start tomcat, which complains about not being able to start
> cocoon logger
> >
> > Now it works EVERY ALTERNATE TIME ?? I run the xsp/esql example
> >
> > First time it works.
> > Hit refresh and it fails with
> >
> > Original exception : java.lang.RuntimeException: Could not get the
> > datasource
> >
> org.apache.avalon.excalibur.datasource.NoAvailableConnectionException:
> > org.apache.avalon.excalibur.datasource.Jdbc3Connection
> > at
> >
> org.apache.cocoon.www.docs.samples.xsp.agsql_xsp.generate(X:\j
> akarta-tomcat-
> >
> 4.0.4b1\work\localhost\cocoon\cocoon-files\org/apache/cocoon/w
> ww/docs/sample
> > s/xsp\agsql_xsp.java:341)
> > at
> >
> org.apache.cocoon.generation.ServerPagesGenerator.generate(Ser
> verPagesGenera
> > tor.java:260)
> > at
> >
> org.apache.cocoon.components.pipeline.CachingEventPipeline.pro
> cess(CachingEv
> > entPipeline.java:251)
> > at
> >
> org.apache.cocoon.components.pipeline.CachingStreamPipeline.pr
> ocess(CachingS
> > treamPipeline.java:399)
> > at
> >
> org.apache.cocoon.www.sitemap_xmap.matchN4007D4(X:\jakarta-tom
> cat-4.0.4b1\wo
> >
> rk\localhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap
> _xmap.java:985
> > 7)
> > at
> >
> org.apache.cocoon.www.sitemap_xmap.process(X:\jakarta-tomcat-4
> .0.4b1\work\lo
> >
> calhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap_xmap
> .java:3675)
> > at
> >
> org.apache.cocoon.www.sitemap_xmap.process(X:\jakarta-tomcat-4
> .0.4b1\work\lo
> >
> calhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap_xmap
> .java:3085)
> > at org.apache.cocoon.sitemap.Handler.process(Handler.java:222)
> > at org.apache.cocoon.sitemap.Manager.invoke(Manager.java:179)
> > at
> org.apache.cocoon.sitemap.SitemapManager.process(SitemapManage
> r.java:154)
> > at org.apache.cocoon.Cocoon.process(Cocoon.java:575)
> > at
> org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.
> java:998)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> >
> > and I can see the port connections getting dropped
> >
> > Hit refresh and it works again.
> > Hit refresh and it fails again as above.
> >
> > Eventually, I get nothing back at all
> >
> > :-{
> >
> > Is this just me?
> > If not, is it something that could be fixed soon, or would
> you advise me to
> > go back to jdk1.3 for the while ??
> >
> > > To make it relly nice to work for all, Berin will
> sourround it with
> > > if(instance of JdbcConnection) ... else if(instance of
> > > Jdbc3Connection) or something like this,
> > > won't you Berin?
> > >
> > > Happy easter again,
> > > Michael
> > >
> > >
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> > > For additional commands, email: cocoon-dev-help@xml.apache.org
> > >
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> > For additional commands, email: cocoon-dev-help@xml.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


RE: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin, please read this

Posted by Berin Loritsch <bl...@apache.org>.
> -----Original Message-----
> From: Enke Michael [mailto:Michael.Enke@wincor-nixdorf.com] 
> 
> Hello again,
> one snippet more:
> in the same file (ResourceLimitingJdbcConnectionPool.java 
> also in line 156 you must insert the "3" -> Jdbc3Connection 
> conn = (Jdbc3Connection)poolable; Now you will get your page 
> every time you reload.
> 
> Berin: What did you mean with "I will change it in both classes"?
>                                                    ^^^^^^^^^^^^

Misunderstanding of which class you meant.  It was in the pool
class.  The Pool was altered.  I need to make the ResourceLimitingPool
also work.

> 
> Regards,
> Michael
> 
> Christopher Watson wrote:
> > 
> > > -----Original Message-----
> > > From: Enke Michael [mailto:Michael.Enke@wincor-nixdorf.com]
> > > Sent: 29 March 2002 08:21
> > > To: cocoon-dev@xml.apache.org
> > > Subject: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> 
> > > Berin, please read this
> > >
> > >
> > > Hi,
> > > Tonight I found the solution:
> > > We have a ClassCastException. To solve this for jdk1.4:
> > > Get the daily build from excalibur,
> > > change both JdbcConnection to Jdbc3Connection in line 106 in 
> > > scratchpad/org/apache/avalon/excalibur/datasource/ResourceLimi
> > > tingJdbcConnectionPool.java
> > > Thats it. But - THIS IS ONLY FOR JDK1.4, this doesn't wor 
> for jdk < 
> > > 1.4
> > 
> > I tried this. I had a bit of fun getting the daily build to build - 
> > I'm assuming you do this from build in the all directory? I had to 
> > drop log4j out of logger, move cli and instrument to under all, use 
> > the latest development jars for logkit and framework etc, blah blah 
> > Eventually got it to compile, put all the jars into cocoon, rebuilt 
> > that ...
> > 
> > Start tomcat, which complains about not being able to start cocoon 
> > logger
> > 
> > Now it works EVERY ALTERNATE TIME ?? I run the xsp/esql example
> > 
> > First time it works.
> > Hit refresh and it fails with
> > 
> > Original exception : java.lang.RuntimeException: Could not get the 
> > datasource
> > 
> org.apache.avalon.excalibur.datasource.NoAvailableConnectionException:
> > org.apache.avalon.excalibur.datasource.Jdbc3Connection
> > at
> > 
> org.apache.cocoon.www.docs.samples.xsp.agsql_xsp.generate(X:\jakarta-t
> > omcat-
> > 
> 4.0.4b1\work\localhost\cocoon\cocoon-files\org/apache/cocoon/w
> ww/docs/sample
> > s/xsp\agsql_xsp.java:341)
> > at
> > 
> org.apache.cocoon.generation.ServerPagesGenerator.generate(Ser
> verPagesGenera
> > tor.java:260)
> > at
> > 
> org.apache.cocoon.components.pipeline.CachingEventPipeline.pro
> cess(CachingEv
> > entPipeline.java:251)
> > at
> > 
> org.apache.cocoon.components.pipeline.CachingStreamPipeline.pr
> ocess(CachingS
> > treamPipeline.java:399)
> > at
> > 
> org.apache.cocoon.www.sitemap_xmap.matchN4007D4(X:\jakarta-tom
> cat-4.0.4b1\wo
> > 
> rk\localhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap
> _xmap.java:985
> > 7)
> > at
> > 
> org.apache.cocoon.www.sitemap_xmap.process(X:\jakarta-tomcat-4
> .0.4b1\work\lo
> > 
> calhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap_xmap
.java:3675)
> > at
> > 
> org.apache.cocoon.www.sitemap_xmap.process(X:\jakarta-tomcat-4
> .0.4b1\work\lo
> > 
> calhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap_xmap
.java:3085)
> > at org.apache.cocoon.sitemap.Handler.process(Handler.java:222)
> > at org.apache.cocoon.sitemap.Manager.invoke(Manager.java:179)
> > at 
> org.apache.cocoon.sitemap.SitemapManager.process(SitemapManage
> r.java:154)
> > at org.apache.cocoon.Cocoon.process(Cocoon.java:575)
> > at 
> org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.
> java:998)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> > 
> > and I can see the port connections getting dropped
> > 
> > Hit refresh and it works again.
> > Hit refresh and it fails again as above.
> > 
> > Eventually, I get nothing back at all
> > 
> > :-{
> > 
> > Is this just me?
> > If not, is it something that could be fixed soon, or would 
> you advise 
> > me to go back to jdk1.3 for the while ??
> > 
> > > To make it relly nice to work for all, Berin will 
> sourround it with 
> > > if(instance of JdbcConnection) ... else if(instance of
> > > Jdbc3Connection) or something like this,
> > > won't you Berin?
> > >
> > > Happy easter again,
> > > Michael
> > >
> > > 
> --------------------------------------------------------------------
> > > -
> > > To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> > > For additional commands, email: cocoon-dev-help@xml.apache.org
> > >
> > 
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> > For additional commands, email: cocoon-dev-help@xml.apache.org
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin, please read this

Posted by Enke Michael <Mi...@wincor-nixdorf.com>.
Hello again,
one snippet more:
in the same file (ResourceLimitingJdbcConnectionPool.java also in line 156
you must insert the "3" -> Jdbc3Connection conn = (Jdbc3Connection)poolable;
Now you will get your page every time you reload.

Berin: What did you mean with "I will change it in both classes"?
                                                   ^^^^^^^^^^^^

Regards,
Michael

Christopher Watson wrote:
> 
> > -----Original Message-----
> > From: Enke Michael [mailto:Michael.Enke@wincor-nixdorf.com]
> > Sent: 29 March 2002 08:21
> > To: cocoon-dev@xml.apache.org
> > Subject: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin,
> > please read this
> >
> >
> > Hi,
> > Tonight I found the solution:
> > We have a ClassCastException. To solve this for jdk1.4:
> > Get the daily build from excalibur,
> > change both JdbcConnection to Jdbc3Connection in line 106 in
> > scratchpad/org/apache/avalon/excalibur/datasource/ResourceLimi
> > tingJdbcConnectionPool.java
> > Thats it. But - THIS IS ONLY FOR JDK1.4, this doesn't wor for
> > jdk < 1.4
> 
> I tried this. I had a bit of fun getting the daily build to build - I'm
> assuming you do this from build in the all directory?
> I had to drop log4j out of logger, move cli and instrument to under all, use
> the latest development jars for logkit and framework etc, blah blah
> Eventually got it to compile, put all the jars into cocoon, rebuilt that ...
> 
> Start tomcat, which complains about not being able to start cocoon logger
> 
> Now it works EVERY ALTERNATE TIME ?? I run the xsp/esql example
> 
> First time it works.
> Hit refresh and it fails with
> 
> Original exception : java.lang.RuntimeException: Could not get the
> datasource
> org.apache.avalon.excalibur.datasource.NoAvailableConnectionException:
> org.apache.avalon.excalibur.datasource.Jdbc3Connection
> at
> org.apache.cocoon.www.docs.samples.xsp.agsql_xsp.generate(X:\jakarta-tomcat-
> 4.0.4b1\work\localhost\cocoon\cocoon-files\org/apache/cocoon/www/docs/sample
> s/xsp\agsql_xsp.java:341)
> at
> org.apache.cocoon.generation.ServerPagesGenerator.generate(ServerPagesGenera
> tor.java:260)
> at
> org.apache.cocoon.components.pipeline.CachingEventPipeline.process(CachingEv
> entPipeline.java:251)
> at
> org.apache.cocoon.components.pipeline.CachingStreamPipeline.process(CachingS
> treamPipeline.java:399)
> at
> org.apache.cocoon.www.sitemap_xmap.matchN4007D4(X:\jakarta-tomcat-4.0.4b1\wo
> rk\localhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap_xmap.java:985
> 7)
> at
> org.apache.cocoon.www.sitemap_xmap.process(X:\jakarta-tomcat-4.0.4b1\work\lo
> calhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap_xmap.java:3675)
> at
> org.apache.cocoon.www.sitemap_xmap.process(X:\jakarta-tomcat-4.0.4b1\work\lo
> calhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap_xmap.java:3085)
> at org.apache.cocoon.sitemap.Handler.process(Handler.java:222)
> at org.apache.cocoon.sitemap.Manager.invoke(Manager.java:179)
> at org.apache.cocoon.sitemap.SitemapManager.process(SitemapManager.java:154)
> at org.apache.cocoon.Cocoon.process(Cocoon.java:575)
> at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:998)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> 
> and I can see the port connections getting dropped
> 
> Hit refresh and it works again.
> Hit refresh and it fails again as above.
> 
> Eventually, I get nothing back at all
> 
> :-{
> 
> Is this just me?
> If not, is it something that could be fixed soon, or would you advise me to
> go back to jdk1.3 for the while ??
> 
> > To make it relly nice to work for all, Berin will sourround it with
> > if(instance of JdbcConnection) ... else if(instance of
> > Jdbc3Connection) or something like this,
> > won't you Berin?
> >
> > Happy easter again,
> > Michael
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> > For additional commands, email: cocoon-dev-help@xml.apache.org
> >
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


RE: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin, please read this

Posted by Christopher Watson <cw...@taraserv.demon.co.uk>.
> -----Original Message-----
> From: Enke Michael [mailto:Michael.Enke@wincor-nixdorf.com]
> Sent: 29 March 2002 08:21
> To: cocoon-dev@xml.apache.org
> Subject: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin,
> please read this
>
>
> Hi,
> Tonight I found the solution:
> We have a ClassCastException. To solve this for jdk1.4:
> Get the daily build from excalibur,
> change both JdbcConnection to Jdbc3Connection in line 106 in
> scratchpad/org/apache/avalon/excalibur/datasource/ResourceLimi
> tingJdbcConnectionPool.java
> Thats it. But - THIS IS ONLY FOR JDK1.4, this doesn't wor for
> jdk < 1.4

I tried this. I had a bit of fun getting the daily build to build - I'm
assuming you do this from build in the all directory?
I had to drop log4j out of logger, move cli and instrument to under all, use
the latest development jars for logkit and framework etc, blah blah
Eventually got it to compile, put all the jars into cocoon, rebuilt that ...

Start tomcat, which complains about not being able to start cocoon logger

Now it works EVERY ALTERNATE TIME ?? I run the xsp/esql example

First time it works.
Hit refresh and it fails with

Original exception : java.lang.RuntimeException: Could not get the
datasource
org.apache.avalon.excalibur.datasource.NoAvailableConnectionException:
org.apache.avalon.excalibur.datasource.Jdbc3Connection
at
org.apache.cocoon.www.docs.samples.xsp.agsql_xsp.generate(X:\jakarta-tomcat-
4.0.4b1\work\localhost\cocoon\cocoon-files\org/apache/cocoon/www/docs/sample
s/xsp\agsql_xsp.java:341)
at
org.apache.cocoon.generation.ServerPagesGenerator.generate(ServerPagesGenera
tor.java:260)
at
org.apache.cocoon.components.pipeline.CachingEventPipeline.process(CachingEv
entPipeline.java:251)
at
org.apache.cocoon.components.pipeline.CachingStreamPipeline.process(CachingS
treamPipeline.java:399)
at
org.apache.cocoon.www.sitemap_xmap.matchN4007D4(X:\jakarta-tomcat-4.0.4b1\wo
rk\localhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap_xmap.java:985
7)
at
org.apache.cocoon.www.sitemap_xmap.process(X:\jakarta-tomcat-4.0.4b1\work\lo
calhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap_xmap.java:3675)
at
org.apache.cocoon.www.sitemap_xmap.process(X:\jakarta-tomcat-4.0.4b1\work\lo
calhost\cocoon\cocoon-files\org/apache/cocoon/www\sitemap_xmap.java:3085)
at org.apache.cocoon.sitemap.Handler.process(Handler.java:222)
at org.apache.cocoon.sitemap.Manager.invoke(Manager.java:179)
at org.apache.cocoon.sitemap.SitemapManager.process(SitemapManager.java:154)
at org.apache.cocoon.Cocoon.process(Cocoon.java:575)
at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:998)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)

and I can see the port connections getting dropped

Hit refresh and it works again.
Hit refresh and it fails again as above.

Eventually, I get nothing back at all

:-{

Is this just me?
If not, is it something that could be fixed soon, or would you advise me to
go back to jdk1.3 for the while ??

> To make it relly nice to work for all, Berin will sourround it with
> if(instance of JdbcConnection) ... else if(instance of
> Jdbc3Connection) or something like this,
> won't you Berin?
>
> Happy easter again,
> Michael
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


RE: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin, please read this

Posted by Berin Loritsch <bl...@apache.org>.
Thank you very much!

Now I thought that all the classes came from AbstractConnection,
I will have to fix line 106 in both classes to use AbstractConnection
so we won't have this problem no matter what Connection class we
are using.

Thanks for your detective work!

> -----Original Message-----
> From: Enke Michael [mailto:Michael.Enke@wincor-nixdorf.com] 
> Sent: Friday, March 29, 2002 3:21 AM
> To: cocoon-dev@xml.apache.org
> Subject: SOLVED: Pool: NoValidConnectionException on jdk1.4 
> -> Berin, please read this
> 
> 
> Hi,
> Tonight I found the solution:
> We have a ClassCastException. To solve this for jdk1.4:
> Get the daily build from excalibur,
> change both JdbcConnection to Jdbc3Connection in line 106 in 
> scratchpad/org/apache/avalon/excalibur/datasource/ResourceLimi
> tingJdbcConnectionPool.java
> Thats it. But - THIS IS ONLY FOR JDK1.4, this doesn't wor for 
> jdk < 1.4 To make it relly nice to work for all, Berin will 
> sourround it with if(instance of JdbcConnection) ... else 
> if(instance of Jdbc3Connection) or something like this, won't 
> you Berin?
> 
> Happy easter again,
> Michael
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org
> 


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


RE: SOLVED: Pool: NoValidConnectionException on jdk1.4 -> Berin, please read this

Posted by Berin Loritsch <bl...@apache.org>.
Thank you very much!

Now I thought that all the classes came from AbstractConnection,
I will have to fix line 106 in both classes to use AbstractConnection
so we won't have this problem no matter what Connection class we
are using.

Thanks for your detective work!

> -----Original Message-----
> From: Enke Michael [mailto:Michael.Enke@wincor-nixdorf.com] 
> Sent: Friday, March 29, 2002 3:21 AM
> To: cocoon-dev@xml.apache.org
> Subject: SOLVED: Pool: NoValidConnectionException on jdk1.4 
> -> Berin, please read this
> 
> 
> Hi,
> Tonight I found the solution:
> We have a ClassCastException. To solve this for jdk1.4:
> Get the daily build from excalibur,
> change both JdbcConnection to Jdbc3Connection in line 106 in 
> scratchpad/org/apache/avalon/excalibur/datasource/ResourceLimi
> tingJdbcConnectionPool.java
> Thats it. But - THIS IS ONLY FOR JDK1.4, this doesn't wor for 
> jdk < 1.4 To make it relly nice to work for all, Berin will 
> sourround it with if(instance of JdbcConnection) ... else 
> if(instance of Jdbc3Connection) or something like this, won't 
> you Berin?
> 
> Happy easter again,
> Michael
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org