Re: Right version of jdbc

Поиск
Список
Период
Сортировка
От Craig McIlwee
Тема Re: Right version of jdbc
Дата
Msg-id CAGqBcTYn7vpx2T+-AM_kS7fszGZfZMULLZw6DqXe=Dq6TnCkNQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Right version of jdbc  (Dave Cramer <davecramer@postgres.rocks>)
Ответы Re: Right version of jdbc
Список pgsql-general
> for some reason the postgresql jar is not in the classpath.

This is due to the way that Tomcat loads drivers, which is documented at [1].  In short, the JDBC driver should be placed in the tomcat/lib directory and removed from the application's WEB-INF/lib directory.  After doing that, I was able to get past the "No suitable driver" exception.

OP, you should read that entire page, and in particular the portion at [2].  By registering a "Resource" with Tomcat, you can let it manage a connection pool for you (if you aren't already using something like PgBouncer or pgpool) and, if registered at the container level, in the future you can share that pool across all of your web applications in the container.


Craig

В списке pgsql-general по дате отправления:

Предыдущее
От: postgresql439848@heinz-it.de
Дата:
Сообщение: Re: Right version of jdbc
Следующее
От: pf@pfortin.com
Дата:
Сообщение: cache lookup failed for function 0