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 json encoding on flow ingestion #212

Closed
jotak opened this issue May 30, 2022 · 1 comment
Closed

Avoid json encoding on flow ingestion #212

jotak opened this issue May 30, 2022 · 1 comment

Comments

@jotak
Copy link
Member

jotak commented May 30, 2022

As commented here https://github.com/netobserv/flowlogs-pipeline/blob/main/pkg/pipeline/ingest/ingest_collector.go#L168-L169, it seems like there's an easy perf improvement we can do by avoiding json encoding during flow ingestion, especially as it kinda forces users to use json decoding as the following stage.

It seems like we can "just" remove the json encode instruction, update related tests and voila. But that's a breaking change of course, consumers need to update their pipeline to remove the following json decode stage.

What I'm not sure, is if it's still necessary to allow json encoding, as all following stages use a native map format anyway. If we think we must maintain a json-encoded option, there's several possible approaches I can see so far:

  • add a json-encode option as part of the ingest-collector stage params
  • create a new json-encode stage (oddly, this stage should be a "transform" stage and not an "encode" stage, because transform has input & output, whereas "encode" has no output (??) )

ping @eranra @KalmanMeth @ronensc

jotak added a commit to jotak/flowlogs-pipeline that referenced this issue May 31, 2022
jotak added a commit to jotak/flowlogs-pipeline that referenced this issue May 31, 2022
jotak added a commit to jotak/flowlogs-pipeline that referenced this issue Jun 2, 2022
jotak added a commit to jotak/flowlogs-pipeline that referenced this issue Jun 7, 2022
jotak added a commit to jotak/flowlogs-pipeline that referenced this issue Jun 14, 2022
jotak added a commit to jotak/flowlogs-pipeline that referenced this issue Jun 16, 2022
@jotak
Copy link
Member Author

jotak commented Jun 16, 2022

Fixed by #225

@jotak jotak closed this as completed Jun 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant