I tried to understand from the OSGi specs what it should happen in case an activate method blocks indefinitely but I did not find an answer. On the other hand, it seams that that Felix SCR has ds.lock.timeout.milliseconds
and ds.stop.timeout.milliseconds
properties to manage activate/deactivate timeouts, right?
Questions:
- Why OSGi specs do not mention activate/deactivate deadlock management?
- In case a DS needs more time to run its activate method, is it wise to increase the default SCR
ds.lock.timeout.milliseconds
value? Or is it better to avoid the activate method altogether and register the service "by hand" usingcontext.registerService
in a dedicated thread?