DaveL17 wrote:I never thought about using shutdown() with a server shutdown, but that makes sense. Do running plugins always shut down in alphabetical order? If that's the case, would "zzzPlugin" be "guaranteed" last to go?
First, remember that shutdown() will also be called if the plugin is disabled or restarted - so you're not guaranteed that the server is also shutting down.
There is no explicit order of plugin shutdowns (that is, there is an order, but we don't publish it because it probably will change periodically as we do more backend server work so you shouldn't assume there is).