Skip to content

Commit 8c693fb

Browse files
author
getsentry-bot
committed
Merge branch 'release/10.10.0'
2 parents cd71888 + ded36e8 commit 8c693fb

File tree

20 files changed

+10
-1186
lines changed

20 files changed

+10
-1186
lines changed

config/config.exs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,9 @@ if config_env() == :test do
1010
send_result: :sync,
1111
send_max_attempts: 1,
1212
dedup_events: false,
13-
test_mode: true,
14-
traces_sample_rate: 1.0
13+
test_mode: true
1514

1615
config :logger, backends: []
17-
18-
config :opentelemetry, span_processor: {Sentry.OpenTelemetry.SpanProcessor, []}
19-
20-
config :opentelemetry,
21-
sampler: {Sentry.OpenTelemetry.Sampler, [drop: ["Elixir.Oban.Stager process"]]}
2216
end
2317

2418
config :phoenix, :json_library, if(Code.ensure_loaded?(JSON), do: JSON, else: Jason)

lib/sentry/application.ex

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,6 @@ defmodule Sentry.Application do
2626

2727
integrations_config = Config.integrations()
2828

29-
maybe_span_storage =
30-
if Config.tracing?() do
31-
[Sentry.OpenTelemetry.SpanStorage]
32-
else
33-
[]
34-
end
35-
3629
children =
3730
[
3831
{Registry, keys: :unique, name: Sentry.Transport.SenderRegistry},
@@ -46,7 +39,6 @@ defmodule Sentry.Application do
4639
]}
4740
] ++
4841
maybe_http_client_spec ++
49-
maybe_span_storage ++
5042
[Sentry.Transport.SenderPool]
5143

5244
cache_loaded_applications()

lib/sentry/client.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ defmodule Sentry.Client do
117117

118118
result_type = Keyword.get_lazy(opts, :result, &Config.send_result/0)
119119
client = Keyword.get_lazy(opts, :client, &Config.client/0)
120-
sample_rate = Keyword.get_lazy(opts, :sample_rate, &Config.traces_sample_rate/0)
120+
sample_rate = Keyword.get_lazy(opts, :sample_rate, &Config.sample_rate/0)
121121
before_send = Keyword.get_lazy(opts, :before_send, &Config.before_send/0)
122122
after_send_event = Keyword.get_lazy(opts, :after_send_event, &Config.after_send_event/0)
123123

lib/sentry/config.ex

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -143,20 +143,6 @@ defmodule Sentry.Config do
143143
be used as the value for this option.
144144
"""
145145
],
146-
traces_sample_rate: [
147-
type: {:custom, __MODULE__, :__validate_traces_sample_rate__, []},
148-
default: 0.0,
149-
doc: """
150-
The sample rate for transaction events. A value between `0.0` and `1.0` (inclusive).
151-
A value of `0.0` means no transactions will be sampled, while `1.0` means all transactions
152-
will be sampled. This value is also used to determine if tracing is enabled: if it's
153-
greater than `0`, tracing is enabled.
154-
155-
Tracing requires OpenTelemetry packages to work. See [the
156-
OpenTelemetry setup documentation](https://opentelemetry.io/docs/languages/erlang/getting-started/)
157-
for guides on how to set it up.
158-
"""
159-
],
160146
included_environments: [
161147
type: {:or, [{:in, [:all]}, {:list, {:or, [:atom, :string]}}]},
162148
deprecated: "Use :dsn to control whether to send events to Sentry.",
@@ -621,9 +607,6 @@ defmodule Sentry.Config do
621607
@spec sample_rate() :: float()
622608
def sample_rate, do: fetch!(:sample_rate)
623609

624-
@spec traces_sample_rate() :: float()
625-
def traces_sample_rate, do: fetch!(:traces_sample_rate)
626-
627610
@spec hackney_opts() :: keyword()
628611
def hackney_opts, do: fetch!(:hackney_opts)
629612

@@ -661,9 +644,6 @@ defmodule Sentry.Config do
661644
@spec integrations() :: keyword()
662645
def integrations, do: fetch!(:integrations)
663646

664-
@spec tracing?() :: boolean()
665-
def tracing?, do: fetch!(:traces_sample_rate) > 0.0
666-
667647
@spec put_config(atom(), term()) :: :ok
668648
def put_config(key, value) when is_atom(key) do
669649
unless key in @valid_keys do
@@ -763,15 +743,6 @@ defmodule Sentry.Config do
763743
end
764744
end
765745

766-
def __validate_traces_sample_rate__(float) do
767-
if is_float(float) and float >= 0.0 and float <= 1.0 do
768-
{:ok, float}
769-
else
770-
{:error,
771-
"expected :traces_sample_rate to be a float between 0.0 and 1.0 (included), got: #{inspect(float)}"}
772-
end
773-
end
774-
775746
def __validate_json_library__(nil) do
776747
{:error, "nil is not a valid value for the :json_library option"}
777748
end

lib/sentry/opentelemetry/sampler.ex

Lines changed: 0 additions & 31 deletions
This file was deleted.

lib/sentry/opentelemetry/span_processor.ex

Lines changed: 0 additions & 193 deletions
This file was deleted.

0 commit comments

Comments
 (0)