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

Config parameters aren't passed through to the shipper output in Beats #2351

Closed
Tracked by #16
faec opened this issue Mar 7, 2023 · 7 comments
Closed
Tracked by #16

Config parameters aren't passed through to the shipper output in Beats #2351

faec opened this issue Mar 7, 2023 · 7 comments
Labels
bug Something isn't working Team:Elastic-Agent Label for the Agent team

Comments

@faec
Copy link
Contributor

faec commented Mar 7, 2023

When ingesting through the shipper via the Beats shipper output, e.g. with a configuration like:

outputs:
  default:
    type: elasticsearch
    log_level: debug
    enabled: true
    hosts: [https://127.0.0.1:9200]
    username: "elastic"
    password: [password]
    bulk_max_size: 4096
    shipper:
      enabled: true

Agent does not pass through bulk_max_size or any other parameters except the ones it synthesizes itself. The config parameters the shipper output receives are:

type
server
ssl.certificate
ssl.key
ssl.certificate_authorities

note that type is not actually a field of the shipper output's config (though it may be used elsewhere in the pipeline). However there are several other fields that are in the shipper output config:

timeout
max_retries
bulk_max_size
ack_polling_interval
backoff.init
backoff.max

and none of these are ever set.

This issue is possibly more for discussion / awareness than an immediate fix, since we might have good reasons not to expose those settings through the agent policy, at least in production. But it also means that right now we have "configuration parameters" on the shipper output that can only be changed by rebuilding with a new hard-coded default, which at a minimum was not obvious to me when I wanted to run tests depending on bulk_max_size :-) So we might want to think about a way to safely expose the full config, at least for internal testing.

@faec faec added bug Something isn't working Team:Elastic-Agent Label for the Agent team labels Mar 7, 2023
@cmacknz
Copy link
Member

cmacknz commented Mar 7, 2023

Hmm, I suspect we'd need to add a shipper section to the agent policy to let us adjust this.

The other option would be to allow changing this by editing the shipper spec file and have it take effect by restarting the agent.

@pierrehilbert
Copy link
Contributor

@cmacknz / @leehinman could we close this one with the new shipper plan?

@cmacknz
Copy link
Member

cmacknz commented May 4, 2023

This is still relevant

@blakerouse
Copy link
Contributor

I am confused? Everything under the outputs.default.* would be sent to the shippers output unit for elasticsearch.

@cmacknz
Copy link
Member

cmacknz commented May 5, 2023

This about configuring the internal Beat -> Shipper output and the not the Shipper -> ES/LS output. We do not expose a way to configure the internal Beat shipper output today.

@faec
Copy link
Contributor Author

faec commented Jun 2, 2023

Followup to this: right now it seems like the most practical way to do this is to include the output policy in both the shipper's output unit and in the output unit of the input component that writes to the shipper. We could then define, internally to the shipper / shipper-output, a certain configuration subtree for the connection writing to the shipper, which can contain the flags discussed here (timeout, backoff, etc) and which would allow us to have advanced configuration flags that affect the Beats shipper-output during troubleshooting or debugging without having to rebuild the whole project with a new flag value. This is a relatively minor change on the Agent side, we would just need to make sure that the Beats shipper output is ready to interpret the new data properly (i.e. that it doesn't try unpacking the policy directly into its own configuration the way it does right now).

@jlind23
Copy link
Contributor

jlind23 commented May 27, 2024

Closing this as the shipper project has been revisited.
cc @ycombinator

@jlind23 jlind23 closed this as not planned Won't fix, can't repro, duplicate, stale May 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Team:Elastic-Agent Label for the Agent team
Projects
None yet
Development

No branches or pull requests

5 participants