-
Notifications
You must be signed in to change notification settings - Fork 31
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
Client can't receive configurations larger than 4MiB #17
Comments
Oh good catch adriansr, @blakerouse @michalpristas Do you see any problem into increasing that, is the data compressed? |
reassign to @ruflin I think this could expose a bigger issue in our system that just the protocol between Agent and the processes. |
@ph I don't see why it could not be increased. Seems like its a general default in GRPC which can be used for many use-cases so makes sense why the value is lower. Being that the communication between GRPC is secured through mutual-TLS the only way to connect is having the correct information, so I do not see a technical issue with increasing this. |
@blakerouse thanks, I think we have to check elsewhere before doing that change. |
I would like to push this forward. In general, I think we should have a sensible limit for max policy sizes to keep sanity in the system. This also helps to bubble up these kind of errors. As the above error bubbles up in GRPC, I wonder what our limit from the Kibana side is? I would expect that this is where it more becomes a problem when the config is sent over the network. One thing we need, is to make sure this error is properly bubbled up to Kibana to give the user good feedback on what kind of error happened. In addition, we could make the max size a configuration option so in edge cases it could be overwritten. @michalpristas @blakerouse @nchaulet
In parallel we should work with @adriansr to see if there are options to not have to ship down these massive parsers ;-) |
Just for completeness, I've mentioned on slack, could we minify these JS parsers and could we compress them when we package the integration? |
I ran a minifier on the JS files to get an idea of the potential savings. Looks like about 330K.
|
@jfsiii Hey that's the integration I was thinking yesterday. |
@andrewkroh Could we gzip them?
|
I see two areas where we could optimize size.
|
If we switch to the minifier approach now, would things work again as a short term solution?
|
No, I think the savings on the minified version are not enough. For the short term we can delay shipping the affected packages.
They are different input types so that it can accept files, udp, or tcp logs. But other than the input type the rest of the configuration attached to the input is duplicated (like the same |
Unfortunately at the moment we only support grouping of configs per input type. I wonder if there is a "low hanging fruit" we could solve this with? @urso With your input grouping proposal, I assume the above would be possible? |
Yes, it could help, as all the settings like fields, fields_under_root, and processors could become shared settings. E.g. the config could become:
But this requires Fleet to actually construct this kind of config. In case we have loads of redundancy we might also consider some 'dedup' support, so we can reference configurations that are common o multiple configured inputs. E.g. if we find 2 datastreams configured, but with different namespace we might end up with a redundant configuration. Besides compression/minification we could provide common/default config blocks like:
All in all it sounds like the main issue is that we have too big/complex processing chain we push to the Beat. We should try to replace those with Ingest Pipelines instead. |
I think @urso is on something. What he proposes is partially supported by the local vars provider from composable inputs. I say partially because from package you cannot define providers related data. providers:
local:
vars:
foo: bar
inputs:
- ...
value: ${foo} |
@ruflin What I've described is already working today. But this requires more long term thinking, maybe by a custom fleet provider where you can define namespace. I was just throwing ideas. ++ on solving the root cause. |
We have discussed this over zoom and we decided the following:
|
@andrewkroh @adriansr I am going to close this issue, we don't consider this change to be the right solution for this problem, if you take any suggestion above into another proposal we are happy to discuss it with you. |
When testing with huge pipelines for Filebeat, I get the following error in elastic-agent:
This is a problem when working with large parsers from rsa2elk, or enabling a lot of the not-so-big integrations.
Can we make this larger, say 16 or 32MiB, or configurable?
The setting would be
grpc.WithDefaultCallOptions(grpc.MaxCallRecvMsgSize(myMaxSize))
The text was updated successfully, but these errors were encountered: