Ack, with one comment, the second LOG_WA message could be more
descriptive, e.g.:
LOG_WA("Lock-instantiaton for '%s' failed, presence state is '%u'", su_name->
...
/Regards HansN
On 04/02/14 15:10, [email protected] wrote:
> osaf/services/saf/avsv/avd/avd_node.c | 9 +++++++++
> osaf/services/saf/avsv/avd/avd_su.c | 8 ++++++++
> 2 files changed, 17 insertions(+), 0 deletions(-)
>
>
> Problem: When su is either in instantiating/Terminating/restarting state and
> if either su/node lock-in operation is performed, then
> it interrupt SU states and forces component to try again.
> Ideally this condition shouldn;t arise.
>
> Analysis: WHen su is not in appropriate state, allowing lock-in admin
> operation is making su states and CLC weird.
>
> Fix: Now, Amfd is returning try again for su/node
> lock-in admin command if su is in insting/terminating/restarting state.
> Once, SU reaches to insted/term failed/inst failed/uninstantiated,
> this command can be accepted.
>
> diff --git a/osaf/services/saf/avsv/avd/avd_node.c
> b/osaf/services/saf/avsv/avd/avd_node.c
> --- a/osaf/services/saf/avsv/avd/avd_node.c
> +++ b/osaf/services/saf/avsv/avd/avd_node.c
> @@ -1081,6 +1081,15 @@ static void node_admin_op_cb(SaImmOiHand
> LOG_WA("SU on this node is undergoing admin op (%s)",
> su->name.value);
> goto done;
> }
> +
> + if ((su->saAmfSUPresenceState == SA_AMF_PRESENCE_INSTANTIATING)
> ||
> + (su->saAmfSUPresenceState ==
> SA_AMF_PRESENCE_TERMINATING) ||
> + (su->saAmfSUPresenceState ==
> SA_AMF_PRESENCE_RESTARTING)) {
> + rc = SA_AIS_ERR_TRY_AGAIN;
> + LOG_WA("'%s' presence state is '%u'", su->name.value,
> su->saAmfSUPresenceState);
> + goto done;
> + }
> +
> if (su->sg_of_su->sg_fsm_state != AVD_SG_FSM_STABLE) {
> rc = SA_AIS_ERR_TRY_AGAIN;
> LOG_WA("SG of SU on this node not in STABLE state
> (%s)", su->name.value);
> diff --git a/osaf/services/saf/avsv/avd/avd_su.c
> b/osaf/services/saf/avsv/avd/avd_su.c
> --- a/osaf/services/saf/avsv/avd/avd_su.c
> +++ b/osaf/services/saf/avsv/avd/avd_su.c
> @@ -1057,6 +1057,14 @@ static void su_admin_op_cb(SaImmOiHandle
> goto done;
> }
>
> + if ((su->saAmfSUPresenceState == SA_AMF_PRESENCE_INSTANTIATING)
> ||
> + (su->saAmfSUPresenceState ==
> SA_AMF_PRESENCE_TERMINATING) ||
> + (su->saAmfSUPresenceState ==
> SA_AMF_PRESENCE_RESTARTING)) {
> + rc = SA_AIS_ERR_TRY_AGAIN;
> + LOG_WA("'%s' presence state is '%u'", su_name->value,
> su->saAmfSUPresenceState);
> + goto done;
> + }
> +
> if ((su->saAmfSUPresenceState ==
> SA_AMF_PRESENCE_UNINSTANTIATED) ||
> (su->saAmfSUPresenceState ==
> SA_AMF_PRESENCE_INSTANTIATION_FAILED) ||
> (su->saAmfSUPresenceState ==
> SA_AMF_PRESENCE_TERMINATION_FAILED)) {
------------------------------------------------------------------------------
Put Bad Developers to Shame
Dominate Development with Jenkins Continuous Integration
Continuously Automate Build, Test & Deployment
Start a new project now. Try Jenkins in the cloud.
http://p.sf.net/sfu/13600_Cloudbees_APR
_______________________________________________
Opensaf-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensaf-devel