Ticket #649 (closed defect: fixed)
logsv: re-initialization of IMM handle is sometimes sluggish
| Reported by: | anders | Owned by: | anders |
|---|---|---|---|
| Priority: | minor | Milestone: | 3.0.1 |
| Component: | saf/logsv | Version: | 3.0.0 |
| Keywords: | Cc: | ||
| patch waiting for maintainer: | yes |
Description
If the IMMND crashes on the node where the LOG-OI resides, the LOG-OI will get a BAD_HANDLE return code on the saImmOiDispatch call.
It handles this case by:
invalidating the handle
removing the IMM file descriptor from the polling array
starting a thread to reinitialize the handle + selection object.
In the meantime the LOGSv is available for normal LOG service.
It is simply not receptive for reconfigurations or providing
runtime data.
When the re-init thread has successfully reinitialized the handle
and selection object, it adds the fresh IMM file descriptor to
the pollign array.
The problem is that by this time, the main thread is typically already blocked on a poll that ignores the fresh IMM descriptor.
The poll has to return once before the fresh descriptor is noticed
(in the next poll).
This will happen at least by the next health check call from the AMF.
But the health check period is quite long, which makes the LOG-OI
unnecessarily sluggish in picking up the new descriptor.
The fix is for the re-init thread to send an internal empty IPC
message before terminating, which will force the main thread to
return from the poll.
