8 #include <boost/statechart/custom_reaction.hpp>
9 #include <boost/statechart/state.hpp>
10 #include <boost/statechart/state_machine.hpp>
11 #include <boost/statechart/transition.hpp>
23 #include "bgp/bgp_peer_types.h"
30 using std::ostringstream;
33 namespace mpl = boost::mpl;
34 namespace sc = boost::statechart;
41 getenv(
"CONTRAIL_BGP_IDLE_HOLD_TIME_MSECS") ?
42 strtol(getenv(
"CONTRAIL_BGP_IDLE_HOLD_TIME_MSECS"), NULL, 0) : 5000;
46 #define SM_LOG(level, _Msg) \
50 if (LoggingDisabled()) break; \
51 BGP_LOG_SERVER(peer_, (BgpTable *) 0); \
52 BGP_LOG(BgpPeerStateMachine, level, \
53 BGP_LOG_FLAG_SYSLOG, BGP_PEER_DIR_NA, \
54 peer_ ? peer_->ToUVEKey() : "", \
58 #define SM_LOG_NOTICE(_Msg) \
62 if (LoggingDisabled()) break; \
63 BGP_LOG_SERVER(peer_, (BgpTable *) 0); \
64 BGP_LOG_NOTICE(BgpPeerStateMachine, \
65 BGP_LOG_FLAG_SYSLOG, BGP_PEER_DIR_NA, \
66 peer_ ? peer_->ToUVEKey() : "", \
78 static const char *
Name() {
86 static const char *
Name() {
95 static const char *
Name() {
96 return "EvIdleHoldTimerExpired";
109 return "EvConnectTimerExpired";
130 return "EvOpenTimerExpired";
147 return "EvHoldTimerExpired";
166 return "EvTcpConnected";
179 return "EvTcpConnectFail";
192 return "EvTcpPassiveOpen";
218 return "EvTcpDeleteSession";
229 data = std::string((
const char *)_data, data_size);
232 return "EvBgpHeaderError";
245 "Open " <<
msg->ToString());
257 boost::shared_ptr<const BgpProto::OpenMessage>
msg;
262 const uint8_t *_data = NULL,
size_t data_size = 0)
270 data = std::string((
const char *)_data, data_size);
274 return "EvBgpOpenError";
289 log_level = SandeshLevel::SYS_INFO;
295 return "EvBgpKeepalive";
313 return "EvBgpNotification";
322 boost::shared_ptr<const BgpProto::Notification>
msg;
330 return "EvBgpUpdate";
334 boost::shared_ptr<const BgpProto::Update>
msg;
343 return "EvBgpUpdateError";
359 template <
typename Ev,
int code = 0>
371 template <
typename Ev>
377 template <
typename Ev>
380 &StateMachine::OnIdle<Ev, BgpProto::Notification::FSMErr> >
reaction;
383 template <
typename Ev,
int code>
393 struct Idle : sc::state<Idle, StateMachine> {
396 sc::custom_reaction<EvStart>,
397 sc::custom_reaction<EvIdleHoldTimerExpired>,
398 sc::custom_reaction<EvTcpPassiveOpen>
407 explicit Idle(my_context ctx) : my_base(ctx) {
431 return transit<Active>();
433 return discard_event();
438 return transit<Active>();
446 return discard_event();
455 struct Active : sc::state<Active, StateMachine> {
458 sc::custom_reaction<EvConnectTimerExpired>,
459 sc::custom_reaction<EvOpenTimerExpired>,
460 sc::custom_reaction<EvTcpPassiveOpen>,
461 sc::custom_reaction<EvTcpClose>,
462 sc::custom_reaction<EvBgpOpen>,
477 explicit Active(my_context ctx) : my_base(ctx) {
497 return discard_event();
499 return transit<Connect>();
510 return transit<OpenSent>();
512 return discard_event();
524 return discard_event();
535 return discard_event();
550 return discard_event();
556 return discard_event();
564 return discard_event();
565 return transit<OpenConfirm>();
573 struct Connect : sc::state<Connect, StateMachine> {
576 sc::custom_reaction<EvConnectTimerExpired>,
577 sc::custom_reaction<EvOpenTimerExpired>,
578 sc::custom_reaction<EvTcpConnected>,
579 sc::custom_reaction<EvTcpConnectFail>,
580 sc::custom_reaction<EvTcpPassiveOpen>,
581 sc::custom_reaction<EvTcpClose>,
582 sc::custom_reaction<EvBgpOpen>,
594 explicit Connect(my_context ctx) : my_base(ctx) {
613 return transit<Active>();
625 return transit<OpenSent>();
636 return transit<OpenSent>();
644 return transit<Active>();
654 return discard_event();
665 return discard_event();
671 return transit<Active>();
687 return discard_event();
693 return discard_event();
703 return discard_event();
704 return transit<OpenConfirm>();
715 struct OpenSent : sc::state<OpenSent, StateMachine> {
718 sc::custom_reaction<EvOpenTimerExpired>,
721 sc::custom_reaction<EvTcpPassiveOpen>,
722 sc::custom_reaction<EvTcpClose>,
723 sc::custom_reaction<EvBgpOpen>,
724 sc::custom_reaction<EvBgpNotification>,
758 return discard_event();
773 return transit<Active>();
775 return discard_event();
789 return transit<Active>();
797 return transit<Active>();
800 return discard_event();
813 if (event.
msg->identifier > local_bgp_id) {
818 "Connection collision - closing active session");
835 if (event.
session != session) {
836 return discard_event();
845 "Connection collision - closing passive session");
856 if (event.
session != session) {
857 return discard_event();
870 if (event.
session != session) {
871 return discard_event();
883 if (event.
session != session) {
884 return discard_event();
893 return discard_event();
894 return transit<OpenConfirm>();
903 return discard_event();
913 return discard_event();
921 return transit<Active>();
923 return discard_event();
927 return transit<Idle, StateMachine, EvBgpNotification>(
928 &StateMachine::OnIdle<EvBgpNotification, 0>, event);
942 sc::custom_reaction<EvTcpPassiveOpen>,
945 sc::custom_reaction<EvBgpNotification>,
946 sc::custom_reaction<EvBgpKeepalive>,
983 "Connection rejected - unexpected passive session");
985 return discard_event();
992 return discard_event();
994 return transit<Idle, StateMachine, EvBgpNotification>(
995 &StateMachine::OnIdle<EvBgpNotification, 0>, event);
1003 StateMachine *state_machine = &context<StateMachine>();
1005 return transit<Idle, StateMachine, EvBgpKeepalive>(
1006 &StateMachine::OnIdle<EvBgpKeepalive, 0>, event);
1008 return transit<Established>();
1021 sc::custom_reaction<EvTcpPassiveOpen>,
1025 sc::custom_reaction<EvBgpKeepalive>,
1026 sc::custom_reaction<EvBgpUpdate>,
1035 StateMachine *state_machine = &context<StateMachine>();
1045 StateMachine *state_machine = &context<StateMachine>();
1054 StateMachine *state_machine = &context<StateMachine>();
1061 return discard_event();
1066 StateMachine *state_machine = &context<StateMachine>();
1068 return discard_event();
1073 StateMachine *state_machine = &context<StateMachine>();
1076 return discard_event();
1083 : work_queue_(
TaskScheduler::GetInstance()->GetTaskId(
"bgp::StateMachine"),
1084 peer->GetTaskInstance(),
1087 active_session_(NULL),
1088 passive_session_(NULL),
1089 connect_timer_(
TimerManager::CreateTimer(*peer->server()->ioservice(),
1091 TaskScheduler::GetInstance()->GetTaskId(
"bgp::StateMachine"),
1092 peer->GetTaskInstance())),
1093 open_timer_(
TimerManager::CreateTimer(*peer->server()->ioservice(),
1095 TaskScheduler::GetInstance()->GetTaskId(
"bgp::StateMachine"),
1096 peer->GetTaskInstance())),
1097 hold_timer_(
TimerManager::CreateTimer(*peer->server()->ioservice(),
1099 TaskScheduler::GetInstance()->GetTaskId(
"bgp::StateMachine"),
1100 peer->GetTaskInstance())),
1101 idle_hold_timer_(
TimerManager::CreateTimer(*peer->server()->ioservice(),
1103 TaskScheduler::GetInstance()->GetTaskId(
"bgp::StateMachine"),
1104 peer->GetTaskInstance())),
1105 hold_time_(GetConfiguredHoldTime()),
1180 template <
typename Ev,
int code>
1186 template <
typename Ev>
1197 template <
typename Ev,
int code>
1220 int ms = seconds ? seconds * 1000 : 50;
1221 ms = (ms * (100 -
kJitter)) / 100;
1371 const std::string &data) {
1377 if (session && code != 0)
1418 boost::system::error_code error;
1421 if (
peer() &&
peer()->session() &&
peer()->session()->socket() &&
1422 peer()->session()->socket()->available(error) > 0) {
1494 switch (msg->
type) {
1564 std::string((
const char *)context->
data, context->
data_size)));
1602 template <
typename Ev>
1604 template <
typename T,
bool (T::*)(StateMachine *) const>
struct SFINAE {};
1606 template <
typename T>
static int Test(...);
1607 static const bool Has =
sizeof(Test<Ev>(0)) ==
sizeof(
char);
1610 template <
typename Ev,
bool has_val
idate>
1617 template <
typename Ev>
1620 return boost::bind(&Ev::validate, event, _1);
1624 template <
typename Ev>
1628 ec.
event =
event.intrusive_from_this();
1630 static_cast<const Ev *
>(ec.
event.get()));
1640 (event_name ==
"fsm::EvBgpKeepalive" ||
1641 event_name ==
"fsm::EvBgpUpdate")) {
1644 SM_LOG(log_level, msg <<
" " << event_name <<
" in state " <<
StateName());
1650 if (deferred_delete != NULL) {
1660 process_event(*ec.
event);
1693 static std::atomic<bool> env_checked = std::atomic<bool>();
1694 static std::atomic<int> env_hold_time = std::atomic<int>();
1698 char *keepalive_time_str = getenv(
"BGP_KEEPALIVE_SECONDS");
1699 if (keepalive_time_str) {
1700 env_hold_time = strtoul(keepalive_time_str, NULL, 0) * 3;
1702 return env_hold_time;
1706 }
else if (env_hold_time) {
1707 return env_hold_time;
1723 assert(!peer_info.get_name().empty());
1733 (event ==
"fsm::EvBgpKeepalive" || event ==
"fsm::EvBgpUpdate")) {
1737 BgpPeerInfoData peer_info;
1738 peer_info.set_name(
peer()->ToUVEKey());
1739 PeerEventInfo event_info;
1742 peer_info.set_event_info(event_info);
1747 const string &reason) {
1752 BgpPeerInfoData peer_info;
1753 peer_info.set_name(
peer()->ToUVEKey());
1761 const string &reason) {
1766 BgpPeerInfoData peer_info;
1767 peer_info.set_name(
peer()->ToUVEKey());
1780 BgpPeerInfoData peer_info;
1781 peer_info.set_name(
peer()->ToUVEKey());
1782 PeerStateInfo state_info;
1786 peer_info.set_state_info(state_info);
1793 BgpPeerInfoData peer_info;
1794 peer_info.set_name(
peer()->ToUVEKey());
1802 BgpPeerInfoData peer_info;
1803 peer_info.set_name(
peer()->ToUVEKey());
1820 BgpPeerInfoData peer_info;
1821 peer_info.set_name(
peer()->ToUVEKey());
1822 PeerStateInfo state_info;
1826 peer_info.set_state_info(state_info);
1828 PeerEventInfo event_info;
1831 peer_info.set_event_info(event_info);
#define BGP_LOG_FLAG_SYSLOG
#define BGP_LOG_PEER(type, peer, level, flags, dir, arg)
#define BGP_UVE_SEND(type, object)
const BgpPeerKey & peer_key() const
StateMachine * state_machine()
virtual const std::string & ToUVEKey() const
uint16_t hold_time() const
bool IsRouterTypeBGPaaS() const
void Close(bool graceful)
bool IsCloseInProgress() const
void increment_flap_count()
virtual BgpServer * server()
virtual void SetDataCollectionKey(BgpPeerInfo *peer_info) const
void inc_connect_timer_expired()
void SendKeepalive(bool from_timer)
virtual uint32_t bgp_identifier() const
void SendNotification(BgpSession *, int code, int subcode=0, const std::string &data=std::string())
void set_session(BgpSession *session)
void SendOpen(TcpSession *session)
void inc_hold_timer_expired()
bool SetCapabilities(const BgpProto::OpenMessage *msg)
void StartKeepaliveTimer()
void inc_rx_notification()
BgpSession * CreateSession()
void ProcessUpdate(const BgpProto::Update *msg, size_t msgsize=0)
virtual IPeerDebugStats * peer_stats()
bool IsCloseGraceful() const
void NotifyEstablished(bool established)
bool AttemptGRHelperMode(int code, int subcode) const
uint32_t bgp_identifier() const
BgpSessionManager * session_manager()
uint32_t hold_time() const
void LogNotification(int code, int subcode, const std::string &direction, const std::string &peer_key, const BgpProto::Notification &msg) const
static SandeshLevel::type LoggingUtLevel()
void CancelIdleHoldTimer()
BgpSession * active_session()
void connect_attempts_inc()
void connect_attempts_clear()
const std::string last_notification_in_error() const
BgpSession * active_session_
void OnIdleError(const Ev &event)
bool IdleHoldTimerExpired()
static const int kOpenSentHoldTime
virtual bool IsCloseGraceful() const
void OnMessage(BgpSession *session, BgpProto::BgpMessage *msg, size_t msgsize=0)
uint64_t last_notification_in_at_
void set_last_notification_out(int code, int subcode, const std::string &reason)
std::pair< int, int > last_notification_in_
virtual const int GetIdleHoldTimeMSecs() const
bool DequeueEvent(EventContainer ec)
virtual void OnNotificationMessage(BgpSession *session, BgpProto::BgpMessage *msg)
void set_state(State state)
uint64_t last_state_change_at_
virtual void DeleteSession(BgpSession *session)
bool ProcessNotificationEvent(BgpSession *session)
const std::string last_state_change_at() const
std::string last_notification_out_error_
void OnMessageError(BgpSession *session, const ParseErrorContext *context)
static const int kConnectInterval
void SendNotification(BgpSession *session, int code, int subcode=0, const std::string &data=std::string())
bool ConnectTimerExpired()
BgpSession * passive_session_
int GetConfiguredHoldTime() const
std::string last_notification_in_error_
StateMachine(BgpPeer *peer)
virtual void OnSessionEvent(TcpSession *session, TcpSession::Event event)
void CancelConnectTimer()
WorkQueue< EventContainer > work_queue_
void OnIdleCease(const Ev &event)
BgpSession * passive_session()
static const int kIdleHoldTime
static const int kHoldTime
void SetAdminState(bool down, int subcode)
void SetDataCollectionKey(BgpPeerInfo *peer_info) const
void set_hold_time(int hold_time)
bool IsQueueEmpty() const
void set_idle_hold_time(int idle_hold_time)
const std::string last_notification_out_error() const
void AssignSession(bool active)
bool Enqueue(const Ev &event)
void set_passive_session(BgpSession *session)
const uint64_t last_state_change_usecs_at() const
const std::string & StateName() const
void PeerClose(int code, int subcode)
void set_last_event(const std::string &event)
uint64_t last_notification_out_at_
bool ConnectTimerRunning()
virtual void StartOpenTimer(int seconds)
void Shutdown(int subcode)
bool IdleHoldTimerRunning()
void LogEvent(std::string event_name, std::string msg, SandeshLevel::type log_level=SandeshLevel::SYS_DEBUG)
void DequeueEventDone(bool done)
int GetConnectTime() const
virtual bool IsPeerCloseInProgress() const
virtual bool IsRouterTypeBGPaaS() const
void BGPPeerInfoSend(const BgpPeerInfoData &peer_info)
virtual void StartIdleHoldTimer()
void set_active_session(BgpSession *session)
bool PassiveOpen(BgpSession *session)
void OnIdle(const Ev &event)
static const int kOpenTime
void OnIdleNotification(const fsm::EvBgpNotification &event)
int idle_hold_time() const
const std::string & LastStateName() const
void reset_idle_hold_time()
void TimerErrorHanlder(std::string name, std::string error)
virtual void StartConnectTimer(int seconds)
virtual void StartHoldTimer()
void set_last_notification_in(int code, int subcode, const std::string &reason)
std::pair< int, int > last_notification_out_
static const int kMaxIdleHoldTime
The TaskScheduler keeps track of what tasks are currently schedulable. When a task is enqueued it is ...
virtual void Connect(TcpSession *session, Endpoint remote)
virtual void DeleteSession(TcpSession *session)
virtual std::string ToString() const
void set_observer(EventObserver observer)
bool IsEstablished() const
virtual void AsyncReadStart()
static bool DeleteTimer(Timer *Timer)
bool Start(int time, Handler handler, ErrorHandler error_handler=NULL)
bool Enqueue(QueueEntryT entry)
void Shutdown(bool delete_entries=true)
void SetExitCallback(TaskExitCallback on_exit)
bool IsQueueEmpty() const
#define SM_LOG(level, _Msg)
ostream & operator<<(ostream &out, const StateMachine::State &state)
#define SM_LOG_NOTICE(_Msg)
static const std::string state_names[]
boost::function< bool(StateMachine *)> EvValidate
static const std::string integerToString(const NumberType &num)
boost::asio::ip::tcp::endpoint endpoint
static const std::string toString(Code code, int subcode)
int Validate(BgpPeer *peer) const
int Validate(const BgpPeer *, std::string *data)
static char Test(SFINAE< T, &T::validate > *)
boost::intrusive_ptr< const sc::event_base > event
EvValidate operator()(const Ev *event)
EvValidate operator()(const Ev *event)
sc::result react(const EvOpenTimerExpired &event)
sc::result react(const EvTcpPassiveOpen &event)
sc::result react(const EvConnectTimerExpired &event)
mpl::list< IdleCease< EvStop >::reaction, sc::custom_reaction< EvConnectTimerExpired >, sc::custom_reaction< EvOpenTimerExpired >, sc::custom_reaction< EvTcpPassiveOpen >, sc::custom_reaction< EvTcpClose >, sc::custom_reaction< EvBgpOpen >, TransitToIdle< EvBgpNotification >::reaction, IdleFsmError< EvBgpKeepalive >::reaction, IdleFsmError< EvBgpUpdate >::reaction, IdleError< EvBgpHeaderError, BgpProto::Notification::MsgHdrErr >::reaction, IdleError< EvBgpOpenError, BgpProto::Notification::OpenMsgErr >::reaction, IdleError< EvBgpUpdateError, BgpProto::Notification::UpdateMsgErr >::reaction > reactions
sc::result react(const EvTcpClose &event)
sc::result react(const EvBgpOpen &event)
mpl::list< IdleCease< EvStop >::reaction, sc::custom_reaction< EvConnectTimerExpired >, sc::custom_reaction< EvOpenTimerExpired >, sc::custom_reaction< EvTcpConnected >, sc::custom_reaction< EvTcpConnectFail >, sc::custom_reaction< EvTcpPassiveOpen >, sc::custom_reaction< EvTcpClose >, sc::custom_reaction< EvBgpOpen >, TransitToIdle< EvBgpNotification >::reaction, IdleFsmError< EvBgpKeepalive >::reaction, IdleFsmError< EvBgpUpdate >::reaction, IdleError< EvBgpHeaderError, BgpProto::Notification::MsgHdrErr >::reaction, IdleError< EvBgpOpenError, BgpProto::Notification::OpenMsgErr >::reaction, IdleError< EvBgpUpdateError, BgpProto::Notification::UpdateMsgErr >::reaction > reactions
sc::result react(const EvTcpConnected &event)
sc::result react(const EvBgpOpen &event)
sc::result react(const EvTcpPassiveOpen &event)
sc::result react(const EvConnectTimerExpired &event)
sc::result react(const EvTcpConnectFail &event)
sc::result react(const EvOpenTimerExpired &event)
sc::result react(const EvTcpClose &event)
sc::result react(const EvTcpPassiveOpen &event)
sc::result react(const EvBgpKeepalive &event)
sc::result react(const EvBgpUpdate &event)
mpl::list< IdleCease< EvStop >::reaction, IdleFsmError< EvOpenTimerExpired >::reaction, TransitToIdle< EvHoldTimerExpired, BgpProto::Notification::HoldTimerExp >::reaction, sc::custom_reaction< EvTcpPassiveOpen >, TransitToIdle< EvTcpClose >::reaction, IdleFsmError< EvBgpOpen >::reaction, TransitToIdle< EvBgpNotification >::reaction, sc::custom_reaction< EvBgpKeepalive >, sc::custom_reaction< EvBgpUpdate >, IdleError< EvBgpHeaderError, BgpProto::Notification::MsgHdrErr >::reaction, IdleFsmError< EvBgpOpenError >::reaction, IdleError< EvBgpUpdateError, BgpProto::Notification::UpdateMsgErr >::reaction > reactions
Established(my_context ctx)
static const char * Name()
bool validate(StateMachine *state_machine) const
EvBgpKeepalive(BgpSession *session)
boost::shared_ptr< const BgpProto::Notification > msg
EvBgpNotification(BgpSession *session, const BgpProto::Notification *msg)
bool validate(StateMachine *state_machine) const
static const char * Name()
static const char * Name()
EvBgpOpenError(BgpSession *session, int subcode, const uint8_t *_data=NULL, size_t data_size=0)
bool validate(StateMachine *state_machine) const
static const char * Name()
boost::shared_ptr< const BgpProto::OpenMessage > msg
EvBgpOpen(BgpSession *session, const BgpProto::OpenMessage *msg)
EvBgpUpdateError(BgpSession *session, int subcode, std::string data)
static const char * Name()
EvBgpUpdate(BgpSession *session, const BgpProto::Update *msg, size_t msgsize)
static const char * Name()
boost::shared_ptr< const BgpProto::Update > msg
bool validate(StateMachine *state_machine) const
static const char * Name()
EvConnectTimerExpired(Timer *timer)
bool validate(StateMachine *state_machine) const
static const char * Name()
EvHoldTimerExpired(Timer *timer)
bool validate(StateMachine *state_machine) const
static const char * Name()
EvIdleHoldTimerExpired(Timer *timer)
EvOpenTimerExpired(Timer *timer)
bool validate(StateMachine *state_machine) const
static const char * Name()
static const char * Name()
static const char * Name()
bool validate(StateMachine *state_machine) const
static const char * Name()
EvTcpClose(BgpSession *session)
EvTcpConnectFail(BgpSession *session)
static const char * Name()
bool validate(StateMachine *state_machine) const
bool validate(StateMachine *state_machine) const
EvTcpConnected(BgpSession *session)
static const char * Name()
static const char * Name()
EvTcpDeleteSession(BgpSession *session)
EvTcpPassiveOpen(BgpSession *session)
static const char * Name()
sc::transition< Ev, Idle, StateMachine, &StateMachine::OnIdleCease< Ev > > reaction
sc::transition< Ev, Idle, StateMachine, &StateMachine::OnIdleError< Ev, code > > reaction
sc::transition< Ev, Idle, StateMachine, &StateMachine::OnIdle< Ev, BgpProto::Notification::FSMErr > > reaction
sc::result react(const EvIdleHoldTimerExpired &event)
mpl::list< IdleCease< EvStop >::reaction, sc::custom_reaction< EvStart >, sc::custom_reaction< EvIdleHoldTimerExpired >, sc::custom_reaction< EvTcpPassiveOpen > > reactions
sc::result react(const EvTcpPassiveOpen &event)
sc::result react(const EvStart &event)
mpl::list< IdleCease< EvStop >::reaction, IdleFsmError< EvOpenTimerExpired >::reaction, TransitToIdle< EvHoldTimerExpired, BgpProto::Notification::HoldTimerExp >::reaction, sc::custom_reaction< EvTcpPassiveOpen >, TransitToIdle< EvTcpClose >::reaction, IdleFsmError< EvBgpOpen >::reaction, sc::custom_reaction< EvBgpNotification >, sc::custom_reaction< EvBgpKeepalive >, IdleFsmError< EvBgpUpdate >::reaction, IdleError< EvBgpHeaderError, BgpProto::Notification::MsgHdrErr >::reaction, IdleError< EvBgpOpenError, BgpProto::Notification::OpenMsgErr >::reaction, IdleError< EvBgpUpdateError, BgpProto::Notification::UpdateMsgErr >::reaction > reactions
OpenConfirm(my_context ctx)
sc::result react(const EvBgpKeepalive &event)
sc::result react(const EvTcpPassiveOpen &event)
sc::result react(const EvBgpNotification &event)
sc::result react(const EvBgpNotification &event)
sc::result react(const EvTcpPassiveOpen &event)
mpl::list< IdleCease< EvStop >::reaction, sc::custom_reaction< EvOpenTimerExpired >, TransitToIdle< EvHoldTimerExpired, BgpProto::Notification::HoldTimerExp >::reaction, sc::custom_reaction< EvTcpPassiveOpen >, sc::custom_reaction< EvTcpClose >, sc::custom_reaction< EvBgpOpen >, sc::custom_reaction< EvBgpNotification >, IdleFsmError< EvBgpKeepalive >::reaction, IdleFsmError< EvBgpUpdate >::reaction, IdleError< EvBgpHeaderError, BgpProto::Notification::MsgHdrErr >::reaction, IdleError< EvBgpOpenError, BgpProto::Notification::OpenMsgErr >::reaction, IdleError< EvBgpUpdateError, BgpProto::Notification::UpdateMsgErr >::reaction > reactions
sc::result react(const EvBgpOpen &event)
sc::result react(const EvTcpClose &event)
sc::result react(const EvOpenTimerExpired &event)
sc::transition< EvBgpNotification, Idle, StateMachine, &StateMachine::OnIdleNotification > reaction
sc::transition< Ev, Idle, StateMachine, &StateMachine::OnIdle< Ev, code > > reaction
#define CHECK_CONCURRENCY(...)
static boost::posix_time::ptime UTCUsecToPTime(uint64_t tusec)
static uint64_t UTCTimestampUsec()