Skip to content

Commit

Permalink
Merge pull request #537 from DataDog/0.15-dev
Browse files Browse the repository at this point in the history
0.15.0 to stable
  • Loading branch information
delner authored Sep 12, 2018
2 parents e80a949 + 123c17c commit 22f9943
Show file tree
Hide file tree
Showing 16 changed files with 344 additions and 50 deletions.
22 changes: 14 additions & 8 deletions Appraisals
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ elsif Gem::Version.new('1.9.3') <= Gem::Version.new(RUBY_VERSION) \
gem 'activerecord', '3.2.22.5'
gem 'activerecord-mysql-adapter', platform: :ruby
gem 'aws-sdk', '~> 2.0'
gem 'concurrent-ruby'
gem 'dalli'
gem 'delayed_job'
gem 'delayed_job_active_record'
Expand Down Expand Up @@ -150,6 +151,7 @@ elsif Gem::Version.new('2.0.0') <= Gem::Version.new(RUBY_VERSION) \
gem 'activerecord', '3.2.22.5'
gem 'activerecord-mysql-adapter', platform: :ruby
gem 'aws-sdk', '~> 2.0'
gem 'concurrent-ruby'
gem 'dalli'
gem 'delayed_job'
gem 'delayed_job_active_record'
Expand Down Expand Up @@ -253,6 +255,7 @@ elsif Gem::Version.new('2.1.0') <= Gem::Version.new(RUBY_VERSION) \
gem 'activerecord', '3.2.22.5'
gem 'activerecord-mysql-adapter', platform: :ruby
gem 'aws-sdk', '~> 2.0'
gem 'concurrent-ruby'
gem 'dalli'
gem 'delayed_job'
gem 'delayed_job_active_record'
Expand Down Expand Up @@ -360,24 +363,24 @@ elsif Gem::Version.new('2.2.0') <= Gem::Version.new(RUBY_VERSION) \
end

appraise 'rails5-mysql2' do
gem 'rails', '~> 5.1.6'
gem 'rails', '~> 5.2.1'
gem 'mysql2', '< 0.5', platform: :ruby
end

appraise 'rails5-postgres' do
gem 'rails', '~> 5.1.6'
gem 'rails', '~> 5.2.1'
gem 'pg', '< 1.0', platform: :ruby
end

appraise 'rails5-postgres-redis' do
gem 'rails', '~> 5.1.6'
gem 'rails', '~> 5.2.1'
gem 'pg', '< 1.0', platform: :ruby
gem 'redis-rails'
gem 'redis'
end

appraise 'rails5-postgres-sidekiq' do
gem 'rails', '~> 5.1.6'
gem 'rails', '~> 5.2.1'
gem 'pg', '< 1.0', platform: :ruby
gem 'sidekiq'
gem 'activejob'
Expand All @@ -387,6 +390,7 @@ elsif Gem::Version.new('2.2.0') <= Gem::Version.new(RUBY_VERSION) \
gem 'active_model_serializers', '>= 0.10.0'
gem 'activerecord', '< 5.1.5'
gem 'aws-sdk'
gem 'concurrent-ruby'
gem 'dalli'
gem 'delayed_job'
gem 'delayed_job_active_record'
Expand Down Expand Up @@ -497,24 +501,24 @@ elsif Gem::Version.new('2.3.0') <= Gem::Version.new(RUBY_VERSION) \
end

appraise 'rails5-mysql2' do
gem 'rails', '~> 5.1.6'
gem 'rails', '~> 5.2.1'
gem 'mysql2', '< 0.5', platform: :ruby
end

appraise 'rails5-postgres' do
gem 'rails', '~> 5.1.6'
gem 'rails', '~> 5.2.1'
gem 'pg', '< 1.0', platform: :ruby
end

appraise 'rails5-postgres-redis' do
gem 'rails', '~> 5.1.6'
gem 'rails', '~> 5.2.1'
gem 'pg', '< 1.0', platform: :ruby
gem 'redis-rails'
gem 'redis'
end

appraise 'rails5-postgres-sidekiq' do
gem 'rails', '~> 5.1.6'
gem 'rails', '~> 5.2.1'
gem 'pg', '< 1.0', platform: :ruby
gem 'sidekiq'
gem 'activejob'
Expand All @@ -524,6 +528,7 @@ elsif Gem::Version.new('2.3.0') <= Gem::Version.new(RUBY_VERSION) \
gem 'active_model_serializers', '>= 0.10.0'
gem 'activerecord', '< 5.1.5'
gem 'aws-sdk'
gem 'concurrent-ruby'
gem 'dalli'
gem 'delayed_job'
gem 'delayed_job_active_record'
Expand Down Expand Up @@ -555,6 +560,7 @@ elsif Gem::Version.new('2.4.0') <= Gem::Version.new(RUBY_VERSION)
gem 'active_model_serializers', '>= 0.10.0'
gem 'activerecord', '< 5.1.5'
gem 'aws-sdk'
gem 'concurrent-ruby'
gem 'dalli'
gem 'delayed_job'
gem 'delayed_job_active_record'
Expand Down
23 changes: 20 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,22 @@

## [Unreleased (beta)]

## [0.15.0] - 2018-09-12

Release notes: https://github.com/DataDog/dd-trace-rb/releases/tag/v0.15.0

Git diff: https://github.com/DataDog/dd-trace-rb/compare/v0.14.2...v0.15.0

### Added

- Rails 5.2 support (#535)
- Context propagation support for `Concurrent::Future` (#415, #496)

### Fixed

- Grape uninitialized constant TraceMiddleware (#525, #533) (@dim)
- Signed integer trace and span IDs being discarded in distributed traces (#530) (@alloy)

## [0.14.2] - 2018-08-23

Release notes: https://github.com/DataDog/dd-trace-rb/releases/tag/v0.14.2
Expand All @@ -14,7 +30,6 @@ Git diff: https://github.com/DataDog/dd-trace-rb/compare/v0.14.1...v0.14.2

- Sampling priority from request headers not being used (#521)


## [0.14.1] - 2018-08-21

Release notes: https://github.com/DataDog/dd-trace-rb/releases/tag/v0.14.1
Expand Down Expand Up @@ -485,8 +500,10 @@ Release notes: https://github.com/DataDog/dd-trace-rb/releases/tag/v0.3.1

Git diff: https://github.com/DataDog/dd-trace-rb/compare/v0.3.0...v0.3.1

[Unreleased (stable)]: https://github.com/DataDog/dd-trace-rb/compare/v0.14.1...master
[Unreleased (beta)]: https://github.com/DataDog/dd-trace-rb/compare/v0.14.1...0.15-dev
[Unreleased (stable)]: https://github.com/DataDog/dd-trace-rb/compare/v0.15.0...master
[Unreleased (beta)]: https://github.com/DataDog/dd-trace-rb/compare/v0.15.0...0.16-dev
[0.15.0]: https://github.com/DataDog/dd-trace-rb/compare/v0.14.2...v0.15.0
[0.14.2]: https://github.com/DataDog/dd-trace-rb/compare/v0.14.1...v0.14.2
[0.14.1]: https://github.com/DataDog/dd-trace-rb/compare/v0.14.0...v0.14.1
[0.14.0]: https://github.com/DataDog/dd-trace-rb/compare/v0.13.2...v0.14.0
[0.14.0.rc1]: https://github.com/DataDog/dd-trace-rb/compare/v0.14.0.beta2...v0.14.0.rc1
Expand Down
7 changes: 7 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ namespace :spec do
:delayed_job,
:active_support,
:aws,
:concurrent_ruby,
:dalli,
:elasticsearch,
:excon,
Expand Down Expand Up @@ -230,6 +231,7 @@ task :ci do
sh 'bundle exec appraisal contrib-old rake spec:active_record'
sh 'bundle exec appraisal contrib-old rake spec:delayed_job'
sh 'bundle exec appraisal contrib-old rake spec:active_support'
sh 'bundle exec appraisal contrib-old rake spec:concurrent_ruby'
sh 'bundle exec appraisal contrib-old rake spec:dalli'
sh 'bundle exec appraisal contrib-old rake spec:elasticsearch'
sh 'bundle exec appraisal contrib-old rake spec:excon'
Expand Down Expand Up @@ -275,6 +277,7 @@ task :ci do
sh 'bundle exec appraisal contrib-old rake spec:active_record'
sh 'bundle exec appraisal contrib-old rake spec:delayed_job'
sh 'bundle exec appraisal contrib-old rake spec:active_support'
sh 'bundle exec appraisal contrib-old rake spec:concurrent_ruby'
sh 'bundle exec appraisal contrib-old rake spec:dalli'
sh 'bundle exec appraisal contrib-old rake spec:elasticsearch'
sh 'bundle exec appraisal contrib-old rake spec:excon'
Expand Down Expand Up @@ -323,6 +326,7 @@ task :ci do
sh 'bundle exec appraisal contrib-old rake spec:active_record'
sh 'bundle exec appraisal contrib-old rake spec:delayed_job'
sh 'bundle exec appraisal contrib-old rake spec:active_support'
sh 'bundle exec appraisal contrib-old rake spec:concurrent_ruby'
sh 'bundle exec appraisal contrib-old rake spec:dalli'
sh 'bundle exec appraisal contrib-old rake spec:elasticsearch'
sh 'bundle exec appraisal contrib-old rake spec:excon'
Expand Down Expand Up @@ -377,6 +381,7 @@ task :ci do
sh 'bundle exec appraisal contrib rake spec:active_record'
sh 'bundle exec appraisal contrib rake spec:delayed_job'
sh 'bundle exec appraisal contrib rake spec:active_support'
sh 'bundle exec appraisal contrib rake spec:concurrent_ruby'
sh 'bundle exec appraisal contrib rake spec:dalli'
sh 'bundle exec appraisal contrib rake spec:elasticsearch'
sh 'bundle exec appraisal contrib rake spec:excon'
Expand Down Expand Up @@ -442,6 +447,7 @@ task :ci do
sh 'bundle exec appraisal contrib rake spec:active_record'
sh 'bundle exec appraisal contrib rake spec:delayed_job'
sh 'bundle exec appraisal contrib rake spec:active_support'
sh 'bundle exec appraisal contrib rake spec:concurrent_ruby'
sh 'bundle exec appraisal contrib rake spec:dalli'
sh 'bundle exec appraisal contrib rake spec:excon'
sh 'bundle exec appraisal contrib rake spec:elasticsearch'
Expand Down Expand Up @@ -506,6 +512,7 @@ task :ci do
sh 'bundle exec appraisal contrib rake spec:active_record'
sh 'bundle exec appraisal contrib rake spec:delayed_job'
sh 'bundle exec appraisal contrib rake spec:active_support'
sh 'bundle exec appraisal contrib rake spec:concurrent_ruby'
sh 'bundle exec appraisal contrib rake spec:dalli'
sh 'bundle exec appraisal contrib rake spec:elasticsearch'
sh 'bundle exec appraisal contrib rake spec:excon'
Expand Down
89 changes: 63 additions & 26 deletions docs/GettingStarted.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ For descriptions of terminology used in APM, take a look at the [official docume
- [Integration instrumentation](#integration-instrumentation)
- [Active Record](#active-record)
- [AWS](#aws)
- [Concurrent Ruby](#concurrent-ruby)
- [Dalli](#dalli)
- [DelayedJob](#delayedjob)
- [Elastic Search](#elastic-search)
Expand Down Expand Up @@ -265,32 +266,33 @@ end
For a list of available integrations, and their configuration options, please refer to the following:
| Name | Key | Versions Supported | How to configure | Gem source |
| -------------- | --------------- | ---------------------- | ------------------------- | ------------------------------------------------------------------------------ |
| Active Record | `active_record` | `>= 3.2, < 5.2` | *[Link](#active-record)* | *[Link](https://github.com/rails/rails/tree/master/activerecord)* |
| AWS | `aws` | `>= 2.0` | *[Link](#aws)* | *[Link](https://github.com/aws/aws-sdk-ruby)* |
| Dalli | `dalli` | `>= 2.7` | *[Link](#dalli)* | *[Link](https://github.com/petergoldstein/dalli)* |
| DelayedJob | `delayed_job` | `>= 4.1` | *[Link](#delayedjob)* | *[Link](https://github.com/collectiveidea/delayed_job)* |
| Elastic Search | `elasticsearch` | `>= 6.0` | *[Link](#elastic-search)* | *[Link](https://github.com/elastic/elasticsearch-ruby)* |
| Excon | `excon` | `>= 0.62` | *[Link](#excon)* | *[Link](https://github.com/excon/excon)* |
| Faraday | `faraday` | `>= 0.14` | *[Link](#faraday)* | *[Link](https://github.com/lostisland/faraday)* |
| gRPC | `grpc` | `>= 1.10` | *[Link](#grpc)* | *[Link](https://github.com/grpc/grpc/tree/master/src/rubyc)* |
| Grape | `grape` | `>= 1.0` | *[Link](#grape)* | *[Link](https://github.com/ruby-grape/grape)* |
| GraphQL | `graphql` | `>= 1.7.9` | *[Link](#graphql)* | *[Link](https://github.com/rmosolgo/graphql-ruby)* |
| MongoDB | `mongo` | `>= 2.0, < 2.5` | *[Link](#mongodb)* | *[Link](https://github.com/mongodb/mongo-ruby-driver)* |
| MySQL2 | `mysql2` | `>= 0.5` | *[Link](#mysql2)* | *[Link](https://github.com/brianmario/mysql2)* |
| Net/HTTP | `http` | *(Any supported Ruby)* | *[Link](#nethttp)* | *[Link](https://ruby-doc.org/stdlib-2.4.0/libdoc/net/http/rdoc/Net/HTTP.html)* |
| Racecar | `racecar` | `>= 0.3.5` | *[Link](#racecar)* | *[Link](https://github.com/zendesk/racecar)* |
| Rack | `rack` | `>= 1.4.7` | *[Link](#rack)* | *[Link](https://github.com/rack/rack)* |
| Rails | `rails` | `>= 3.2, < 5.2` | *[Link](#rails)* | *[Link](https://github.com/rails/rails)* |
| Rake | `rake` | `>= 12.0` | *[Link](#rake)* | *[Link](https://github.com/ruby/rake)* |
| Redis | `redis` | `>= 3.2, < 4.0` | *[Link](#redis)* | *[Link](https://github.com/redis/redis-rb)* |
| Rest Client | `rest-client` | `>= 1.8` | *[Link](#restclient)* | *[Link](https://github.com/rest-client/rest-client)* |
| Resque | `resque` | `>= 1.0, < 2.0` | *[Link](#resque)* | *[Link](https://github.com/resque/resque)* |
| Sequel | `sequel` | `>= 3.41` | *[Link](#sequel)* | *[Link](https://github.com/jeremyevans/sequel)* |
| Sidekiq | `sidekiq` | `>= 4.0` | *[Link](#sidekiq)* | *[Link](https://github.com/mperham/sidekiq)* |
| Sinatra | `sinatra` | `>= 1.4.5` | *[Link](#sinatra)* | *[Link](https://github.com/sinatra/sinatra)* |
| Sucker Punch | `sucker_punch` | `>= 2.0` | *[Link](#sucker-punch)* | *[Link](https://github.com/brandonhilkert/sucker_punch)* |
| Name | Key | Versions Supported | How to configure | Gem source |
| -------------- | ----------------- | ------------------------ | ------------------------- | ------------------------------------------------------------------------------ |
| Active Record | `active_record` | `>= 3.2, < 6.0` | *[Link](#active-record)* | *[Link](https://github.com/rails/rails/tree/master/activerecord)* |
| AWS | `aws` | `>= 2.0` | *[Link](#aws)* | *[Link](https://github.com/aws/aws-sdk-ruby)* |
| Concurrent Ruby| `concurrent_ruby` | `>= 0.9` | *[Link](#concurrent-ruby)*| *[Link](https://github.com/ruby-concurrency/concurrent-ruby)* |
| Dalli | `dalli` | `>= 2.7` | *[Link](#dalli)* | *[Link](https://github.com/petergoldstein/dalli)* |
| DelayedJob | `delayed_job` | `>= 4.1` | *[Link](#delayedjob)* | *[Link](https://github.com/collectiveidea/delayed_job)* |
| Elastic Search | `elasticsearch` | `>= 6.0` | *[Link](#elastic-search)* | *[Link](https://github.com/elastic/elasticsearch-ruby)* |
| Excon | `excon` | `>= 0.62` | *[Link](#excon)* | *[Link](https://github.com/excon/excon)* |
| Faraday | `faraday` | `>= 0.14` | *[Link](#faraday)* | *[Link](https://github.com/lostisland/faraday)* |
| gRPC | `grpc` | `>= 1.10` | *[Link](#grpc)* | *[Link](https://github.com/grpc/grpc/tree/master/src/rubyc)* |
| Grape | `grape` | `>= 1.0` | *[Link](#grape)* | *[Link](https://github.com/ruby-grape/grape)* |
| GraphQL | `graphql` | `>= 1.7.9` | *[Link](#graphql)* | *[Link](https://github.com/rmosolgo/graphql-ruby)* |
| MongoDB | `mongo` | `>= 2.0, < 2.5` | *[Link](#mongodb)* | *[Link](https://github.com/mongodb/mongo-ruby-driver)* |
| MySQL2 | `mysql2` | `>= 0.5` | *[Link](#mysql2)* | *[Link](https://github.com/brianmario/mysql2)* |
| Net/HTTP | `http` | *(Any supported Ruby)* | *[Link](#nethttp)* | *[Link](https://ruby-doc.org/stdlib-2.4.0/libdoc/net/http/rdoc/Net/HTTP.html)* |
| Racecar | `racecar` | `>= 0.3.5` | *[Link](#racecar)* | *[Link](https://github.com/zendesk/racecar)* |
| Rack | `rack` | `>= 1.4.7` | *[Link](#rack)* | *[Link](https://github.com/rack/rack)* |
| Rails | `rails` | `>= 3.2, <= 6.0` | *[Link](#rails)* | *[Link](https://github.com/rails/rails)* |
| Rake | `rake` | `>= 12.0` | *[Link](#rake)* | *[Link](https://github.com/ruby/rake)* |
| Redis | `redis` | `>= 3.2, < 4.0` | *[Link](#redis)* | *[Link](https://github.com/redis/redis-rb)* |
| Rest Client | `rest-client` | `>= 1.8` | *[Link](#restclient)* | *[Link](https://github.com/rest-client/rest-client)* |
| Resque | `resque` | `>= 1.0, < 2.0` | *[Link](#resque)* | *[Link](https://github.com/resque/resque)* |
| Sequel | `sequel` | `>= 3.41` | *[Link](#sequel)* | *[Link](https://github.com/jeremyevans/sequel)* |
| Sidekiq | `sidekiq` | `>= 4.0` | *[Link](#sidekiq)* | *[Link](https://github.com/mperham/sidekiq)* |
| Sinatra | `sinatra` | `>= 1.4.5` | *[Link](#sinatra)* | *[Link](https://github.com/sinatra/sinatra)* |
| Sucker Punch | `sucker_punch` | `>= 2.0` | *[Link](#sucker-punch)* | *[Link](https://github.com/brandonhilkert/sucker_punch)* |
### Active Record
Expand Down Expand Up @@ -379,6 +381,32 @@ Where `options` is an optional `Hash` that accepts the following parameters:
| --- | --- | --- |
| ``service_name`` | Service name used for `aws` instrumentation | aws |
### Concurrent Ruby
The Concurrent Ruby integration adds support for context propagation when using `::Concurrent::Future`.
Making sure that code traced within the `Future#execute` will have correct parent set.
To activate your integration, use the ``Datadog.configure`` method:
```ruby
# Inside Rails initializer or equivalent
Datadog.configure do |c|
c.use :concurrent_ruby # patches ::Concurrent::Future to use ExecutorService that propagates context
end
# Pass context into code executed within Concurrent::Future
Datadog.tracer.trace('outer') do
Concurrent::Future.execute { Datadog.tracer.trace('inner') { } }.wait
end
```
The `use :concurrent_ruby` method accepts the following parameters:
| Key | Description | Default |
| --- | --- | --- |
| ``tracer`` | A ``Datadog::Tracer`` instance used to instrument the application. Usually you don't need to set that. | ``Datadog.tracer`` |


### Dalli

Dalli integration will trace all calls to your ``memcached`` server:
Expand Down Expand Up @@ -846,6 +874,15 @@ Where `options` is an optional `Hash` that accepts the following parameters:
| ``tracer`` | A ``Datadog::Tracer`` instance used to instrument the application. Usually you don't need to set that. | ``Datadog.tracer`` |
| ``databases`` | Hash of tracer settings to use for each database connection. See [ActiveRecord](#activerecord) for more details. | ``{}`` |
**Supported versions**
| Ruby Versions | Supported Rails Versions |
| ------------- | ------------------------ |
| 1.9.3 - 2.0 | 3.0 - 3.2 |
| 2.1 | 3.0 - 4.2 |
| 2.2 - 2.3 | 3.0 - 5.2 |
| 2.4 - 2.5 | 4.2.8 - 5.2 |
### Rake
You can add instrumentation around your Rake tasks by activating the `rake` integration. Each task and its subsequent subtasks will be traced.
Expand Down
Loading

0 comments on commit 22f9943

Please sign in to comment.