mirror of
https://github.com/zeek/zeek.git
synced 2025-10-04 07:38:19 +00:00
Adapting attribute serialization when talking to Broccoli.
Broccoli doesn't support expressions, and we now no longer send them when serializing attributes. This is the Bro change mentioned in #606. It's needs a correspondinly modified Broccoli identifying itself as such, and it isn't tested yet ... Addresses #606.
This commit is contained in:
parent
01b4ea1f5d
commit
18d968adcd
4 changed files with 30 additions and 2 deletions
|
@ -385,6 +385,9 @@ inline void RemoteSerializer::SetupSerialInfo(SerialInfo* info, Peer* peer)
|
|||
peer->phase == Peer::RUNNING )
|
||||
info->new_cache_strategy = true;
|
||||
|
||||
if ( (peer->caps & Peer::BROCCOLI_PEER) )
|
||||
info->broccoli_peer = true;
|
||||
|
||||
info->include_locations = false;
|
||||
}
|
||||
|
||||
|
@ -1457,7 +1460,7 @@ void RemoteSerializer::Finish()
|
|||
Poll(true);
|
||||
while ( io->CanWrite() );
|
||||
|
||||
loop_over_list(peers, i)
|
||||
loop_over_list(peers, i)
|
||||
{
|
||||
CloseConnection(peers[i]);
|
||||
}
|
||||
|
@ -2113,6 +2116,9 @@ bool RemoteSerializer::HandshakeDone(Peer* peer)
|
|||
if ( (peer->caps & Peer::NEW_CACHE_STRATEGY) )
|
||||
Log(LogInfo, "peer supports keep-in-cache; using that", peer);
|
||||
|
||||
if ( (peer->caps & Peer::BROCCOLI_PEER) )
|
||||
Log(LogInfo, "peer is a Broccoli", peer);
|
||||
|
||||
if ( peer->logs_requested )
|
||||
log_mgr->SendAllWritersTo(peer->id);
|
||||
|
||||
|
@ -2365,6 +2371,9 @@ bool RemoteSerializer::ProcessSerialization()
|
|||
current_peer->phase == Peer::RUNNING )
|
||||
info.new_cache_strategy = true;
|
||||
|
||||
if ( current_peer->caps & Peer::BROCCOLI_PEER )
|
||||
info.broccoli_peer = true;
|
||||
|
||||
if ( ! forward_remote_state_changes )
|
||||
ignore_accesses = true;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue