Hi. On 2016-08-07T16:26:16 +0200 <e...@zusammenkunft.net> wrote:
> Hello, > > Although it is not good practice to sleep/block I think it is natural to wait > till the component is shut down. Right. I think it's a matter of interpretation. The compendium spec doesn't seem to say one way or the other. I think if the contract of the deactivate() method was specified as "When the deactivate method returns without raising an exception, the component is assumed to have been shut down correctly" then there'd be no question; you'd *have* to wait for the shut down in the method to obey the contract. > > On the other hand startup problems with port binding code are so common, it > does not hurt to code this in a retrying thread as well. Then the started > server will recover from the port becoming available later on. Only problem with that is that there's no way short of parsing implementation-specific error messages to distinguish between a transient "the address is still in use" error and a permanent "this address doesn't exist" error. Worse, even if it could be determined that the address does exist but is currently taken unambiguously, we don't know enough to say if that's because there's a previous dying service still hanging around, or if there's something already running there (suggesting a misconfiguration). M
pgpy0r2B0Lptg.pgp
Description: OpenPGP digital signature
_______________________________________________ OSGi Developer Mail List osgi-dev@mail.osgi.org https://mail.osgi.org/mailman/listinfo/osgi-dev