• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: JDBC close() exception?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: JDBC close() exception?


  • Subject: Re: JDBC close() exception?
  • From: William Hatch <email@hidden>
  • Date: Wed, 02 Sep 2009 11:17:40 -0400

Thanks Andrew,

I don't have problems with it not reconnecting, but in tomcat, it seems that exceptions blow up the memory eventually, even if they're caught and handled. That's my theory anyway; I could be completely wrong. But I've noticed a few other places where I may get loads of caught exceptions (you know, "this won't happen that often, so just catch the occasional exception..." type implementation, and then it turns out to happen a whole lot more than what you'd originally thought), and it crushed the server within minutes and it started to swap and thrash. After I'd refactored to handle that particular situation differently, the problems vanished. So I'm just relating this current issue with that experience. Also, memory settings are critical for GC purposes; on a 64 bit os, using Sun's java, I've found you really can't go much above 3GB max or GC will end up gradually consuming more and more time and the app eventually gets ridiculously slow.

Thanks Andrew.

Bill


On Sep 2, 2009, at 12:44 AM, Andrew Lindesay wrote:

Hello Amiel & Bill;

Is it possible that there could be a bug in the data-source in the container you are using -- assume you are servletting? I think MySQL server does close the connection "overnight" if there is no traffic on the connection, but I haven't experienced it doing this during operational hours. I seem to remember the "autoReconnect" does work. Maybe you could use a data source which runs a test query each time a connection is taken from the pool?

Regards;

Did you find a solution to this? I'm afraid I am also being killed by this.
Could it be a timeout problem and MySQL is closing the connection? There is a MySQL option "autoReconnect" but I don't feel comfortable with it.

___ Andrew Lindesay www.lindesay.co.nz


_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: JDBC close() exception?
      • From: Andrew Lindesay <email@hidden>
    • Re: JDBC close() exception?
      • From: Amiel Montecillo <email@hidden>
References: 
 >Re: JDBC close() exception? (From: Amiel Montecillo <email@hidden>)
 >Re: JDBC close() exception? (From: Andrew Lindesay <email@hidden>)

  • Prev by Date: Re: developing under 10.6 and deploying under 10.5 server
  • Next by Date: Re: Snow Leopard Development and Deployment
  • Previous by thread: Re: JDBC close() exception?
  • Next by thread: Re: JDBC close() exception?
  • Index(es):
    • Date
    • Thread