Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid implicit conversions in Zeek utility classes #376

Merged
merged 2 commits into from
Oct 13, 2023

Conversation

Neverlord
Copy link
Member

This PR mainly refactors the API in zeek.hh as preparation for the upcoming variant switch. However, the changes also address some rather nasty API details like implicit conversions all over the place and very verbose code in our valid() implementations that make it often hard to follow what's actually being checked.

  • to make transition to variant easier, the Zeek-compatibility classes provide an interface from data_message now
  • the new BatchBuilder gives an interface for assembling batches without manually pulling out the data member from Zeek message types

@Neverlord Neverlord force-pushed the topic/neverlord/zeek-compat-refactoring branch from e618639 to 1840fd2 Compare September 24, 2023 12:51
@Neverlord Neverlord marked this pull request as ready for review September 24, 2023 13:33
@Neverlord Neverlord force-pushed the topic/neverlord/zeek-compat-refactoring branch from 1840fd2 to 5ac94f5 Compare September 24, 2023 14:01
src/zeek.cc Outdated Show resolved Hide resolved
include/broker/zeek.hh Outdated Show resolved Hide resolved
@Neverlord Neverlord force-pushed the topic/neverlord/zeek-compat-refactoring branch from f645eb4 to e4b0cfc Compare October 12, 2023 15:30
@timwoj timwoj merged commit 86ed39b into master Oct 13, 2023
23 checks passed
@timwoj timwoj deleted the topic/neverlord/zeek-compat-refactoring branch October 13, 2023 20:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants