sentry-ruby 4.1.0 → 4.1.5.pre.beta.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (51) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +7 -7
  3. metadata +31 -59
  4. data/.craft.yml +0 -19
  5. data/.gitignore +0 -11
  6. data/.rspec +0 -3
  7. data/.travis.yml +0 -6
  8. data/CHANGELOG.md +0 -89
  9. data/CODE_OF_CONDUCT.md +0 -74
  10. data/Gemfile +0 -16
  11. data/Rakefile +0 -8
  12. data/bin/console +0 -14
  13. data/bin/setup +0 -8
  14. data/lib/sentry-ruby.rb +0 -141
  15. data/lib/sentry/background_worker.rb +0 -37
  16. data/lib/sentry/backtrace.rb +0 -128
  17. data/lib/sentry/benchmarks/benchmark_transport.rb +0 -14
  18. data/lib/sentry/breadcrumb.rb +0 -25
  19. data/lib/sentry/breadcrumb/sentry_logger.rb +0 -87
  20. data/lib/sentry/breadcrumb_buffer.rb +0 -47
  21. data/lib/sentry/client.rb +0 -86
  22. data/lib/sentry/configuration.rb +0 -399
  23. data/lib/sentry/core_ext/object/deep_dup.rb +0 -57
  24. data/lib/sentry/core_ext/object/duplicable.rb +0 -153
  25. data/lib/sentry/dsn.rb +0 -48
  26. data/lib/sentry/event.rb +0 -177
  27. data/lib/sentry/hub.rb +0 -137
  28. data/lib/sentry/interface.rb +0 -22
  29. data/lib/sentry/interfaces/exception.rb +0 -11
  30. data/lib/sentry/interfaces/request.rb +0 -74
  31. data/lib/sentry/interfaces/single_exception.rb +0 -14
  32. data/lib/sentry/interfaces/stacktrace.rb +0 -57
  33. data/lib/sentry/linecache.rb +0 -44
  34. data/lib/sentry/logger.rb +0 -20
  35. data/lib/sentry/rack.rb +0 -4
  36. data/lib/sentry/rack/capture_exceptions.rb +0 -54
  37. data/lib/sentry/rack/interface.rb +0 -22
  38. data/lib/sentry/rake.rb +0 -17
  39. data/lib/sentry/scope.rb +0 -214
  40. data/lib/sentry/span.rb +0 -132
  41. data/lib/sentry/transaction.rb +0 -157
  42. data/lib/sentry/transaction_event.rb +0 -29
  43. data/lib/sentry/transport.rb +0 -87
  44. data/lib/sentry/transport/configuration.rb +0 -21
  45. data/lib/sentry/transport/dummy_transport.rb +0 -14
  46. data/lib/sentry/transport/http_transport.rb +0 -62
  47. data/lib/sentry/utils/exception_cause_chain.rb +0 -20
  48. data/lib/sentry/utils/real_ip.rb +0 -70
  49. data/lib/sentry/utils/request_id.rb +0 -16
  50. data/lib/sentry/version.rb +0 -3
  51. data/sentry-ruby.gemspec +0 -27
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 517c3e0bc0ab170dbd508034bf74b3a9ba62a1a32f13a992ba84d65f81249e01
4
- data.tar.gz: 8a86690e05e1695f15e2da33002ecd52b4596ef8dbd2e9c0a7461f94a8868906
3
+ metadata.gz: 86308e7f3445ce4567e7bf20e9d6d4ded1388fc8b1ddcb38a0b3e75d5c31952f
4
+ data.tar.gz: c02aa2dee269bf6d5be4518e3c7fdef9003bd57cac8fb80bdb165db81ac96351
5
5
  SHA512:
6
- metadata.gz: 3cc45e503a6ed19a5cc507ab0791087e432b612581498e84403fd806e0d9538ff02f57c2fbb64294ba9895514218bca05610f637a8708a752e6eaf42fa61bfaa
7
- data.tar.gz: 9eb027f449b6bdee43316e3b78364d1680d56442b5f34ec82b49059a9f28418a51448e24e45318efb022e526b62e067e410a8e78eb3b67678f1e18ce46866004
6
+ metadata.gz: a72d696a63fbe3a766b6d44f75af5dc85dc6f401b3a197c7dbcca10bf13d69510961aa5cc382b3f05caba069b9188dd95abebb2b46fbdf790eb144ff6b85bae7
7
+ data.tar.gz: dd3cb8715eb0d69d29efa54373ee876182e1688f8bf05d03c7e987ee911995ea5e241720caa8d5b8bfb37adc3b73687a87e807c194f7421f286f6320adacd8f4
data/README.md CHANGED
@@ -65,7 +65,7 @@ end
65
65
 
66
66
  ### Sentry doesn't report some kinds of data by default
67
67
 
68
- **Sentry ignores some exceptions by default** - most of these are related to 404s parameter parsing errors. [For a complete list, see the `IGNORE_DEFAULT` constant](https://github.com/getsentry/sentry-ruby/blob/master/sentry-ruby/lib/sentry/configuration.rb#L118) and the integration gems' `IGNORE_DEFAULT`, like [`sentry-rails`'s](https://github.com/getsentry/sentry-ruby/blob/update-readme/sentry-rails/lib/sentry/rails/configuration.rb#L12)
68
+ **Sentry ignores some exceptions by default** - most of these are related to 404s parameter parsing errors. [For a complete list, see the `IGNORE_DEFAULT` constant](https://github.com/getsentry/sentry-ruby/blob/master/sentry-ruby/lib/sentry/configuration.rb#L118) and the integration gems' `IGNORE_DEFAULT`, like [`sentry-rails`'s](https://github.com/getsentry/sentry-ruby/blob/master/sentry-rails/lib/sentry/rails/configuration.rb#L12)
69
69
 
70
70
  Sentry doesn't send personally identifiable information (pii) by default, such as request body, user ip or cookies. If you want those information to be sent, you can use the `send_default_pii` config option:
71
71
 
@@ -94,7 +94,7 @@ Sentry.init do |config|
94
94
  end
95
95
  ```
96
96
 
97
- To lean more about performance monitoring, please visit the [official documentation](https://docs.sentry.io/platforms/ruby/performance).
97
+ To learn more about performance monitoring, please visit the [official documentation](https://docs.sentry.io/platforms/ruby/performance).
98
98
 
99
99
  ### Usage
100
100
 
@@ -144,8 +144,8 @@ You're all set - but there's a few more settings you may want to know about too!
144
144
  **Before version 4.1.0**, `sentry-ruby` sends every event immediately. But it can be configured to send asynchronously:
145
145
 
146
146
  ```ruby
147
- config.async = lambda { |event|
148
- Thread.new { Sentry.send_event(event) }
147
+ config.async = lambda { |event, hint|
148
+ Thread.new { Sentry.send_event(event, hint) }
149
149
  }
150
150
  ```
151
151
 
@@ -154,13 +154,13 @@ Using a thread to send events will be adequate for truly parallel Ruby platforms
154
154
  Note that the naive example implementation has a major drawback - it can create an infinite number of threads. We recommend creating a background job, using your background job processor, that will send Sentry notifications in the background.
155
155
 
156
156
  ```ruby
157
- config.async = lambda { |event| SentryJob.perform_later(event) }
157
+ config.async = lambda { |event, hint| SentryJob.perform_later(event, hint) }
158
158
 
159
159
  class SentryJob < ActiveJob::Base
160
160
  queue_as :default
161
161
 
162
- def perform(event)
163
- Sentry.send_event(event)
162
+ def perform(event, hint)
163
+ Sentry.send_event(event, hint)
164
164
  end
165
165
  end
166
166
  ```
metadata CHANGED
@@ -1,15 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sentry-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.0
4
+ version: 4.1.5.pre.beta.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sentry Team
8
8
  autorequire:
9
- bindir: exe
9
+ bindir: bin
10
10
  cert_chain: []
11
- date: 2020-12-18 00:00:00.000000000 Z
11
+ date: 2021-01-21 00:00:00.000000000 Z
12
12
  dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: sentry-ruby-core
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - '='
18
+ - !ruby/object:Gem::Version
19
+ version: 4.1.5.pre.beta.0
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - '='
25
+ - !ruby/object:Gem::Version
26
+ version: 4.1.5.pre.beta.0
13
27
  - !ruby/object:Gem::Dependency
14
28
  name: faraday
15
29
  requirement: !ruby/object:Gem::Requirement
@@ -28,16 +42,22 @@ dependencies:
28
42
  name: concurrent-ruby
29
43
  requirement: !ruby/object:Gem::Requirement
30
44
  requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '1.0'
31
48
  - - ">="
32
49
  - !ruby/object:Gem::Version
33
- version: '0'
50
+ version: 1.0.2
34
51
  type: :runtime
35
52
  prerelease: false
36
53
  version_requirements: !ruby/object:Gem::Requirement
37
54
  requirements:
55
+ - - "~>"
56
+ - !ruby/object:Gem::Version
57
+ version: '1.0'
38
58
  - - ">="
39
59
  - !ruby/object:Gem::Version
40
- version: '0'
60
+ version: 1.0.2
41
61
  description: A gem that provides a client interface for the Sentry error logger
42
62
  email: accounts@sentry.io
43
63
  executables: []
@@ -46,63 +66,15 @@ extra_rdoc_files:
46
66
  - README.md
47
67
  - LICENSE.txt
48
68
  files:
49
- - ".craft.yml"
50
- - ".gitignore"
51
- - ".rspec"
52
- - ".travis.yml"
53
- - CHANGELOG.md
54
- - CODE_OF_CONDUCT.md
55
- - Gemfile
56
69
  - LICENSE.txt
57
70
  - README.md
58
- - Rakefile
59
- - bin/console
60
- - bin/setup
61
- - lib/sentry-ruby.rb
62
- - lib/sentry/background_worker.rb
63
- - lib/sentry/backtrace.rb
64
- - lib/sentry/benchmarks/benchmark_transport.rb
65
- - lib/sentry/breadcrumb.rb
66
- - lib/sentry/breadcrumb/sentry_logger.rb
67
- - lib/sentry/breadcrumb_buffer.rb
68
- - lib/sentry/client.rb
69
- - lib/sentry/configuration.rb
70
- - lib/sentry/core_ext/object/deep_dup.rb
71
- - lib/sentry/core_ext/object/duplicable.rb
72
- - lib/sentry/dsn.rb
73
- - lib/sentry/event.rb
74
- - lib/sentry/hub.rb
75
- - lib/sentry/interface.rb
76
- - lib/sentry/interfaces/exception.rb
77
- - lib/sentry/interfaces/request.rb
78
- - lib/sentry/interfaces/single_exception.rb
79
- - lib/sentry/interfaces/stacktrace.rb
80
- - lib/sentry/linecache.rb
81
- - lib/sentry/logger.rb
82
- - lib/sentry/rack.rb
83
- - lib/sentry/rack/capture_exceptions.rb
84
- - lib/sentry/rack/interface.rb
85
- - lib/sentry/rake.rb
86
- - lib/sentry/scope.rb
87
- - lib/sentry/span.rb
88
- - lib/sentry/transaction.rb
89
- - lib/sentry/transaction_event.rb
90
- - lib/sentry/transport.rb
91
- - lib/sentry/transport/configuration.rb
92
- - lib/sentry/transport/dummy_transport.rb
93
- - lib/sentry/transport/http_transport.rb
94
- - lib/sentry/utils/exception_cause_chain.rb
95
- - lib/sentry/utils/real_ip.rb
96
- - lib/sentry/utils/request_id.rb
97
- - lib/sentry/version.rb
98
- - sentry-ruby.gemspec
99
- homepage: https://github.com/getsentry/raven-ruby
71
+ homepage: https://github.com/getsentry/sentry-ruby
100
72
  licenses:
101
73
  - Apache-2.0
102
74
  metadata:
103
- homepage_uri: https://github.com/getsentry/raven-ruby
104
- source_code_uri: https://github.com/getsentry/raven-ruby
105
- changelog_uri: https://github.com/getsentry/raven-ruby/blob/master/CHANGELOG.md
75
+ homepage_uri: https://github.com/getsentry/sentry-ruby
76
+ source_code_uri: https://github.com/getsentry/sentry-ruby
77
+ changelog_uri: https://github.com/getsentry/sentry-ruby/blob/master/CHANGELOG.md
106
78
  post_install_message:
107
79
  rdoc_options: []
108
80
  require_paths:
@@ -114,9 +86,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
114
86
  version: '2.4'
115
87
  required_rubygems_version: !ruby/object:Gem::Requirement
116
88
  requirements:
117
- - - ">="
89
+ - - ">"
118
90
  - !ruby/object:Gem::Version
119
- version: '0'
91
+ version: 1.3.1
120
92
  requirements: []
121
93
  rubygems_version: 3.0.3
122
94
  signing_key:
data/.craft.yml DELETED
@@ -1,19 +0,0 @@
1
- minVersion: '0.13.2'
2
- github:
3
- owner: getsentry
4
- repo: sentry-ruby
5
- changelogPolicy: simple
6
- preReleaseCommand: ruby ../.scripts/bump-version.rb
7
- releaseBranchPrefix: release-sentry-ruby
8
- statusProvider:
9
- name: github
10
- artifactProvider:
11
- name: github
12
- targets:
13
- - name: gem
14
- - name: github
15
- tagPrefix: sentry-ruby-v
16
- - name: registry
17
- type: sdk
18
- config:
19
- canonical: 'gem:sentry-ruby'
data/.gitignore DELETED
@@ -1,11 +0,0 @@
1
- /.bundle/
2
- /.yardoc
3
- /_yardoc/
4
- /coverage/
5
- /doc/
6
- /pkg/
7
- /spec/reports/
8
- /tmp/
9
-
10
- # rspec failure tracking
11
- .rspec_status
data/.rspec DELETED
@@ -1,3 +0,0 @@
1
- --format documentation
2
- --color
3
- --require spec_helper
@@ -1,6 +0,0 @@
1
- ---
2
- language: ruby
3
- cache: bundler
4
- rvm:
5
- - 2.6.5
6
- before_install: gem install bundler -v 2.1.1
@@ -1,89 +0,0 @@
1
- # Changelog
2
-
3
- ## 4.1.0
4
-
5
- - Separate rack integration [#1138](https://github.com/getsentry/sentry-ruby/pull/1138)
6
- - Fixes [#1136](https://github.com/getsentry/sentry-ruby/pull/1136)
7
- - Fix event sampling [#1144](https://github.com/getsentry/sentry-ruby/pull/1144)
8
- - Merge & rename 2 Rack middlewares [#1147](https://github.com/getsentry/sentry-ruby/pull/1147)
9
- - Fixes [#1153](https://github.com/getsentry/sentry-ruby/pull/1153)
10
- - Removed `Sentry::Rack::Tracing` middleware and renamed `Sentry::Rack::CaptureException` to `Sentry::Rack::CaptureExceptions`.
11
- - Deep-copy spans [#1148](https://github.com/getsentry/sentry-ruby/pull/1148)
12
- - Move span recorder related code from Span to Transaction [#1149](https://github.com/getsentry/sentry-ruby/pull/1149)
13
- - Check SDK initialization before running integrations [#1151](https://github.com/getsentry/sentry-ruby/pull/1151)
14
- - Fixes [#1145](https://github.com/getsentry/sentry-ruby/pull/1145)
15
- - Refactor transport [#1154](https://github.com/getsentry/sentry-ruby/pull/1154)
16
- - Implement non-blocking event sending [#1155](https://github.com/getsentry/sentry-ruby/pull/1155)
17
- - Added `background_worker_threads` configuration option.
18
-
19
- ### Noticeable Changes
20
-
21
- #### Middleware Changes
22
-
23
- `Sentry::Rack::Tracing` is now removed. And `Sentry::Rack::CaptureException` has been renamed to `Sentry::Rack::CaptureExceptions`.
24
-
25
- #### Events Are Sent Asynchronously
26
-
27
- `sentry-ruby` now sends events asynchronously by default. The functionality works like this:
28
-
29
- 1. When the SDK is initialized, a `Sentry::BackgroundWorker` will be initialized too.
30
- 2. When an event is passed to `Client#capture_event`, instead of sending it directly with `Client#send_event`, we'll let the worker do it.
31
- 3. The worker will have a number of threads. And the one of the idle threads will pick the job and call `Client#send_event`.
32
- - If all the threads are busy, new jobs will be put into a queue, which has a limit of 30.
33
- - If the queue size is exceeded, new events will be dropped.
34
-
35
- However, if you still prefer to use your own async approach, that's totally fine. If you have `config.async` set, the worker won't initialize a thread pool and won't be used either.
36
-
37
- This functionality also introduces a new `background_worker_threads` config option. It allows you to decide how many threads should the worker hold. By default, the value will be the number of the processors your machine has. For example, if your machine has 4 processors, the value would be 4.
38
-
39
- Of course, you can always override the value to fit your use cases, like
40
-
41
- ```ruby
42
- config.background_worker_threads = 5 # the worker will have 5 threads for sending events
43
- ```
44
-
45
- You can also disable this new non-blocking behaviour by giving a `0` value:
46
-
47
- ```ruby
48
- config.background_worker_threads = 0 # all events will be sent synchronously
49
- ```
50
-
51
- ## 4.0.1
52
-
53
- - Add rake integration: [1137](https://github.com/getsentry/sentry-ruby/pull/1137)
54
- - Make Event's interfaces accessible: [1135](https://github.com/getsentry/sentry-ruby/pull/1135)
55
- - ActiveSupportLogger should only record events that has a started time: [1132](https://github.com/getsentry/sentry-ruby/pull/1132)
56
-
57
- ## 4.0.0
58
-
59
- - Only documents update for the official release and no API/feature changes.
60
-
61
- ## 0.3.0
62
-
63
- - Major API changes: [1123](https://github.com/getsentry/sentry-ruby/pull/1123)
64
- - Support event hint: [1122](https://github.com/getsentry/sentry-ruby/pull/1122)
65
- - Add request-id tag to events: [1120](https://github.com/getsentry/sentry-ruby/pull/1120) (by @tvec)
66
-
67
- ## 0.2.0
68
-
69
- - Multiple fixes and refactorings
70
- - Tracing support
71
-
72
- ## 0.1.3
73
-
74
- Fix require reference
75
-
76
- ## 0.1.2
77
-
78
- - Fix: Fix async callback [1098](https://github.com/getsentry/sentry-ruby/pull/1098)
79
- - Refactor: Some code cleanup [1100](https://github.com/getsentry/sentry-ruby/pull/1100)
80
- - Refactor: Remove Event options [1101](https://github.com/getsentry/sentry-ruby/pull/1101)
81
-
82
- ## 0.1.1
83
-
84
- - Feature: Allow passing custom scope to Hub#capture* helpers [1086](https://github.com/getsentry/sentry-ruby/pull/1086)
85
-
86
- ## 0.1.0
87
-
88
- First version
89
-
@@ -1,74 +0,0 @@
1
- # Contributor Covenant Code of Conduct
2
-
3
- ## Our Pledge
4
-
5
- In the interest of fostering an open and welcoming environment, we as
6
- contributors and maintainers pledge to making participation in our project and
7
- our community a harassment-free experience for everyone, regardless of age, body
8
- size, disability, ethnicity, gender identity and expression, level of experience,
9
- nationality, personal appearance, race, religion, or sexual identity and
10
- orientation.
11
-
12
- ## Our Standards
13
-
14
- Examples of behavior that contributes to creating a positive environment
15
- include:
16
-
17
- * Using welcoming and inclusive language
18
- * Being respectful of differing viewpoints and experiences
19
- * Gracefully accepting constructive criticism
20
- * Focusing on what is best for the community
21
- * Showing empathy towards other community members
22
-
23
- Examples of unacceptable behavior by participants include:
24
-
25
- * The use of sexualized language or imagery and unwelcome sexual attention or
26
- advances
27
- * Trolling, insulting/derogatory comments, and personal or political attacks
28
- * Public or private harassment
29
- * Publishing others' private information, such as a physical or electronic
30
- address, without explicit permission
31
- * Other conduct which could reasonably be considered inappropriate in a
32
- professional setting
33
-
34
- ## Our Responsibilities
35
-
36
- Project maintainers are responsible for clarifying the standards of acceptable
37
- behavior and are expected to take appropriate and fair corrective action in
38
- response to any instances of unacceptable behavior.
39
-
40
- Project maintainers have the right and responsibility to remove, edit, or
41
- reject comments, commits, code, wiki edits, issues, and other contributions
42
- that are not aligned to this Code of Conduct, or to ban temporarily or
43
- permanently any contributor for other behaviors that they deem inappropriate,
44
- threatening, offensive, or harmful.
45
-
46
- ## Scope
47
-
48
- This Code of Conduct applies both within project spaces and in public spaces
49
- when an individual is representing the project or its community. Examples of
50
- representing a project or community include using an official project e-mail
51
- address, posting via an official social media account, or acting as an appointed
52
- representative at an online or offline event. Representation of a project may be
53
- further defined and clarified by project maintainers.
54
-
55
- ## Enforcement
56
-
57
- Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
- reported by contacting the project team at stan001212@gmail.com. All
59
- complaints will be reviewed and investigated and will result in a response that
60
- is deemed necessary and appropriate to the circumstances. The project team is
61
- obligated to maintain confidentiality with regard to the reporter of an incident.
62
- Further details of specific enforcement policies may be posted separately.
63
-
64
- Project maintainers who do not follow or enforce the Code of Conduct in good
65
- faith may face temporary or permanent repercussions as determined by other
66
- members of the project's leadership.
67
-
68
- ## Attribution
69
-
70
- This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
- available at [https://contributor-covenant.org/version/1/4][version]
72
-
73
- [homepage]: https://contributor-covenant.org
74
- [version]: https://contributor-covenant.org/version/1/4/
data/Gemfile DELETED
@@ -1,16 +0,0 @@
1
- source "https://rubygems.org"
2
-
3
- # Specify your gem's dependencies in sentry-ruby.gemspec
4
- gemspec
5
-
6
- gem "rake", "~> 12.0"
7
- gem "rspec", "~> 3.0"
8
- gem "codecov"
9
-
10
- gem "pry"
11
- gem "rack" unless ENV["WITHOUT_RACK"] == "1"
12
-
13
- gem "benchmark-ips"
14
- gem "benchmark_driver"
15
- gem "benchmark-ipsa"
16
- gem "benchmark-memory"
data/Rakefile DELETED
@@ -1,8 +0,0 @@
1
- require "bundler/gem_tasks"
2
- require "rspec/core/rake_task"
3
-
4
- RSpec::Core::RakeTask.new(:spec).tap do |task|
5
- task.rspec_opts = "--order rand"
6
- end
7
-
8
- task :default => :spec
@@ -1,14 +0,0 @@
1
- #!/usr/bin/env ruby
2
-
3
- require "bundler/setup"
4
- require "sentry/ruby"
5
-
6
- # You can add fixtures and/or initialization code here to make experimenting
7
- # with your gem easier. You can also use a different console, if you like.
8
-
9
- # (If you use this, don't forget to add pry to your Gemfile!)
10
- # require "pry"
11
- # Pry.start
12
-
13
- require "irb"
14
- IRB.start(__FILE__)