the idea to e.g. be able to cleanup extensions on plugin unload is starting to grow on me
I wouldn't do that, extensions should just behave correctly. And if the plugin is unloaded and the extension is still registered, there will probably be a huge crash that the extension developer notices (not sure what happens with resident plugins in this case which the LSP plugin is).