File tree Expand file tree Collapse file tree 4 files changed +5
-6
lines changed
Expand file tree Collapse file tree 4 files changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -473,6 +473,7 @@ int main(int argc, char **argv)
473473 SWSS_LOG_ERROR (" Invalid input for heartbeat interval: %d. use default interval: %ld" , interval, heartBeatInterval);
474474 }
475475 }
476+ break ;
476477 case ' R' :
477478 gRingMode = true ;
478479 break ;
Original file line number Diff line number Diff line change @@ -375,7 +375,8 @@ void Executor::pushRingBuffer(AnyTask&& task)
375375
376376void Consumer::drain ()
377377{
378- m_orch->doTask (*this );
378+ if (!m_toSync.empty ())
379+ ((Orch *)m_orch)->doTask ((Consumer&)*this );
379380}
380381
381382size_t Orch::addExistingData (const string& tableName)
Original file line number Diff line number Diff line change @@ -928,7 +928,6 @@ void OrchDaemon::start(long heartBeatInterval)
928928
929929 if (gRingBuffer )
930930 {
931-
932931 if (!gRingBuffer ->IsEmpty () || !gRingBuffer ->IsIdle ())
933932 {
934933 gRingBuffer ->notify ();
@@ -958,9 +957,10 @@ void OrchDaemon::start(long heartBeatInterval)
958957 * execute all the remaining tasks that need to be retried. */
959958
960959 if (!gRingBuffer || (gRingBuffer ->IsEmpty () && gRingBuffer ->IsIdle ()))
960+ {
961961 for (Orch *o : m_orchList)
962962 o->doTask ();
963-
963+ }
964964 /*
965965 * Asked to check warm restart readiness.
966966 * Not doing this under Select::TIMEOUT condition because of
@@ -971,7 +971,6 @@ void OrchDaemon::start(long heartBeatInterval)
971971 bool ret = warmRestartCheck ();
972972 if (ret)
973973 {
974-
975974 // Orchagent is ready to perform warm restart, stop processing any new db data.
976975 // but should finish data that already in the ring
977976 if (gRingBuffer )
Original file line number Diff line number Diff line change @@ -115,15 +115,13 @@ class OrchDaemon
115115
116116 std::vector<Orch *> m_orchList;
117117 Select *m_select;
118-
119118 std::chrono::time_point<std::chrono::high_resolution_clock> m_lastHeartBeat;
120119
121120 void flush ();
122121
123122 void heartBeat (std::chrono::time_point<std::chrono::high_resolution_clock> tcurrent, long interval);
124123
125124 void freezeAndHeartBeat (unsigned int duration, long interval);
126-
127125};
128126
129127class FabricOrchDaemon : public OrchDaemon
You can’t perform that action at this time.
0 commit comments