Hi Gary,
Ack, code review only/Thanks HansN
-----Original Message-----
From: Gary Lee <[email protected]>
Sent: den 22 augusti 2019 06:23
To: Hans Nordebäck <[email protected]>; Minh Hon Chau
<[email protected]>
Cc: [email protected]; Gary Lee <[email protected]>
Subject: [PATCH 1/1] amfd: set failover_state on standby [#3072]
Otherwise, after two controller failovers, unexpected reboot of previously
rebooted payloads may occur.
---
src/amf/amfd/node_state_machine.cc | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/amf/amfd/node_state_machine.cc
b/src/amf/amfd/node_state_machine.cc
index efe2085..d38f79e 100644
--- a/src/amf/amfd/node_state_machine.cc
+++ b/src/amf/amfd/node_state_machine.cc
@@ -63,6 +63,12 @@ void NodeStateMachine::SetState(uint32_t state) {
LOG_NO("New state '%u'", state);
}
+ // this is needed for cold sync, in case this node (currently
+ standby) // becomes active later AVD_AVND *node =
+ avd_node_find_nodeid(node_id_); osafassert(node != nullptr);
+ node->failover_state = state;
+
switch (state) {
case NodeState::kStart:
state_ = std::make_shared<Start>(this);
--
2.7.4
_______________________________________________
Opensaf-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensaf-devel