elastic / elastic-agent

Elastic Agent - single, unified way to add monitoring for logs, metrics, and other types of data to a host.
Other
21 stars 143 forks source link

Remove `--path.install` option #2489

Open ycombinator opened 1 year ago

ycombinator commented 1 year ago

As per the conversation starting from https://github.com/elastic/ingest-dev/issues/1609#issuecomment-1503384831, the --path.install option is no longer being used by Elastic Agent. We should remove it but, since that would be a breaking change, we should do this in 9.0.

Copying relevant bits of the conversation here for easy reference:

@blakerouse said:

I believe with the changes in the V2 architecture (aka 8.6+) we missed removing some command-line arguments. --path.install has a different meaning then what this issue is seeking to solve. It is documented as Install path contains binaries Agent extracts, which meant the binaries that Elastic Agent extracted to run (aka. filebeat, metricbeat, etc..). Obviously with V2 (8.6+) we no longer extract the binaries they come pre-extracted so we no longer need or use the --path.install.

@ycombinator asked:

Shouldn't we wait to remove the --path.install option in 9.0 since it would technically be a breaking change to remove it in 8.x?

@jlind23 confirmed:

Let's wait for [9.0] indeed.

cmacknz commented 1 year ago

Haven't we already made the breaking change by ignoring the argument? Anyone relying on this has already had their use case broken.

blakerouse commented 1 year ago

@cmacknz No because you can still provide the --path.install to the Elastic Agent and it won't error. If we remove it then it would be breaking as the Elastic Agent would fail to start. We also didn't break any use-case because we no-longer extract to any directory so its not needed.

belimawr commented 11 months ago

What about we at least edit the description of the flag to state it is deprecated and ignored?

On v8.11.1 (the latest release at the time of writting) we still have:

      --path.install string          Install path contains binaries Agent extracts

We could edit the message to something like "DEPRECATED, setting this flag has no effect". Or even add the version: "DEPRECATED, setting this flag has no effect since v8.6.0".

That way we do not break anything, keep the current behaviour and better inform the users about the current behaviour.

cmacknz commented 11 months ago

@belimawr good idea, go ahead and a make PR for it.

belimawr commented 11 months ago

PR created: https://github.com/elastic/elastic-agent/pull/3863