hi marco!
i have serious problems with oracle/doa since a firewall between my server with doa and oracle db has been errected. new policy dumps the physical db connection between my host (with OracleClient) and db itself after 2h of inactivity.
bad thing: no exception raises, pool "thinks" there is a free connection and all fine - yet the sql goes nirvana and server request just voids - waiting and waiting.
it lasted some time after i realised the firewal kills the connection, yet the question was why the server refuses to react.
well, you have radther mean loop in
procedure TOracleSessionPool.Reserve(ASession: TOracleSession);
repeat
Space := (Max LOWEREQUAL 0) or (FreeCount NOTEQUAL 0);
if not Space then Sleep(10);
until Space;
which waits for a connection to be freed, which under the circumstances NEVER happens... deadlock.
so, i tried to set TOracleSession.Timeout Parameter to something0 just to realise:
1) pool calls "compressOld" ONLY after one reserve takes place - implemented timer, no big deal.
BUT:
2) if Timerout NOTEQUAL 0 the session pool itself is rendered trash because no POOL as such is given any more: simple testing with one query in the loopx500 results with 500 connections generated by pool itself - regardles what value MAX is set to!!!
i'm under rather heavy stress because servers go nirvana on regular basis - please check the code & give me some explanation/fix asap, cause the roof is on fire & have no time to check it by myself.
tia,
cvarak
i have serious problems with oracle/doa since a firewall between my server with doa and oracle db has been errected. new policy dumps the physical db connection between my host (with OracleClient) and db itself after 2h of inactivity.
bad thing: no exception raises, pool "thinks" there is a free connection and all fine - yet the sql goes nirvana and server request just voids - waiting and waiting.
it lasted some time after i realised the firewal kills the connection, yet the question was why the server refuses to react.
well, you have radther mean loop in
procedure TOracleSessionPool.Reserve(ASession: TOracleSession);
repeat
Space := (Max LOWEREQUAL 0) or (FreeCount NOTEQUAL 0);
if not Space then Sleep(10);
until Space;
which waits for a connection to be freed, which under the circumstances NEVER happens... deadlock.
so, i tried to set TOracleSession.Timeout Parameter to something0 just to realise:
1) pool calls "compressOld" ONLY after one reserve takes place - implemented timer, no big deal.
BUT:
2) if Timerout NOTEQUAL 0 the session pool itself is rendered trash because no POOL as such is given any more: simple testing with one query in the loopx500 results with 500 connections generated by pool itself - regardles what value MAX is set to!!!
i'm under rather heavy stress because servers go nirvana on regular basis - please check the code & give me some explanation/fix asap, cause the roof is on fire & have no time to check it by myself.
tia,
cvarak