hermes-rb 0.6.1 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +43 -0
- data/.gitignore +1 -0
- data/.ruby-version +1 -0
- data/Appraisals +12 -0
- data/Changelog.md +3 -0
- data/Gemfile.lock +37 -27
- data/gemfiles/rails.5.2.gemfile +9 -0
- data/gemfiles/rails.6.1.gemfile +9 -0
- data/gemfiles/rails.7.0.gemfile +9 -0
- data/hermes-rb.gemspec +1 -0
- data/lib/hermes/rb/version.rb +1 -1
- data/lib/hermes/tracers/datadog.rb +7 -1
- metadata +23 -4
- data/.travis.yml +0 -17
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA256:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: 01e56f5cf846518bbedba098f5d3129cea50b81390e948eb8b3640cd98b4ee58
         | 
| 4 | 
            +
              data.tar.gz: d672a90b3b7ddec2b8c7fcf3a57307c208297362dd16191c11792f4d8ddc4d4f
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: 9440e207aaddc314e99d66e87c9d0296b80df0280c2d4112e4d1b6530fcf3bf9da17fcdb44f398ae8f607cf6c4dbf4eed66ba44b6836d748781ce997100777d6
         | 
| 7 | 
            +
              data.tar.gz: 55886c1f907cf1031bdf2fb8528bfa5e4efeb062161aef0e64c6b6bf601481eb411736b93e24b0b21b5a11636d0a308f5c73bce4508e2071698c7b670e5eceff
         | 
| @@ -0,0 +1,43 @@ | |
| 1 | 
            +
            name: CI
         | 
| 2 | 
            +
            on: [pull_request]
         | 
| 3 | 
            +
            jobs:
         | 
| 4 | 
            +
              rspec:
         | 
| 5 | 
            +
                strategy:
         | 
| 6 | 
            +
                  fail-fast: false
         | 
| 7 | 
            +
                  matrix:
         | 
| 8 | 
            +
                    include:
         | 
| 9 | 
            +
                      - { ruby: '2.7', rails: '5.2' }
         | 
| 10 | 
            +
                      - { ruby: '3.0', rails: '6.1' }
         | 
| 11 | 
            +
                      - { ruby: '3.1', rails: '7.0' }
         | 
| 12 | 
            +
                runs-on: ubuntu-latest
         | 
| 13 | 
            +
                env:
         | 
| 14 | 
            +
                  BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/rails.${{ matrix.rails }}.gemfile
         | 
| 15 | 
            +
                  DATABASE_URL: "postgresql://postgres:postgres@127.0.0.1:5432/hermes-rb-test"
         | 
| 16 | 
            +
                  DISTRIBUTED_TRACING_DATABASE_URI: "postgresql://postgres:postgres@127.0.0.1:5432/hermes-rb-test"
         | 
| 17 | 
            +
                  HUTCH_URI: "amqp://guest:guest@127.0.0.1:5672"
         | 
| 18 | 
            +
                  HUTCH_ENABLE_HTTP_API_USE: false
         | 
| 19 | 
            +
                services:
         | 
| 20 | 
            +
                  postgres:
         | 
| 21 | 
            +
                    image: postgres:14
         | 
| 22 | 
            +
                    env:
         | 
| 23 | 
            +
                      POSTGRES_USER: postgres
         | 
| 24 | 
            +
                      POSTGRES_PASSWORD: postgres
         | 
| 25 | 
            +
                      POSTGRES_DB: hermes-rb-test
         | 
| 26 | 
            +
                    ports:
         | 
| 27 | 
            +
                      - 5432:5432
         | 
| 28 | 
            +
                    options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
         | 
| 29 | 
            +
                  rabbitmq:
         | 
| 30 | 
            +
                    image: rabbitmq
         | 
| 31 | 
            +
                    env:
         | 
| 32 | 
            +
                      RABBITMQ_DEFAULT_USER: guest
         | 
| 33 | 
            +
                      RABBITMQ_DEFAULT_PASS: guest
         | 
| 34 | 
            +
                    ports:
         | 
| 35 | 
            +
                      - 5672:5672
         | 
| 36 | 
            +
                    options: --health-cmd "rabbitmqctl node_health_check" --health-interval 10s --health-timeout 5s --health-retries 5
         | 
| 37 | 
            +
                steps:
         | 
| 38 | 
            +
                - uses: actions/checkout@v2
         | 
| 39 | 
            +
                - uses: ruby/setup-ruby@v1
         | 
| 40 | 
            +
                  with:
         | 
| 41 | 
            +
                    ruby-version: ${{ matrix.ruby }}
         | 
| 42 | 
            +
                    bundler-cache: true
         | 
| 43 | 
            +
                - run: bundle exec rspec
         | 
    
        data/.gitignore
    CHANGED
    
    
    
        data/.ruby-version
    ADDED
    
    | @@ -0,0 +1 @@ | |
| 1 | 
            +
            2.7
         | 
    
        data/Appraisals
    ADDED
    
    
    
        data/Changelog.md
    CHANGED
    
    
    
        data/Gemfile.lock
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            PATH
         | 
| 2 2 | 
             
              remote: .
         | 
| 3 3 | 
             
              specs:
         | 
| 4 | 
            -
                hermes-rb (0. | 
| 4 | 
            +
                hermes-rb (0.7.0)
         | 
| 5 5 | 
             
                  activerecord (>= 5)
         | 
| 6 6 | 
             
                  activesupport (>= 5)
         | 
| 7 7 | 
             
                  dry-container (~> 0)
         | 
| @@ -12,35 +12,39 @@ PATH | |
| 12 12 | 
             
            GEM
         | 
| 13 13 | 
             
              remote: https://rubygems.org/
         | 
| 14 14 | 
             
              specs:
         | 
| 15 | 
            -
                activemodel ( | 
| 16 | 
            -
                  activesupport (=  | 
| 17 | 
            -
                activerecord ( | 
| 18 | 
            -
                  activemodel (=  | 
| 19 | 
            -
                  activesupport (=  | 
| 20 | 
            -
                activesupport ( | 
| 15 | 
            +
                activemodel (7.0.3)
         | 
| 16 | 
            +
                  activesupport (= 7.0.3)
         | 
| 17 | 
            +
                activerecord (7.0.3)
         | 
| 18 | 
            +
                  activemodel (= 7.0.3)
         | 
| 19 | 
            +
                  activesupport (= 7.0.3)
         | 
| 20 | 
            +
                activesupport (7.0.3)
         | 
| 21 21 | 
             
                  concurrent-ruby (~> 1.0, >= 1.0.2)
         | 
| 22 22 | 
             
                  i18n (>= 1.6, < 2)
         | 
| 23 23 | 
             
                  minitest (>= 5.1)
         | 
| 24 24 | 
             
                  tzinfo (~> 2.0)
         | 
| 25 | 
            -
                  zeitwerk (~> 2.3)
         | 
| 26 25 | 
             
                amq-protocol (2.3.2)
         | 
| 27 | 
            -
                 | 
| 26 | 
            +
                appraisal (2.4.1)
         | 
| 27 | 
            +
                  bundler
         | 
| 28 | 
            +
                  rake
         | 
| 29 | 
            +
                  thor (>= 0.14.0)
         | 
| 30 | 
            +
                bunny (2.19.0)
         | 
| 28 31 | 
             
                  amq-protocol (~> 2.3, >= 2.3.1)
         | 
| 32 | 
            +
                  sorted_set (~> 1, >= 1.0.2)
         | 
| 29 33 | 
             
                carrot-top (0.0.7)
         | 
| 30 34 | 
             
                  json
         | 
| 31 | 
            -
                concurrent-ruby (1.1. | 
| 35 | 
            +
                concurrent-ruby (1.1.10)
         | 
| 32 36 | 
             
                ddtrace (0.45.0)
         | 
| 33 37 | 
             
                  msgpack
         | 
| 34 38 | 
             
                diff-lcs (1.4.4)
         | 
| 35 | 
            -
                dry-configurable (0. | 
| 39 | 
            +
                dry-configurable (0.15.0)
         | 
| 36 40 | 
             
                  concurrent-ruby (~> 1.0)
         | 
| 37 | 
            -
                  dry-core (~> 0. | 
| 38 | 
            -
                dry-container (0. | 
| 41 | 
            +
                  dry-core (~> 0.6)
         | 
| 42 | 
            +
                dry-container (0.9.0)
         | 
| 39 43 | 
             
                  concurrent-ruby (~> 1.0)
         | 
| 40 | 
            -
                  dry-configurable (~> 0. | 
| 41 | 
            -
                dry-core (0. | 
| 44 | 
            +
                  dry-configurable (~> 0.13, >= 0.13.0)
         | 
| 45 | 
            +
                dry-core (0.7.1)
         | 
| 42 46 | 
             
                  concurrent-ruby (~> 1.0)
         | 
| 43 | 
            -
                dry-inflector (0.2. | 
| 47 | 
            +
                dry-inflector (0.2.1)
         | 
| 44 48 | 
             
                dry-logic (1.2.0)
         | 
| 45 49 | 
             
                  concurrent-ruby (~> 1.0)
         | 
| 46 50 | 
             
                  dry-core (~> 0.5, >= 0.5)
         | 
| @@ -54,23 +58,24 @@ GEM | |
| 54 58 | 
             
                  dry-core (~> 0.5, >= 0.5)
         | 
| 55 59 | 
             
                  dry-inflector (~> 0.1, >= 0.1.2)
         | 
| 56 60 | 
             
                  dry-logic (~> 1.0, >= 1.0.2)
         | 
| 57 | 
            -
                hutch (1. | 
| 58 | 
            -
                  activesupport (>= 4.2, <  | 
| 59 | 
            -
                  bunny (>= 2. | 
| 61 | 
            +
                hutch (1.1.1)
         | 
| 62 | 
            +
                  activesupport (>= 4.2, < 8)
         | 
| 63 | 
            +
                  bunny (>= 2.19, < 3.0)
         | 
| 60 64 | 
             
                  carrot-top (~> 0.0.7)
         | 
| 61 | 
            -
                  multi_json (~> 1. | 
| 62 | 
            -
                i18n (1. | 
| 65 | 
            +
                  multi_json (~> 1.15)
         | 
| 66 | 
            +
                i18n (1.10.0)
         | 
| 63 67 | 
             
                  concurrent-ruby (~> 1.0)
         | 
| 64 68 | 
             
                ice_nine (0.11.2)
         | 
| 65 | 
            -
                json (2. | 
| 66 | 
            -
                minitest (5. | 
| 69 | 
            +
                json (2.6.2)
         | 
| 70 | 
            +
                minitest (5.15.0)
         | 
| 67 71 | 
             
                msgpack (1.4.2)
         | 
| 68 72 | 
             
                multi_json (1.15.0)
         | 
| 69 73 | 
             
                newrelic_rpm (6.15.0)
         | 
| 70 74 | 
             
                pg (1.2.3)
         | 
| 71 | 
            -
                rack (2.2.3)
         | 
| 75 | 
            +
                rack (2.2.3.1)
         | 
| 72 76 | 
             
                rake (13.0.1)
         | 
| 73 | 
            -
                 | 
| 77 | 
            +
                rbtree (0.4.5)
         | 
| 78 | 
            +
                request_store (1.5.1)
         | 
| 74 79 | 
             
                  rack (>= 1.4)
         | 
| 75 80 | 
             
                rspec (3.10.0)
         | 
| 76 81 | 
             
                  rspec-core (~> 3.10.0)
         | 
| @@ -85,16 +90,21 @@ GEM | |
| 85 90 | 
             
                  diff-lcs (>= 1.2.0, < 2.0)
         | 
| 86 91 | 
             
                  rspec-support (~> 3.10.0)
         | 
| 87 92 | 
             
                rspec-support (3.10.0)
         | 
| 93 | 
            +
                set (1.0.2)
         | 
| 94 | 
            +
                sorted_set (1.0.3)
         | 
| 95 | 
            +
                  rbtree
         | 
| 96 | 
            +
                  set (~> 1.0)
         | 
| 97 | 
            +
                thor (1.2.1)
         | 
| 88 98 | 
             
                timecop (0.9.2)
         | 
| 89 99 | 
             
                tzinfo (2.0.4)
         | 
| 90 100 | 
             
                  concurrent-ruby (~> 1.0)
         | 
| 91 101 | 
             
                vcr (5.0.0)
         | 
| 92 | 
            -
                zeitwerk (2.4.2)
         | 
| 93 102 |  | 
| 94 103 | 
             
            PLATFORMS
         | 
| 95 104 | 
             
              ruby
         | 
| 96 105 |  | 
| 97 106 | 
             
            DEPENDENCIES
         | 
| 107 | 
            +
              appraisal
         | 
| 98 108 | 
             
              bundler
         | 
| 99 109 | 
             
              ddtrace
         | 
| 100 110 | 
             
              hermes-rb!
         | 
| @@ -106,4 +116,4 @@ DEPENDENCIES | |
| 106 116 | 
             
              vcr
         | 
| 107 117 |  | 
| 108 118 | 
             
            BUNDLED WITH
         | 
| 109 | 
            -
               2. | 
| 119 | 
            +
               2.2.22
         | 
    
        data/hermes-rb.gemspec
    CHANGED
    
    
    
        data/lib/hermes/rb/version.rb
    CHANGED
    
    
| @@ -11,7 +11,13 @@ module Hermes | |
| 11 11 | 
             
                  end
         | 
| 12 12 |  | 
| 13 13 | 
             
                  def handle(message)
         | 
| 14 | 
            -
                    ::Datadog. | 
| 14 | 
            +
                    tracer = ::Datadog.respond_to?(:tracer) ? ::Datadog.tracer : "Datadog::Tracing".safe_constantize
         | 
| 15 | 
            +
             | 
| 16 | 
            +
                    tracer.trace(
         | 
| 17 | 
            +
                      klass.class.name || klass.class.to_s,
         | 
| 18 | 
            +
                      service: "hermes",
         | 
| 19 | 
            +
                      span_type: "rabbitmq"
         | 
| 20 | 
            +
                    ) do
         | 
| 15 21 | 
             
                      klass.process(message)
         | 
| 16 22 | 
             
                    end
         | 
| 17 23 | 
             
                  end
         | 
    
        metadata
    CHANGED
    
    | @@ -1,14 +1,14 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification
         | 
| 2 2 | 
             
            name: hermes-rb
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            -
              version: 0. | 
| 4 | 
            +
              version: 0.7.0
         | 
| 5 5 | 
             
            platform: ruby
         | 
| 6 6 | 
             
            authors:
         | 
| 7 7 | 
             
            - Karol Galanciak
         | 
| 8 8 | 
             
            autorequire:
         | 
| 9 9 | 
             
            bindir: bin
         | 
| 10 10 | 
             
            cert_chain: []
         | 
| 11 | 
            -
            date:  | 
| 11 | 
            +
            date: 2022-05-30 00:00:00.000000000 Z
         | 
| 12 12 | 
             
            dependencies:
         | 
| 13 13 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 14 14 | 
             
              name: dry-struct
         | 
| @@ -206,6 +206,20 @@ dependencies: | |
| 206 206 | 
             
                - - ">="
         | 
| 207 207 | 
             
                  - !ruby/object:Gem::Version
         | 
| 208 208 | 
             
                    version: '0'
         | 
| 209 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 210 | 
            +
              name: appraisal
         | 
| 211 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 212 | 
            +
                requirements:
         | 
| 213 | 
            +
                - - ">="
         | 
| 214 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 215 | 
            +
                    version: '0'
         | 
| 216 | 
            +
              type: :development
         | 
| 217 | 
            +
              prerelease: false
         | 
| 218 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 219 | 
            +
                requirements:
         | 
| 220 | 
            +
                - - ">="
         | 
| 221 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 222 | 
            +
                    version: '0'
         | 
| 209 223 | 
             
            description: A messenger of gods, delivering them via RabbitMQ with a little help
         | 
| 210 224 | 
             
              from Hutch
         | 
| 211 225 | 
             
            email:
         | 
| @@ -215,9 +229,11 @@ executables: | |
| 215 229 | 
             
            extensions: []
         | 
| 216 230 | 
             
            extra_rdoc_files: []
         | 
| 217 231 | 
             
            files:
         | 
| 232 | 
            +
            - ".github/workflows/ci.yml"
         | 
| 218 233 | 
             
            - ".gitignore"
         | 
| 219 234 | 
             
            - ".rspec"
         | 
| 220 | 
            -
            - ". | 
| 235 | 
            +
            - ".ruby-version"
         | 
| 236 | 
            +
            - Appraisals
         | 
| 221 237 | 
             
            - Changelog.md
         | 
| 222 238 | 
             
            - Gemfile
         | 
| 223 239 | 
             
            - Gemfile.lock
         | 
| @@ -227,6 +243,9 @@ files: | |
| 227 243 | 
             
            - bin/console
         | 
| 228 244 | 
             
            - bin/hermes_health_check
         | 
| 229 245 | 
             
            - bin/setup
         | 
| 246 | 
            +
            - gemfiles/rails.5.2.gemfile
         | 
| 247 | 
            +
            - gemfiles/rails.6.1.gemfile
         | 
| 248 | 
            +
            - gemfiles/rails.7.0.gemfile
         | 
| 230 249 | 
             
            - hermes-rb.gemspec
         | 
| 231 250 | 
             
            - lib/hermes-rb.rb
         | 
| 232 251 | 
             
            - lib/hermes.rb
         | 
| @@ -288,7 +307,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement | |
| 288 307 | 
             
                - !ruby/object:Gem::Version
         | 
| 289 308 | 
             
                  version: '0'
         | 
| 290 309 | 
             
            requirements: []
         | 
| 291 | 
            -
            rubygems_version: 3. | 
| 310 | 
            +
            rubygems_version: 3.2.22
         | 
| 292 311 | 
             
            signing_key:
         | 
| 293 312 | 
             
            specification_version: 4
         | 
| 294 313 | 
             
            summary: A messenger of gods, delivering them via RabbitMQ with a little help from
         | 
    
        data/.travis.yml
    DELETED
    
    | @@ -1,17 +0,0 @@ | |
| 1 | 
            -
            ---
         | 
| 2 | 
            -
            language: ruby
         | 
| 3 | 
            -
            cache: bundler
         | 
| 4 | 
            -
            rvm:
         | 
| 5 | 
            -
              - 2.7.2
         | 
| 6 | 
            -
            env:
         | 
| 7 | 
            -
              - HUTCH_URI="amqp://guest:guest@localhost:5672"
         | 
| 8 | 
            -
              - HUTCH_ENABLE_HTTP_API_USE=false
         | 
| 9 | 
            -
            dist: xenial
         | 
| 10 | 
            -
            addons:
         | 
| 11 | 
            -
              apt:
         | 
| 12 | 
            -
                packages:
         | 
| 13 | 
            -
                  - rabbitmq-server
         | 
| 14 | 
            -
            services:
         | 
| 15 | 
            -
              - rabbitmq
         | 
| 16 | 
            -
              - postgresql
         | 
| 17 | 
            -
            before_install: gem install bundler -v 2.1.4
         |