Dear List,<div><br></div><div>My very first post in the dev mailing list, as I am going to spend much more time in my personal OpenSim.</div><div><br></div><div>I have written some code quite a while back and wanted to share my thoughts and start a discussion about it.</div>
<div><br></div><div><b>Signal Handling</b></div><div>Currently, OpenSim services do NOT support POSIX signal handling when POSIX is available. This support is available</div><div>on pretty much any *nix platform including MacOS X. Windows does NOT support POSIX period.</div>
<div><br></div><div>In Mono, POSIX signal handling can be easily accomplished using the mono.posix.dll.</div><div><br></div><div>I have currently implemented nothing more but the TERM signal, to ensure the services are properly stopped, instead of</div>
<div>simply killed on the spot. This means that the service actually goes through the shutdown procedure (if any).</div><div>The next goal would be to implement HUP to reload the service.</div><div><br></div><div>My current problem, is that the code is just there. No ifdef statements, nothing.</div>
<div>I simply lack the knowledge in .NET/Mono to exclude the code from an environment that does not include posix.</div><div>Some pointers in the right direction would be much appreciated.</div><div><br></div><div><b>Discussion</b></div>
<div>When creating services, there must be an easy way to start/stop them. Especially on *nix this comes in handy.</div><div>Shoving the word "exit" or "shutdown" into the service cli is just not working all the time and is error prone.</div>
<div><br></div><div>Adding POSIX signal handling would be considered "standard" in such services. The fact that MS Windows does not</div><div>support POSIX signals is simply disregarded. The equivalent on Windows would be to have a service binary that runs</div>
<div>the OpenSim services (I think that already exists).</div><div><br></div><div>There aren't that many other "standard" solutions to the same problem, and although signal handling wouldn't work on</div>
<div>ONE platform (ONE being Windows), it is guaranteed to work on ALL others (ALL being the *nix ones lol).</div><div><br></div><div>So to start the discussion, here are some questions:</div><div>1. Is there any interest in this code?</div>
<div>With this I mean: would we want POSIX signal handling or will we try to develop a different way to solve the same problem?</div><div>2. If there is any interest, who do I send my patch to?</div><div><br></div><div>With kind regards,</div>
<div>Rory Slegtenhorst<br>rory dot slegtenhorst at gmail dot com<br>
</div>