Olympia crashes in a failover environment

Hi,

We use Olympia as a service with SQL Server (failover) as backend DB. When the secondary server takes over from the primary, Olympia crashes.

Is there something we can do to solve this problem?

Regards,

Filip.

Hello

Could you elaborate what exactly happens?

Thanks in advance

Our SQL 2016 has been set up in High Availability (AAG): this means clients connect to a single DNS name/IP (“listener”): from this IP on, the traffic is redirected to the correct (running) SQL instance. For applications this behaviour is completely transparent, except in case the SQL environment switches between servers, a brief disconnect on the communication with the listener occurs.

For Delphi client/server application (with a persistent ADO connection) this implies the ADO connection needs to reconnect. For stateless applications (not keeping a persistent connection to the database) this switch should be completely transparent.

We would have expected the Olympia server is stateless to the database, be we notice error messages when the switch occurs.

Regards,

Filip

Hello

What exactly error messages do you get? If possible could you attech a debugger instance to the servrer and provide exact exception message and stacktrace.

Also which exactly Olympia version do you run (please check the Olympia exe’s file properties and say the ‘File version’ property value)?

Depending on the connection settings Olympia might use internal connection pool. However is clears this internal pool when a db access exception occurs.

So I need the version # and exact error message to diagnose what causes the issue.

Thanks in advance

Hi Anton,

Thanks for your message.

We use Olympia v9.0.97.1245
I run the test via the SessionTypes demo. On client side I get the following error “An exception was raised on the server: Error connecting to Olympia Server. Please run the Olympia Server before attempting to store session data in the Olympia session manager.”

Debugging the serverapp results in following error EROUnregisteredServerException with message A transport-level error has occurred when sending the request to the server. (provider: TCP Provider, error: 0 – An existing connection was forcibly closed by the remote host.)
Followed by a EIdSocketError with message 'SocketError # 10053 Software caused connection abort.
Followed by the ‘client message’ stated above.

Stack:
:76495b68 KERNELBASE.RaiseException + 0x48
uROMessage.TROMessage.ProcessException
uROBinMessage.TROBinMessage.IntReadFromStream(???,False)
uROBinMessage.TROBinMessage.ReadFromStream($30F9380,???)
uROTransportChannel.TROTransportChannel.Dispatch(TROBinMessage($211E66C) as IROMessage)
ROOlympia_Intf.TOlympiaSessionManager_Proxy.ReadSession(’{840EC3F5-A5E6-4938-9905-C5250C7F34A3}’)
uROOlympiaSessionManager.TROOlympiaSessionManager.DoFindSession((2215560181, 42470, 18744, (153, 5, 197, 37, 12, 127, 52, 163)),???)
uROSessions.TROCustomSessionManager.FindSession((2215560181, 42470, 18744, (153, 5, 197, 37, 12, 127, 52, 163)),True)
uRORemoteDataModule.TRORemoteDataModule.DoOnActivate((2215560181, 42470, 18744, (153, 5, 197, 37, 12, 127, 52, 163)),???)
uRORemoteDataModule.TRORemoteDataModule._OnActivate((52755672, 64165, 103, (136, 4, 23, 2, 12, 229, 17, 2)),TROBinMessage($211E50C) as IROMessage)
uROServer.TROInvoker.BeforeInvoke((uRORTTIServerSupport.TRORTTIInvoker.RTTIInvoke,$21B34E0),TSessionTypesService($2108914) as IInterface,???,TROBinMessage($211E50C) as IROMessage,TROSCServerWorker($2170488) as IROTransport)
uROServer.TROInvoker.CustomHandleMessage(TROClassFactory($21CF924) as IROClassFactory,TROBinMessage($211E50C) as IROMessage,TROSCServerWorker($2170488) as IROTransport,[])
uROServer.TROInvoker.HandleMessage(???,???,TROSCServerWorker($2170488) as IROTransport,[])
uROServer.MainProcessMessage(TROBinMessage($211E50C) as IROMessage,TROSCServerWorker($2170488) as IROTransport,???,$2166560,[],True)
uROServer.TROMessageDispatcher.ProcessMessage(TROSCServerWorker($2170488) as IROTransport,$21664C0,$2166560,[],True)
uROServer.TROServer.IntDispatchMessage($21D0080,TROSCServerWorker($2170488) as IROTransport,$21664C0,$2166560,[])
uROServer.TROServer.DispatchMessage(TROSCServerWorker($2170488) as IROTransport,$21664C0,$2166560,[])
uROServer.TROServer.DispatchMessage(???,???,$2166560)
uROBaseSuperTCPServer.TROInvokerQueueItem.Callback(???,???)
uROThreadPool.TROPooledThread.IntExecute
uROInitializedThread.TROInitializedThread.Execute
:004c4f48 ThreadProc + $4C
:00409fc2 ThreadWrapper + $2A
:767a7c04 KERNEL32.BaseThreadInitThunk + 0x24
:7773ab8f ntdll.RtlInitializeExceptionChain + 0x8f
:7773ab5a ntdll.RtlInitializeExceptionChain + 0x5a

Reproducing the problem is straight forward. Start client & server from the Session Types demo (of course using the OlympiaSessionManager). On client side choose a UserID - click Login - simulate a failover on SQL Server - click Get Session Manager Name - error occurs.
When Olympia runs as a service, Olympia stops running.

Regards,

Filip.

Hello

Could you check Windows Events logs for error message?

Also please drop a mail to support@ I’ll try to provide you a custom build with possible workaround and extended diagnostics capabilities.

Thanks in advance