instana 1.193.4 → 1.193.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +7 -0
- data/Appraisals +3 -0
- data/Gemfile +3 -0
- data/LICENSE +2 -1
- data/Rakefile +3 -0
- data/benchmarks/10k-rack-traces.rb +3 -0
- data/benchmarks/Gemfile +4 -0
- data/benchmarks/id_generation.rb +4 -0
- data/benchmarks/opentracing.rb +4 -0
- data/benchmarks/rack_vanilla_vs_traced.rb +3 -0
- data/benchmarks/stackprof_rack_tracing.rb +3 -0
- data/benchmarks/time_processing.rb +4 -0
- data/bin/console +3 -0
- data/examples/opentracing.rb +4 -0
- data/examples/tracing.rb +4 -0
- data/extras/license_header.rb +44 -0
- data/gemfiles/cuba_30.gemfile +3 -0
- data/gemfiles/dalli_20.gemfile +3 -0
- data/gemfiles/excon_02.gemfile +3 -0
- data/gemfiles/graphql_10.gemfile +3 -0
- data/gemfiles/grpc_10.gemfile +3 -0
- data/gemfiles/net_http_01.gemfile +3 -0
- data/gemfiles/rack_16.gemfile +3 -0
- data/gemfiles/rack_20.gemfile +3 -0
- data/gemfiles/rails_42.gemfile +3 -0
- data/gemfiles/rails_50.gemfile +3 -0
- data/gemfiles/rails_52.gemfile +3 -0
- data/gemfiles/rails_60.gemfile +3 -0
- data/gemfiles/redis_40.gemfile +3 -0
- data/gemfiles/resque_122.gemfile +3 -0
- data/gemfiles/resque_20.gemfile +3 -0
- data/gemfiles/rest_client_16.gemfile +3 -0
- data/gemfiles/rest_client_20.gemfile +3 -0
- data/gemfiles/roda_20.gemfile +3 -0
- data/gemfiles/roda_30.gemfile +3 -0
- data/gemfiles/sidekiq_42.gemfile +3 -0
- data/gemfiles/sidekiq_50.gemfile +3 -0
- data/gemfiles/sinatra_14.gemfile +3 -0
- data/instana.gemspec +4 -0
- data/lib/instana.rb +3 -0
- data/lib/instana/activator.rb +3 -0
- data/lib/instana/activators/action_cable.rb +24 -0
- data/lib/instana/activators/action_controller_api.rb +3 -0
- data/lib/instana/activators/action_controller_base.rb +3 -0
- data/lib/instana/activators/action_view.rb +3 -0
- data/lib/instana/activators/active_record.rb +3 -0
- data/lib/instana/activators/cuba.rb +3 -0
- data/lib/instana/activators/dalli.rb +3 -0
- data/lib/instana/activators/excon.rb +3 -0
- data/lib/instana/activators/graphql.rb +3 -0
- data/lib/instana/activators/grpc_client.rb +3 -0
- data/lib/instana/activators/grpc_server.rb +3 -0
- data/lib/instana/activators/net_http.rb +3 -0
- data/lib/instana/activators/rack.rb +3 -0
- data/lib/instana/activators/rails.rb +3 -0
- data/lib/instana/activators/redis.rb +3 -0
- data/lib/instana/activators/resque_client.rb +3 -0
- data/lib/instana/activators/resque_worker.rb +3 -0
- data/lib/instana/activators/rest_client.rb +3 -0
- data/lib/instana/activators/roda.rb +3 -0
- data/lib/instana/activators/sidekiq_client.rb +3 -0
- data/lib/instana/activators/sidekiq_worker.rb +3 -0
- data/lib/instana/activators/sinatra.rb +3 -0
- data/lib/instana/agent.rb +3 -0
- data/lib/instana/agent/helpers.rb +3 -0
- data/lib/instana/agent/hooks.rb +3 -0
- data/lib/instana/agent/tasks.rb +3 -0
- data/lib/instana/base.rb +3 -0
- data/lib/instana/collector.rb +3 -0
- data/lib/instana/collectors/gc.rb +3 -0
- data/lib/instana/collectors/memory.rb +3 -0
- data/lib/instana/collectors/thread.rb +3 -0
- data/lib/instana/config.rb +3 -0
- data/lib/instana/frameworks/cuba.rb +3 -0
- data/lib/instana/frameworks/rails.rb +3 -0
- data/lib/instana/frameworks/roda.rb +3 -0
- data/lib/instana/frameworks/sinatra.rb +3 -0
- data/lib/instana/helpers.rb +3 -0
- data/lib/instana/instrumentation/action_cable.rb +53 -0
- data/lib/instana/instrumentation/action_controller.rb +3 -0
- data/lib/instana/instrumentation/action_view.rb +3 -0
- data/lib/instana/instrumentation/active_record.rb +3 -0
- data/lib/instana/instrumentation/dalli.rb +3 -0
- data/lib/instana/instrumentation/excon.rb +3 -0
- data/lib/instana/instrumentation/graphql.rb +3 -0
- data/lib/instana/instrumentation/grpc.rb +3 -0
- data/lib/instana/instrumentation/instrumented_request.rb +4 -0
- data/lib/instana/instrumentation/net-http.rb +3 -0
- data/lib/instana/instrumentation/rack.rb +3 -0
- data/lib/instana/instrumentation/redis.rb +3 -0
- data/lib/instana/instrumentation/resque.rb +3 -0
- data/lib/instana/instrumentation/rest-client.rb +3 -0
- data/lib/instana/instrumentation/sidekiq-client.rb +3 -0
- data/lib/instana/instrumentation/sidekiq-worker.rb +3 -0
- data/lib/instana/opentracing/carrier.rb +3 -0
- data/lib/instana/opentracing/tracer.rb +3 -0
- data/lib/instana/rack.rb +4 -0
- data/lib/instana/secrets.rb +3 -0
- data/lib/instana/setup.rb +3 -0
- data/lib/instana/thread_local.rb +3 -0
- data/lib/instana/tracer.rb +3 -0
- data/lib/instana/tracing/processor.rb +3 -0
- data/lib/instana/tracing/span.rb +3 -0
- data/lib/instana/tracing/span_context.rb +3 -0
- data/lib/instana/util.rb +3 -0
- data/lib/instana/version.rb +4 -1
- data/lib/oj_check.rb +3 -0
- data/lib/opentracing.rb +3 -0
- data/test/activator_test.rb +3 -0
- data/test/agent/agent_test.rb +3 -0
- data/test/benchmarks/bench_id_generation.rb +3 -0
- data/test/benchmarks/bench_opentracing.rb +3 -0
- data/test/config_test.rb +3 -0
- data/test/frameworks/cuba_test.rb +3 -0
- data/test/frameworks/roda_test.rb +4 -0
- data/test/frameworks/sinatra_test.rb +3 -0
- data/test/instana_test.rb +3 -0
- data/test/instrumentation/dalli_test.rb +3 -0
- data/test/instrumentation/excon_test.rb +3 -0
- data/test/instrumentation/graphql_test.rb +3 -0
- data/test/instrumentation/grpc_test.rb +3 -0
- data/test/instrumentation/net_http_test.rb +3 -0
- data/test/instrumentation/rack_instrumented_request_test.rb +3 -0
- data/test/instrumentation/rack_test.rb +3 -0
- data/test/instrumentation/rails_action_cable_test.rb +131 -0
- data/test/instrumentation/rails_action_controller_test.rb +3 -0
- data/test/instrumentation/rails_action_view_test.rb +3 -0
- data/test/instrumentation/rails_active_record_test.rb +3 -2
- data/test/instrumentation/redis_test.rb +3 -0
- data/test/instrumentation/resque_test.rb +3 -0
- data/test/instrumentation/rest_client_test.rb +3 -0
- data/test/instrumentation/sidekiq-client_test.rb +3 -0
- data/test/instrumentation/sidekiq-worker_test.rb +3 -0
- data/test/secrets_test.rb +3 -0
- data/test/support/apps/active_record/active_record.rb +3 -0
- data/test/support/apps/grpc/boot.rb +3 -0
- data/test/support/apps/grpc/grpc_server.rb +3 -0
- data/test/support/apps/http_endpoint/boot.rb +3 -0
- data/test/support/apps/rails/boot.rb +3 -0
- data/test/support/apps/rails/models/block.rb +3 -0
- data/test/support/apps/rails/models/block6.rb +3 -0
- data/test/support/apps/resque/boot.rb +3 -0
- data/test/support/apps/resque/jobs/resque_error_job.rb +3 -0
- data/test/support/apps/resque/jobs/resque_fast_job.rb +3 -0
- data/test/support/apps/sidekiq/boot.rb +4 -0
- data/test/support/apps/sidekiq/jobs/sidekiq_job_1.rb +3 -0
- data/test/support/apps/sidekiq/jobs/sidekiq_job_2.rb +3 -0
- data/test/support/apps/sidekiq/worker.rb +3 -0
- data/test/support/helpers.rb +3 -0
- data/test/test_helper.rb +3 -0
- data/test/tracing/custom_test.rb +3 -0
- data/test/tracing/id_management_test.rb +4 -0
- data/test/tracing/opentracing_test.rb +3 -0
- data/test/tracing/tracer_async_test.rb +3 -0
- data/test/tracing/tracer_test.rb +3 -0
- metadata +7 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3a4bd641fb11b956073bc9d424e61e1425382ed0bd3e92fcb1c00223e07f8202
|
4
|
+
data.tar.gz: 8f8627a078613dd16adcf67a37f5eacf163c21a34b3d6172f05f831d833720f0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 488afe1762be438b3d02ccc89a1616ce8a8600047dd9e7f5fdb988474d335d494a44a40fb3f1e4c24cb804dde777e6246adbc6b737eeab2317525cee4de90f33
|
7
|
+
data.tar.gz: 5af49960b8f13c6fdd2a6f3b7e961da14632820e2b323853f53af2be45f3655aa36b07224ae9734cbd4ca505bd136c8e1b5da6e115b9019031667ea9cd708c9b
|
data/.rubocop.yml
CHANGED
data/Appraisals
CHANGED
data/Gemfile
CHANGED
data/LICENSE
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
MIT License
|
2
2
|
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) Copyright IBM Corp. 2021
|
4
|
+
Copyright (c) 2017 Instana, Inc. https://www.instana.com/
|
4
5
|
|
5
6
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
7
|
of this software and associated documentation files (the "Software"), to deal
|
data/Rakefile
CHANGED
data/benchmarks/Gemfile
CHANGED
data/benchmarks/id_generation.rb
CHANGED
data/benchmarks/opentracing.rb
CHANGED
data/bin/console
CHANGED
data/examples/opentracing.rb
CHANGED
@@ -4,6 +4,10 @@
|
|
4
4
|
# to `OpenTracing.global_tracer`. Once the gem is loaded, you can
|
5
5
|
# immediately start making OpenTracing calls.
|
6
6
|
#
|
7
|
+
|
8
|
+
# (c) Copyright IBM Corp. 2021
|
9
|
+
# (c) Copyright Instana Inc. 2018
|
10
|
+
|
7
11
|
require "opentracing"
|
8
12
|
|
9
13
|
entry_span = OpenTracing.start_span("HandMadeRackServer")
|
data/examples/tracing.rb
CHANGED
@@ -17,6 +17,10 @@
|
|
17
17
|
# points in webservers (e.g. rack), it will initialize tracing and instrument the passed
|
18
18
|
# block. <incoming_id> is a hash for continuing remote traces (remote in terms
|
19
19
|
# of service calls, or message queues).
|
20
|
+
|
21
|
+
# (c) Copyright IBM Corp. 2021
|
22
|
+
# (c) Copyright Instana Inc. 2016
|
23
|
+
|
20
24
|
Instana::Tracer.start_or_continue_trace(:my_block_name, {}, incoming_context) do
|
21
25
|
# Code block
|
22
26
|
end
|
@@ -0,0 +1,44 @@
|
|
1
|
+
# (c) Copyright IBM Corp. 2021
|
2
|
+
# (c) Copyright Instana Inc. 2021
|
3
|
+
|
4
|
+
require 'time'
|
5
|
+
|
6
|
+
module RuboCop
|
7
|
+
module Cop
|
8
|
+
module Instana
|
9
|
+
# Ensures the license header is present in each ruby file
|
10
|
+
class LicenseHeader < Base
|
11
|
+
extend AutoCorrector
|
12
|
+
|
13
|
+
MSG = 'The license header should be present in each file.'.freeze
|
14
|
+
HEADER = '(c) Copyright IBM Corp.'.freeze
|
15
|
+
HEADER_TEMPLATE = <<~HERE.freeze
|
16
|
+
# (c) Copyright IBM Corp. %d
|
17
|
+
# (c) Copyright Instana Inc. %d
|
18
|
+
HERE
|
19
|
+
|
20
|
+
def on_new_investigation
|
21
|
+
first_statement = processed_source.tokens.detect { |t| t.type != :tCOMMENT }
|
22
|
+
file_name = first_statement.pos.source_buffer.name
|
23
|
+
header_comment = processed_source.comments.detect do |comment|
|
24
|
+
first_statement_line = first_statement.pos.line
|
25
|
+
comment_line = comment.loc.line
|
26
|
+
|
27
|
+
(comment_line < first_statement_line) && comment.text.include?(HEADER)
|
28
|
+
end
|
29
|
+
|
30
|
+
return if header_comment
|
31
|
+
|
32
|
+
add_offense(first_statement.pos) do |corrector|
|
33
|
+
current_year = Time.now.year
|
34
|
+
created_time = `git log --diff-filter=A --follow --format=%aD -1 -- #{file_name}`
|
35
|
+
created_year = created_time.empty? ? current_year : Time.parse(created_time).year
|
36
|
+
|
37
|
+
header_text = format(HEADER_TEMPLATE, current_year, created_year)
|
38
|
+
corrector.insert_before(first_statement.pos, "\n#{header_text}\n")
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
43
|
+
end
|
44
|
+
end
|
data/gemfiles/cuba_30.gemfile
CHANGED
data/gemfiles/dalli_20.gemfile
CHANGED
data/gemfiles/excon_02.gemfile
CHANGED
data/gemfiles/graphql_10.gemfile
CHANGED
data/gemfiles/grpc_10.gemfile
CHANGED
data/gemfiles/rack_16.gemfile
CHANGED
data/gemfiles/rack_20.gemfile
CHANGED
data/gemfiles/rails_42.gemfile
CHANGED
data/gemfiles/rails_50.gemfile
CHANGED
data/gemfiles/rails_52.gemfile
CHANGED
data/gemfiles/rails_60.gemfile
CHANGED
data/gemfiles/redis_40.gemfile
CHANGED
data/gemfiles/resque_122.gemfile
CHANGED
data/gemfiles/resque_20.gemfile
CHANGED
data/gemfiles/roda_20.gemfile
CHANGED
data/gemfiles/roda_30.gemfile
CHANGED
data/gemfiles/sidekiq_42.gemfile
CHANGED
data/gemfiles/sidekiq_50.gemfile
CHANGED
data/gemfiles/sinatra_14.gemfile
CHANGED
data/instana.gemspec
CHANGED