Stop/Pause/Resume service events on a standalone Web application

How a standalone Web application running as a Windows service can trap/handle the Stop/Pause/Resume events generated by the Service Manager?
In a ServiceApplication there are Resume/Stop/Pause events but not on a web application.

Thank you.

File a feature request. They’re there, we’re just using them.

Done, case #29283.

Best regards.

It would also be useful to have access to signals (SIGHUP, etc.) in os x and linux.

Now that the events are implemented, we need a means of pausing and resuming new connections so that when a Windows administrator pauses our Service (aka Web App), we have a means to stop accepting new connections until they resume our Service.

<> WebApplication - Pause/Resume Accepting Connections

Just to be clear, that’s not what that case requests. The case requests that you would stop accepting connections, which would mean calling StopListening, but it sounds like what you want here is the ability to prevent new sessions from being created. You should put that information on the case because it is a completely different (and more complicated) ball of wax.

Sorry I was not more clear. Being able to call StopListening/Listen to pause/resume accepting new connections would be great, especially if that’s relatively easy for you to implement.

For sure having also this feature would be useful.

In my opinion being able to stop listening to pause accepting new connections must be something that must be done, in any case, under control of the application i.e. not done automatically by Xojo framework without application supervision.

To me it has a much wider meaning “pause a service” when we are speaking about a service accessible remotely by Web.
“Pausing a web service” means that you can’t connect to the service itself using a browser or the service must suspend some specific processing and continue to have a user interface active?

It is more correct to notify user that the service it is paused from some voluntary action than leaving the user in a state where it doesn’t know if the service was never started, terminated or faulted.

Please add these comments to the case.