Menu

#72 Application freezes after database connection timeout

Unknown
closed
None
2017-03-02
2014-05-18
No

I have a problem using ZeosDBO 7.1.3 stable using a Postgres 9 database. Everything works fine but if I don't touch the program for a few minutes and then execute a database action, the application freezes.

madExcept shows the following stacktrace:
main thread ($1ae4):
ntdll.dll NtWaitForSingleObject
WS2HELP.dll WahReferenceContextByHandle
WS2_32.dll select
ZPlainPostgreSqlDriver 1215 +2 TZPostgreSQLBaseDriver.ExecPrepared
ZDbcPostgreSqlStatement 858 +14 TZPostgreSQLCAPIPreparedStatement.ExectuteInternal
ZDbcPostgreSqlStatement 1127 +10 TZPostgreSQLCAPIPreparedStatement.ExecuteQueryPrepared
ZAbstractRODataset 1722 +25 TZAbstractRODataset.CreateResultSet
ZAbstractDataset 330 +1 TZAbstractDataset.CreateResultSet
ZAbstractRODataset 1751 +16 TZAbstractRODataset.InternalOpen
ZAbstractRODataset 2477 +34 TZAbstractRODataset.InternalRefresh
DB 10588 +5 TDataSet.Refresh

I suppose this is about a connection timeout on either side that is not properly detected by ZEOSLib? Is this a cause of misconfiguration? Can I implement a "Reconnect on timeout" globally for an application?

Discussion

  • EgonHugeist

    EgonHugeist - 2014-06-20

    Hi Michael,

    reconnect on timeout is not supported yet. Have no idea how to do this. Are there article you could point us? Or coud you do it by your selves and share your code?

    Michael

     
  • Michael Stieler

    Michael Stieler - 2014-06-21

    thanks for the response, as I read it I thought about why not simply increasing the timeout on server side. could be an easy solution...

     
  • EgonHugeist

    EgonHugeist - 2017-03-02
    • status: open --> closed
    • assigned_to: EgonHugeist
     
  • EgonHugeist

    EgonHugeist - 2017-03-02

    Not reproducable however..

     

Log in to post a comment.

MongoDB Logo MongoDB