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

Log configuration at start up #689

Merged
merged 1 commit into from
Apr 19, 2024
Merged

Log configuration at start up #689

merged 1 commit into from
Apr 19, 2024

Conversation

mem
Copy link
Contributor

@mem mem commented Apr 18, 2024

When the program is starting up, log the configuration parameters. This helps with debugging and support.

Be careful not to log the API secret.

This is a no-op change, but it's a little noisy becuase of the introduction of the config struct.

@mem mem requested a review from a team as a code owner April 18, 2024 21:57
When the program is starting up, log the configuration parameters. This
helps with debugging and support.

Be careful not to log the API secret.

This is a no-op change, but it's a little noisy becuase of the
introduction of the config struct.

Signed-off-by: Marcelo E. Magallon <marcelo.magallon@grafana.com>
Copy link
Collaborator

@roobre roobre left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Having a string implement Stringer is a pretty clever way of redacting!

Comment on lines +11 to +15
// Set sets the value of the secret.
func (s *Secret) Set(value string) error {
*s = Secret(value)
return nil
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does Set(string) error make this implement any interface?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah, yeah, it's what flag.Value wants. It also wants String() for that matter.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's needed for line 83 to work.

@mem mem merged commit aeaf280 into main Apr 19, 2024
4 checks passed
@mem mem deleted the log-configuration branch April 19, 2024 16:51
The-9880 added a commit that referenced this pull request Apr 30, 2024
* Feature: upgrade k6 to v0.50.0 (#681)
* Chore(deps): Bump github.com/prometheus/blackbox_exporter
* skip interpolating multihttp variables into the metric names (#683)
* proto fields for scripted check enablement (#674)
* Switch to using buf to manage protobuf code (#641)
* Release v0.23.4 (#685)
* Fix: TestTickWithOffset sometimes if offset is 0 (#686)
* Chore(deps): Bump the prometheus-go group with 2 updates
* Chore(deps): Bump github.com/miekg/dns from 1.1.58 to 1.1.59
* Log configuration at start up (#689)
* Feature: automatically set up GOMEMLIMIT (#691)
* Terminate agent if capabilities not supported (#684)
* Make k6 capability validation nil-safe (#692)
* Fix: use uniform timeout validation logic (#693)

Signed-off-by: Anant Sharma <anant.sharma@grafana.com>
@The-9880 The-9880 mentioned this pull request Apr 30, 2024
The-9880 added a commit that referenced this pull request Apr 30, 2024
* Feature: upgrade k6 to v0.50.0 (#681)
* Chore(deps): Bump github.com/prometheus/blackbox_exporter
* skip interpolating multihttp variables into the metric names (#683)
* proto fields for scripted check enablement (#674)
* Switch to using buf to manage protobuf code (#641)
* Release v0.23.4 (#685)
* Fix: TestTickWithOffset sometimes if offset is 0 (#686)
* Chore(deps): Bump the prometheus-go group with 2 updates
* Chore(deps): Bump github.com/miekg/dns from 1.1.58 to 1.1.59
* Log configuration at start up (#689)
* Feature: automatically set up GOMEMLIMIT (#691)
* Terminate agent if capabilities not supported (#684)
* Make k6 capability validation nil-safe (#692)
* Fix: use uniform timeout validation logic (#693)

Signed-off-by: Anant Sharma <anant.sharma@grafana.com>
@The-9880 The-9880 mentioned this pull request Apr 30, 2024
The-9880 added a commit that referenced this pull request Apr 30, 2024
* Feature: upgrade k6 to v0.50.0 (#681)
* Chore(deps): Bump github.com/prometheus/blackbox_exporter
* skip interpolating multihttp variables into the metric names (#683)
* proto fields for scripted check enablement (#674)
* Switch to using buf to manage protobuf code (#641)
* Release v0.23.4 (#685)
* Fix: TestTickWithOffset sometimes if offset is 0 (#686)
* Chore(deps): Bump the prometheus-go group with 2 updates
* Chore(deps): Bump github.com/miekg/dns from 1.1.58 to 1.1.59
* Log configuration at start up (#689)
* Feature: automatically set up GOMEMLIMIT (#691)
* Terminate agent if capabilities not supported (#684)
* Make k6 capability validation nil-safe (#692)
* Fix: use uniform timeout validation logic (#693)
* k6runner: handle errors reported by http runners
* k6runner/test: add test for RunResponse error handling
* k6runner: inspect errors and propagate unexpected ones to the probe

Signed-off-by: Anant Sharma <anant.sharma@grafana.com>
@The-9880 The-9880 mentioned this pull request Apr 30, 2024
mem pushed a commit that referenced this pull request Apr 30, 2024
* Feature: upgrade k6 to v0.50.0 (#681)
* Chore(deps): Bump github.com/prometheus/blackbox_exporter
* skip interpolating multihttp variables into the metric names (#683)
* proto fields for scripted check enablement (#674)
* Switch to using buf to manage protobuf code (#641)
* Release v0.23.4 (#685)
* Fix: TestTickWithOffset sometimes if offset is 0 (#686)
* Chore(deps): Bump the prometheus-go group with 2 updates
* Chore(deps): Bump github.com/miekg/dns from 1.1.58 to 1.1.59
* Log configuration at start up (#689)
* Feature: automatically set up GOMEMLIMIT (#691)
* Terminate agent if capabilities not supported (#684)
* Make k6 capability validation nil-safe (#692)
* Fix: use uniform timeout validation logic (#693)
* k6runner: handle errors reported by http runners
* k6runner/test: add test for RunResponse error handling
* k6runner: inspect errors and propagate unexpected ones to the probe

Signed-off-by: Anant Sharma <anant.sharma@grafana.com>
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

Successfully merging this pull request may close these issues.

2 participants