Control node crash when handling config client reinit:
The config client can be reinit through a signal or if some config
params changed. While processing the reinit, the config manager tries
to shutdown and recreate the config db client. The config client and
its associated partition tasks cannot be running since they are
mutually exclusive tasks to the client init task and this is a valid
assumption. However, it is possible that the tasks have been scheduled
to run but yet to begin execution. If that is the case and we try to
shutdown the config db client/partition, TaskTriggers assert if there
are scheduled tasks. This is not a problem for WorkQueue and Task
classes. Fixing this for TaskTrigger tasks by checking if they have
been scheduled and retrying the config init.
UT will be done at a later time when the test infra for reinit code
is added. For now, verified that the config client tests pass.
Change-Id: Id6d9c6aed32d32688d88932a8ec6c85a5207ad28
Partial-Bug: 1786154
(cherry picked from commit 8ae5f21f9cbb7e4b5771db25fe2c2d7a0dd6d658)
Reviewed: https:/ /review. opencontrail. org/46183 github. com/Juniper/ contrail- common/ commit/ 39a4814b15cce9d a235c00127a52cb f41e27125b
Committed: http://
Submitter: Zuul v3 CI (<email address hidden>)
Branch: R5.0
commit 39a4814b15cce9d a235c00127a52cb f41e27125b
Author: Mahesh Sivakumar <email address hidden>
Date: Tue Aug 14 16:15:57 2018 -0700
Control node crash when handling config client reinit:
The config client can be reinit through a signal or if some config
params changed. While processing the reinit, the config manager tries
to shutdown and recreate the config db client. The config client and
its associated partition tasks cannot be running since they are
mutually exclusive tasks to the client init task and this is a valid
assumption. However, it is possible that the tasks have been scheduled
to run but yet to begin execution. If that is the case and we try to
shutdown the config db client/partition, TaskTriggers assert if there
are scheduled tasks. This is not a problem for WorkQueue and Task
classes. Fixing this for TaskTrigger tasks by checking if they have
been scheduled and retrying the config init.
UT will be done at a later time when the test infra for reinit code
is added. For now, verified that the config client tests pass.
Change-Id: Id6d9c6aed32d32 688d88932a8ec6c 85a5207ad28 b5771db25fe2c2d 7a0dd6d658)
Partial-Bug: 1786154
(cherry picked from commit 8ae5f21f9cbb7e4