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

Don't init OpenTelemetry when in rails console. #307

Merged
merged 1 commit into from
Jul 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# 9.0.2

* GovukAppConfig no longer automatically initialises OpenTelemetry when running in `rails console`.

# 9.0.1

* Rename the "error" field in Rails logs from logstasher to "message" as error is supposed to be an object.
Expand All @@ -12,11 +16,11 @@

# 8.1.1

* Fix prometheus_exporter to method patching compatible with open telemetry.
* Fix prometheus_exporter to method patching compatible with OpenTelemetry.

# 8.1.0

* Add ability to enable Open Telemetry instrumentation for Rails applications.
* Add ability to enable OpenTelemetry instrumentation for Rails applications.

# 8.0.2

Expand Down
4 changes: 3 additions & 1 deletion lib/govuk_app_config/railtie.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@ class Railtie < Rails::Railtie
end

initializer "govuk_app_config.configure_open_telemetry" do |app|
GovukOpenTelemetry.configure(app.class.module_parent_name.underscore)
unless Rails.const_defined?(:Console)
GovukOpenTelemetry.configure(app.class.module_parent_name.underscore)
end
end

config.before_initialize do
Expand Down
2 changes: 1 addition & 1 deletion lib/govuk_app_config/version.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module GovukAppConfig
VERSION = "9.0.1".freeze
VERSION = "9.0.2".freeze
end