You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by Chris Means <cm...@intfar.com> on 2004/05/23 18:32:05 UTC

Possible bug in RC3 with connection pool

I've had RC3 running for the past week.

Other than an issue I ran into with the config.xml when translating changes
from my 0a4 configuration, RC3 has been running quite well except for a new
problem that appears to have surfaced.

This issue may relate to the fact that I've also been evaluating Mars
(http://leapfrog-mars.sourceforge.net/) for monitoring services.

I wanted to run this by the list before I reported it as a possible bug in
James.

Here's the exception that's occurring in the pop3server log:

23/05/04 11:01:58 ERROR pop3server: Exception during connection from
intfar.com (66.92.129.218) : An exception occurred getting a database
connection.
org.apache.avalon.framework.CascadingRuntimeException: An exception occurred
getting a database connection.
	at
org.apache.james.userrepository.AbstractJdbcUsersRepository.openConnection(A
bstractJdbcUsersRepository.java:601)
	at
org.apache.james.userrepository.AbstractJdbcUsersRepository.getUserByName(Ab
stractJdbcUsersRepository.java:506)
	at
org.apache.james.userrepository.AbstractUsersRepository.test(AbstractUsersRe
pository.java:284)
	at
org.apache.james.pop3server.POP3Handler.doPASS(POP3Handler.java:528)
	at
org.apache.james.pop3server.POP3Handler.parseCommand(POP3Handler.java:470)
	at
org.apache.james.pop3server.POP3Handler.handleConnection(POP3Handler.java:26
6)
	at
org.apache.james.util.connection.ServerConnection$ClientConnectionRunner.run
(ServerConnection.java:417)
	at
org.apache.james.util.thread.ExecutableRunnable.execute(ExecutableRunnable.j
ava:55)
	at
org.apache.james.util.thread.WorkerThread.run(WorkerThread.java:90)
Caused by: org.apache.commons.dbcp.SQLNestedException: Cannot get a
connection, pool exhausted, cause: Timeout waiting for idle object
	at
org.apache.commons.dbcp.PoolingDataSource.getConnection(PoolingDataSource.ja
va:148)
	at
org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:5
18)
	at
org.apache.james.util.dbcp.JdbcDataSource.getConnection(JdbcDataSource.java:
218)
	at
org.apache.james.userrepository.AbstractJdbcUsersRepository.openConnection(A
bstractJdbcUsersRepository.java:598)
	... 8 more
Caused by: java.util.NoSuchElementException: Timeout waiting for idle object
	at
org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPoo
l.java:801)
	at
org.apache.commons.dbcp.PoolingDataSource.getConnection(PoolingDataSource.ja
va:140)
	... 11 more

This an exception from mailstore log:

23/05/04 10:31:09 ERROR mailstore: Error retrieving messageCannot get a
connection, pool exhausted0nullnull
23/05/04 10:31:09 ERROR mailstore: Exception during retrieve -- skipping
item Mail1085326264738-657
javax.mail.MessagingException: Exception while retrieving mail: Cannot get a
connection, pool exhausted
	at
org.apache.james.mailrepository.JDBCMailRepository.retrieve(JDBCMailReposito
ry.java:905)
	at
org.apache.james.mailrepository.JDBCSpoolRepository.accept(JDBCSpoolReposito
ry.java:199)
	at
org.apache.james.mailrepository.JDBCSpoolRepository.accept(JDBCSpoolReposito
ry.java:124)
	at
org.apache.james.transport.JamesSpoolManager.run(JamesSpoolManager.java:350)
	at java.lang.Thread.run(Thread.java:536)

I can certainly turn on debug level logging if it will help.

Some background:

I am the primary user of this mail server.  My M$ Outlook checks 5 different
accounts every 5 minutes.

Since I've been evaluating Mars, I've had it monitoring access for POP3 and
SMTP every minute, with a 5 second timeout.

I think it's this last point that's likely causing the problem.  Am I
expecting too much from James?  My monitoring too aggressive?

Let me know if there's anything you'd like me to try to help nail down the
problem...assuming it's not just some misconfiguration at my end.

As this seems to be a new issue, I didn't think RC4 was likely to solve it.

Thanks.

-Chris


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


RE: Possible bug in RC3 with connection pool

Posted by "Noel J. Bergman" <no...@devtech.com>.
> I've also been evaluating Mars
> (http://leapfrog-mars.sourceforge.net/)
> for monitoring services.

I've been using Mars for quite some time (you'll find a comment in the
change log when I started working with it).

> Here's the exception that's occurring in the pop3server log:

> org.apache.commons.dbcp.SQLNestedException: Cannot get a
> connection, pool exhausted, cause: Timeout waiting for idle object

> This an exception from mailstore log:

> Error retrieving message Cannot get a connection, pool exhausted0nullnull

Unfortunately, in preparing James for release, I have not had as much time
to test DBCP.  You could revert to mordred, and see if that fixes the
problem (identifying the problem as being in the connection pool, rather
than in the application), but it would be great, Chris, if you would test
the current release candidate for DBCP.  From Dirk Verbeek:

  Both DBCP and Pool are moving towards a 1.2 release.
  Release candidates for testing are available from:
  http://jakarta.apache.org/commons/pool/downloads.html
  http://jakarta.apache.org/commons/dbcp/downloads.html

  Final release target is 31 May 2004.
  Send your feedback to commons-dev mailing list please.

Commons Pool 1.1 and DBCP 1.1 are in our release candidate builds.  You
should be able to replace the JAR files with the 1.2 release candidates from
Commons.

	--- Noel


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org