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

span type/subtype alignment #1183

Closed
wants to merge 1 commit into from
Closed

span type/subtype alignment #1183

wants to merge 1 commit into from

Conversation

SylvainJuge
Copy link
Member

@SylvainJuge SylvainJuge commented Nov 2, 2021

What does this pull request do?

Adds changes to shared spec in elastic/apm#513

Checklist

  • remove all references to any deprecated field in spec
  • modify ruby agent implementation to fit the updated spec
  • once merged (or about to be), back-port changes to the shared spec

@apmmachine
Copy link
Contributor

apmmachine commented Nov 2, 2021

💔 Tests Failed

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2022-05-17T05:45:26.116+0000

  • Duration: 123 min 3 sec

Test stats 🧪

Test Results
Failed 169
Passed 38031
Skipped 49
Total 38249

Test errors 169

Expand to view the tests failures

> Show only the first 10 test failures

Tests / Tests / Ruby:docker.elastic.co/observability-ci/jruby:9.2-13-jdk#rails-6.1 / ElasticAPM::Metrics.collect_and_send when no samples calls callback – when no samples
    Expand to view the error details

     failed ElasticAPM::Metrics.collect_and_send when no samples calls callback 
    

    Expand to view the stacktrace

     
            The message expectation for #<ElasticAPM::Metrics::TransactionSet:0x3def5336 @metrics={}, @lock=#<Thread::Mutex:0x3f0cdd5b>, @config=#<ElasticAPM::Config:0x63112b>, @disabled=false>.collect has already been invoked and cannot be modified further (e.g. using `at_least`). All message expectation customizations must be applied before it is used for the first time.
    ["./spec/elastic_apm/metrics_spec.rb:100:in `block in ElasticAPM'", "./spec/elastic_apm/metrics_spec.rb:99:in `block in ElasticAPM'", "/usr/local/bundle/jruby/2.5.0/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block in /usr/local/bundle/jruby/2.5.0/gems/webmock-3.14.0/lib/webmock/rspec.rb'"]
           
    

Tests / Tests / Ruby:ruby:3.0#rails-6.0 / Spy: Elasticsearch spans requests – Spy: Elasticsearch
    Expand to view the error details

     failed Spy: Elasticsearch spans requests 
    

    Expand to view the stacktrace

     
            undefined method `name' for nil:NilClass
    ["./spec/elastic_apm/spies/elasticsearch_spec.rb:61:in `block (2 levels) in <module:ElasticAPM>'", "/usr/local/bundle/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block (2 levels) in <top (required)>'"]
           
    

Tests / Tests / Ruby:ruby:3.0#rails-6.0 / Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is true uses the body in the statement – when capture_elasticsearch_queries is true
    Expand to view the error details

     failed Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is true uses the body in the statement 
    

    Expand to view the stacktrace

     
            undefined method `name' for nil:NilClass
    ["./spec/elastic_apm/spies/elasticsearch_spec.rb:96:in `block (4 levels) in <module:ElasticAPM>'", "/usr/local/bundle/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block (2 levels) in <top (required)>'"]
           
    

Tests / Tests / Ruby:ruby:3.0#rails-6.0 / Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is true filters sensitive information – when capture_elasticsearch_queries is true
    Expand to view the error details

     failed Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is true filters sensitive information 
    

    Expand to view the stacktrace

     
            undefined method `context' for nil:NilClass
    ["./spec/elastic_apm/spies/elasticsearch_spec.rb:123:in `block (4 levels) in <module:ElasticAPM>'", "/usr/local/bundle/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block (2 levels) in <top (required)>'"]
           
    

Tests / Tests / Ruby:ruby:3.0#rails-6.0 / Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is false does not use the body in the statement – when capture_elasticsearch_queries is false
    Expand to view the error details

     failed Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is false does not use the body in the statement 
    

    Expand to view the stacktrace

     
            undefined method `name' for nil:NilClass
    ["./spec/elastic_apm/spies/elasticsearch_spec.rb:147:in `block (4 levels) in <module:ElasticAPM>'", "/usr/local/bundle/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block (2 levels) in <top (required)>'"]
           
    

Tests / Tests / Ruby:ruby:2.6#sinatra-1.4 / Spy: Elasticsearch spans requests – Spy: Elasticsearch
    Expand to view the error details

     failed Spy: Elasticsearch spans requests 
    

    Expand to view the stacktrace

     
            undefined method `name' for nil:NilClass
    ["./spec/elastic_apm/spies/elasticsearch_spec.rb:61:in `block (2 levels) in <module:ElasticAPM>'", "/usr/local/bundle/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block (2 levels) in <top (required)>'"]
           
    

Tests / Tests / Ruby:ruby:2.6#sinatra-1.4 / Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is true uses the body in the statement – when capture_elasticsearch_queries is true
    Expand to view the error details

     failed Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is true uses the body in the statement 
    

    Expand to view the stacktrace

     
            undefined method `name' for nil:NilClass
    ["./spec/elastic_apm/spies/elasticsearch_spec.rb:96:in `block (4 levels) in <module:ElasticAPM>'", "/usr/local/bundle/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block (2 levels) in <top (required)>'"]
           
    

Tests / Tests / Ruby:ruby:2.6#sinatra-1.4 / Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is true filters sensitive information – when capture_elasticsearch_queries is true
    Expand to view the error details

     failed Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is true filters sensitive information 
    

    Expand to view the stacktrace

     
            undefined method `context' for nil:NilClass
    ["./spec/elastic_apm/spies/elasticsearch_spec.rb:123:in `block (4 levels) in <module:ElasticAPM>'", "/usr/local/bundle/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block (2 levels) in <top (required)>'"]
           
    

Tests / Tests / Ruby:ruby:2.6#sinatra-1.4 / Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is false does not use the body in the statement – when capture_elasticsearch_queries is false
    Expand to view the error details

     failed Spy: Elasticsearch a post request with body when capture_elasticsearch_queries is false does not use the body in the statement 
    

    Expand to view the stacktrace

     
            undefined method `name' for nil:NilClass
    ["./spec/elastic_apm/spies/elasticsearch_spec.rb:147:in `block (4 levels) in <module:ElasticAPM>'", "/usr/local/bundle/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block (2 levels) in <top (required)>'"]
           
    

Tests / Tests / Ruby:ruby:2.7#grape-1.5,sinatra-2.0,rails-6.1 / Spy: Elasticsearch spans requests – Spy: Elasticsearch
    Expand to view the error details

     failed Spy: Elasticsearch spans requests 
    

    Expand to view the stacktrace

     
            undefined method `name' for nil:NilClass
    ["./spec/elastic_apm/spies/elasticsearch_spec.rb:61:in `block (2 levels) in <module:ElasticAPM>'", "/usr/local/bundle/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block (2 levels) in <top (required)>'"]
           
    

Steps errors 87

Expand to view the steps failures

Show only the first 10 steps failures

Shell Script
  • Took 2 min 28 sec . View more details here
  • Description: ./spec/scripts/spec.sh docker.elastic.co/observability-ci/jruby:9.2-8-jdk rails-6.1
Shell Script
  • Took 2 min 13 sec . View more details here
  • Description: ./spec/scripts/spec.sh docker.elastic.co/observability-ci/jruby:9.2-8-jdk rails-6.0
Shell Script
  • Took 2 min 15 sec . View more details here
  • Description: ./spec/scripts/spec.sh docker.elastic.co/observability-ci/jruby:9.2-8-jdk rails-6.0
Shell Script
  • Took 2 min 23 sec . View more details here
  • Description: ./spec/scripts/spec.sh docker.elastic.co/observability-ci/jruby:9.2-8-jdk rails-5.2
Shell Script
  • Took 2 min 23 sec . View more details here
  • Description: ./spec/scripts/spec.sh docker.elastic.co/observability-ci/jruby:9.2-8-jdk rails-5.2
Shell Script
  • Took 2 min 8 sec . View more details here
  • Description: ./spec/scripts/spec.sh docker.elastic.co/observability-ci/jruby:9.2-8-jdk sinatra-2.0
Shell Script
  • Took 2 min 12 sec . View more details here
  • Description: ./spec/scripts/spec.sh docker.elastic.co/observability-ci/jruby:9.2-8-jdk sinatra-2.0
Restore files previously stashed
  • Took 0 min 0 sec . View more details here
  • Description: jruby-9.2-8-jdk-grape-1.5
Read yaml from files in the workspace or text.
  • Took 0 min 0 sec . View more details here
  • Description: .ci/.jenkins_main_framework.yml
Error signal
  • Took 0 min 0 sec . View more details here
  • Description: Ruby:ruby:3.0#rails-6.1 tests failed : hudson.AbortException: script returned exit code 1

🤖 GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

  • run benchmark tests : Run the benchmark test.

  • run elasticsearch-ci/docs : Re-trigger the docs validation. (use unformatted text in the comment!)

@SylvainJuge
Copy link
Member Author

/test

@jaggederest
Copy link
Contributor

Hi @SylvainJuge does this need attention from me? Just going through the open PRs, I know this is a draft so if it's not moving forward can we close it? Happy to take over if you prefer that as well.

@SylvainJuge
Copy link
Member Author

Hi @jaggederest , thanks for cleaning-up old PRs, this was my attempt to modify the specification for the ruby agent regarding span type/subtype alignment.

From what I remember, the ruby agent does enforce the span types & subtypes from the shared spec in https://github.com/elastic/apm/blob/main/tests/agents/json-specs/span_types.json.

So here, the next steps here are:

While not being "strictly urgent", providing alignment here helps for quite other features that indirectly use span type and subtype for resource destination, compressed spans, destination metrics, ... On the other end, it is a "potentially breaking change" as any user relying on the current values would be impacted (quite minimal, but worth being aware of).

@jaggederest
Copy link
Contributor

Great, I'll work on that then 👍

@jaggederest jaggederest self-assigned this May 18, 2022
@SylvainJuge
Copy link
Member Author

Closing this PR as it has become stale, we'll likely revisit the topic in the context of OTel.

@SylvainJuge SylvainJuge deleted the apm-513 branch November 27, 2023 09:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants