howto run startup code AFTER full reload

I want to run startup code that uses a plugin, but when i want to use this in the lua startup code i get;

Device_LuaUPnP::HandleActionRequest 50 not ready 0xc78ef0

In the logging i found that the plugin is initialized after running the startup code.
So basically i need to know if the plugin is loaded OR need to find out if the startup sequence is ready.

Is this possible or does somebody know a better solution?

The startup code is indeed run early in the sequence, so it’s quite possible that some plugins are not ready. A straight-forward way around this is to delay activation of a named startup function through the use of [tt]luup.call_delay[/tt], see: [url=http://wiki.micasaverde.com/index.php/Luup_Lua_extensions#function:_call_delay]http://wiki.micasaverde.com/index.php/Luup_Lua_extensions#function:_call_delay[/url]

I was already looking to that and was also testing with is_ready() but it looks like that online works for devices and not for plugins.

If somebody has another solution;
Let us/me know!! ;D

I never found a better solution than delay-and-retry. That’s what I implemented in the UPnP Event Proxy plugin, which runs outside of LuaUPnP and has to be robust about messages that it sends to plugins, even if they are in the middle of a reload.