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

Autogenerate Sidecar Configuration Path Value #5265

Closed
mpfz0r opened this issue Nov 5, 2018 · 0 comments
Closed

Autogenerate Sidecar Configuration Path Value #5265

mpfz0r opened this issue Nov 5, 2018 · 0 comments
Assignees
Milestone

Comments

@mpfz0r
Copy link
Contributor

mpfz0r commented Nov 5, 2018

The decision in our meeting in Hamburg, was to remove the Configuration Path option.
We don't have a strong use case for this feature yet, thus it's better to start with less.

We auto-generate the value instead.

@mpfz0r mpfz0r added this to the 3.0.0 milestone Nov 5, 2018
@mpfz0r mpfz0r self-assigned this Nov 5, 2018
mpfz0r added a commit that referenced this issue Nov 5, 2018
Instead of a GUI option, we autogenerate the path
to ".../generated/<collector_name>.conf"

Remove existing configuration_path values in the migration
to simplify upgrading to this change.

Only expose the configuration path when the Collector object is requested via
the Sidecar API. Change this at runtime to an empty string and
use @JsonInclude(JsonInclude.Include.NON_EMPTY) to hide it.

Fixes #5265
mpfz0r added a commit that referenced this issue Nov 5, 2018
Instead of a GUI option, we autogenerate the path
to ".../generated/<collector_name>.conf"

We still provide the configuration path via the API to the sidecar.
This gives us more flexibility if we need to change the path in the future.

That's why we only expose the configuration path when the Collector object
is requested via the Sidecar API. We can change the path at runtime to an
empty string and use @JsonInclude(JsonInclude.Include.NON_EMPTY) to hide it.

Remove existing configuration_path values in the migration
to simplify upgrading to this change.

Fixes #5265
mpfz0r added a commit to Graylog2/collector-sidecar that referenced this issue Nov 8, 2018
Add a new sidecar.yml config option 'collector_config_directory'
to allow the configurations to be rendered into a different directory.

In the future, graylog might be able to specify the file name
for each collector backend. Add support for that by
adding a 'configuration_file_name' field to the API.

Fixes Graylog2/graylog2-server#5265
mpfz0r added a commit that referenced this issue Nov 8, 2018
Instead of a GUI option, we let the sidecar autogenerate the path
to ".../generated/<collector_name>.conf"

Remove existing configuration_path values in the migration
to simplify upgrading to this change.

Fixes #5265
mpfz0r added a commit that referenced this issue Nov 8, 2018
Instead of a GUI option, we let the sidecar autogenerate the path
to ".../generated/<collector_name>.conf"

Remove existing configuration_path values in the migration
to simplify upgrading to this change.

Fixes #5265
mariussturm pushed a commit to Graylog2/collector-sidecar that referenced this issue Nov 13, 2018
* Generate collector configuration file path in sidecar

Add a new sidecar.yml config option 'collector_config_directory'
to allow the configurations to be rendered into a different directory.

In the future, graylog might be able to specify the file name
for each collector backend. Add support for that by
adding a 'configuration_file_name' field to the API.

Fixes Graylog2/graylog2-server#5265

* Fix review comments

* Replace more "config" with "configuration"
mpfz0r added a commit that referenced this issue Nov 13, 2018
Instead of a GUI option, we let the sidecar autogenerate the path
to ".../generated/<collector_name>.conf"

Remove existing configuration_path values in the migration
to simplify upgrading to this change.

Fixes #5265
mariussturm pushed a commit that referenced this issue Nov 14, 2018
* Remove Sidecar collector configuration path

Instead of a GUI option, we let the sidecar autogenerate the path
to ".../generated/<collector_name>.conf"

Remove existing configuration_path values in the migration
to simplify upgrading to this change.

Fixes #5265

* Restrict collector names to path safe characters

We use the collector name in the configuration path.
Avoid problems by restricting it to a characters that need no escape
handling.

* Perform validatons all collector requests

and fix annotation on copy route

* Remove debug printf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant