2

I am struggling to understand how session variables are managed when using a connection pool on every documentation I am reading the definition of session variable is

Session variables

Session variables are set in the scope of your session with the MySQL server.

A session starts with a connection to the server and ends when the connection is closed. Variables go out of scope once the connection is terminated.

for example : http://www.java2s.com/Tutorial/MySQL/0201__Procedure-Function/LOCALSESSIONANDGLOBALVARIABLESINMYSQL.htm

if we're using a connection pool the connection is not really getting close or terminated does it mean we need to reset the session variable at the end of the transaction?

Naor Tedgi
  • 4,065
  • 2
  • 20
  • 43

0 Answers0