mirror of
https://github.com/zeek/zeek.git
synced 2025-10-07 00:58:19 +00:00
Remove concept of multiple timer managers
- All timers are now handled by a single global timer manager, which simplifies how they handled by the IOSource manager. - This change flows down a number of changes to other parts of the code. The timer manager tag field is removed, which means that matching connections to a timer manager is also removed. This removes the ability to tag a connection as internal or external, since that's how the connections where differentiated. This in turn removes the `current_conns_extern` field from the `ConnStats` record type in the script layer.
This commit is contained in:
parent
2dcc936787
commit
be42608b51
15 changed files with 28 additions and 284 deletions
10
src/Conn.h
10
src/Conn.h
|
@ -228,11 +228,6 @@ public:
|
|||
void Describe(ODesc* d) const override;
|
||||
void IDString(ODesc* d) const;
|
||||
|
||||
TimerMgr* GetTimerMgr() const;
|
||||
|
||||
// Returns true if connection has been received externally.
|
||||
bool IsExternal() const { return conn_timer_mgr != 0; }
|
||||
|
||||
// Statistics.
|
||||
|
||||
// Just a lower bound.
|
||||
|
@ -243,8 +238,6 @@ public:
|
|||
{ return total_connections; }
|
||||
static uint64_t CurrentConnections()
|
||||
{ return current_connections; }
|
||||
static uint64_t CurrentExternalConnections()
|
||||
{ return external_connections; }
|
||||
|
||||
// Returns true if the history was already seen, false otherwise.
|
||||
int CheckHistory(uint32_t mask, char code)
|
||||
|
@ -320,8 +313,6 @@ protected:
|
|||
ConnIDKey key;
|
||||
bool key_valid;
|
||||
|
||||
// Timer manager to use for this conn (or nil).
|
||||
std::string* conn_timer_mgr;
|
||||
timer_list timers;
|
||||
|
||||
IPAddr orig_addr;
|
||||
|
@ -353,7 +344,6 @@ protected:
|
|||
// Count number of connections.
|
||||
static uint64_t total_connections;
|
||||
static uint64_t current_connections;
|
||||
static uint64_t external_connections;
|
||||
|
||||
string history;
|
||||
uint32_t hist_seen;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue