|
|
|
CannotCreateTransactionException: Could not open JDBC Connection for transaction
|
|||
|---|---|---|---|
|
#18+
Добрый день! Последнее время возникает ошибка получения соединения. Опишу ситуацию. Есть сервер, где крутится томкат. На нем крутятся сервисы. Ночью пропадает коннект, что ведет к ошибке Код: java 1. 2. Файл context.xml(Самого сервиса), где описывается коннект Код: xml 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. Проблема в том, что в логах томката подробной инфы нет. Есть идеи у кого нибудь, почему вдруг может пропадать вот так коннект? P.S.: Есть варианты, что превышается число активных сессий, из за этого может быть? И как можно получить более детальное логгирование попытки соединения с БД? ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 27.03.2013, 13:16:14 |
|
||
|
CannotCreateTransactionException: Could not open JDBC Connection for transaction
|
|||
|---|---|---|---|
|
#18+
stacktrace приведите. Довольно странно что пул умудрился вернуть null. ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 27.03.2013, 13:43:22 |
|
||
|
CannotCreateTransactionException: Could not open JDBC Connection for transaction
|
|||
|---|---|---|---|
|
#18+
RTFMConnectionWaitTimeout Specifies cache behavior when a connection is requested and there are already MaxLimit connections active. If ConnectionWaitTimeout is greater than zero, then each connection request waits for the specified number of seconds or until a connection is returned to the cache. If no connection is returned to the cache before the timeout elapses, then the connection request returns null. Default: 0 (no timeout) ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 27.03.2013, 13:45:53 |
|
||
|
CannotCreateTransactionException: Could not open JDBC Connection for transaction
|
|||
|---|---|---|---|
|
#18+
Код: java 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. 17. 18. 19. 20. 21. 22. 23. 24. 25. 26. 27. 28. 29. 30. 31. 32. 33. 34. 35. 36. 37. 38. 39. 40. 41. 42. 43. 44. 45. 46. 47. 48. 49. 50. 51. 52. 53. 54. 55. 56. 57. ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 27.03.2013, 13:46:24 |
|
||
|
CannotCreateTransactionException: Could not open JDBC Connection for transaction
|
|||
|---|---|---|---|
|
#18+
BlazkowiczRTFMConnectionWaitTimeout Specifies cache behavior when a connection is requested and there are already MaxLimit connections active. If ConnectionWaitTimeout is greater than zero, then each connection request waits for the specified number of seconds or until a connection is returned to the cache. If no connection is returned to the cache before the timeout elapses, then the connection request returns null. Default: 0 (no timeout) То есть получается, что нет временного ожидания и он сразу возвращает NULL когда(судя по моему конфигу) есть 5 подключений? ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 27.03.2013, 13:49:25 |
|
||
|
CannotCreateTransactionException: Could not open JDBC Connection for transaction
|
|||
|---|---|---|---|
|
#18+
Timoshenko ArthurТо есть получается, что нет временного ожидания и он сразу возвращает NULL когда(судя по моему конфигу) есть 5 подключений? Странно, конечно. Доожен вешаться до освобождения соединения по логике. ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 27.03.2013, 14:00:21 |
|
||
|
CannotCreateTransactionException: Could not open JDBC Connection for transaction
|
|||
|---|---|---|---|
|
#18+
3.1.5 Logging and Tracing http://docs.oracle.com/cd/B14117_01/java.101/b10979/urls.htm ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 27.03.2013, 14:01:28 |
|
||
|
CannotCreateTransactionException: Could not open JDBC Connection for transaction
|
|||
|---|---|---|---|
|
#18+
BlazkowiczTimoshenko ArthurТо есть получается, что нет временного ожидания и он сразу возвращает NULL когда(судя по моему конфигу) есть 5 подключений? Странно, конечно. Доожен вешаться до освобождения соединения по логике. По идее да. Должен висеть и ждать(( Увеличим MaxLimit и выставлю ConnectionWaitTimeout=600. Посмотрим, что получится. ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 27.03.2013, 14:22:27 |
|
||
|
CannotCreateTransactionException: Could not open JDBC Connection for transaction
|
|||
|---|---|---|---|
|
#18+
Спасибо большое за помощь. Ошибка пока что не возникала. Установил MaxLimit и ConnectionWaitTimeout. Пока что соединение стабильно и не падает. В итоге получился вот такой конфиг(может, кому-то надо): Код: xml 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 28.03.2013, 10:35:04 |
|
||
|
|

start [/forum/topic.php?fid=59&msg=38200421&tid=2129677]: |
0ms |
get settings: |
14ms |
get forum list: |
29ms |
check forum access: |
8ms |
check topic access: |
8ms |
track hit: |
67ms |
get topic data: |
22ms |
get forum data: |
6ms |
get page messages: |
100ms |
get tp. blocked users: |
3ms |
| others: | 298ms |
| total: | 555ms |

| 0 / 0 |
