datadog-ci 0.1.1 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (81) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +29 -1
  3. data/LICENSE-3rdparty.csv +1 -0
  4. data/README.md +64 -0
  5. data/lib/datadog/ci/configuration/components.rb +72 -5
  6. data/lib/datadog/ci/configuration/settings.rb +36 -8
  7. data/lib/datadog/ci/contrib/cucumber/configuration/settings.rb +2 -3
  8. data/lib/datadog/ci/contrib/cucumber/formatter.rb +8 -10
  9. data/lib/datadog/ci/contrib/cucumber/integration.rb +3 -5
  10. data/lib/datadog/ci/contrib/integration.rb +149 -0
  11. data/lib/datadog/ci/contrib/minitest/configuration/settings.rb +2 -3
  12. data/lib/datadog/ci/contrib/minitest/hooks.rb +8 -4
  13. data/lib/datadog/ci/contrib/minitest/integration.rb +3 -5
  14. data/lib/datadog/ci/contrib/rspec/configuration/settings.rb +2 -3
  15. data/lib/datadog/ci/contrib/rspec/example.rb +5 -8
  16. data/lib/datadog/ci/contrib/rspec/integration.rb +3 -5
  17. data/lib/datadog/ci/contrib/settings.rb +33 -0
  18. data/lib/datadog/ci/ext/environment/providers/appveyor.rb +4 -0
  19. data/lib/datadog/ci/ext/environment/providers/aws_code_pipeline.rb +39 -0
  20. data/lib/datadog/ci/ext/environment/providers/azure.rb +4 -0
  21. data/lib/datadog/ci/ext/environment/providers/base.rb +4 -0
  22. data/lib/datadog/ci/ext/environment/providers/bitbucket.rb +4 -0
  23. data/lib/datadog/ci/ext/environment/providers/bitrise.rb +4 -0
  24. data/lib/datadog/ci/ext/environment/providers/buddy.rb +4 -0
  25. data/lib/datadog/ci/ext/environment/providers/buildkite.rb +4 -0
  26. data/lib/datadog/ci/ext/environment/providers/circleci.rb +4 -0
  27. data/lib/datadog/ci/ext/environment/providers/codefresh.rb +4 -0
  28. data/lib/datadog/ci/ext/environment/providers/github_actions.rb +4 -0
  29. data/lib/datadog/ci/ext/environment/providers/gitlab.rb +4 -0
  30. data/lib/datadog/ci/ext/environment/providers/jenkins.rb +4 -0
  31. data/lib/datadog/ci/ext/environment/providers/local_git.rb +7 -0
  32. data/lib/datadog/ci/ext/environment/providers/teamcity.rb +4 -0
  33. data/lib/datadog/ci/ext/environment/providers/travis.rb +4 -0
  34. data/lib/datadog/ci/ext/environment/providers.rb +16 -14
  35. data/lib/datadog/ci/ext/settings.rb +2 -0
  36. data/lib/datadog/ci/ext/transport.rb +24 -0
  37. data/lib/datadog/ci/{test.rb → recorder.rb} +6 -5
  38. data/lib/datadog/ci/test_visibility/flush.rb +40 -0
  39. data/lib/datadog/ci/test_visibility/serializers/base.rb +161 -0
  40. data/lib/datadog/ci/test_visibility/serializers/factories/test_level.rb +30 -0
  41. data/lib/datadog/ci/test_visibility/serializers/span.rb +51 -0
  42. data/lib/datadog/ci/test_visibility/serializers/test_v1.rb +60 -0
  43. data/lib/datadog/ci/test_visibility/transport.rb +151 -0
  44. data/lib/datadog/ci/transport/api/base.rb +36 -0
  45. data/lib/datadog/ci/transport/api/builder.rb +46 -0
  46. data/lib/datadog/ci/transport/api/ci_test_cycle.rb +30 -0
  47. data/lib/datadog/ci/transport/api/evp_proxy.rb +44 -0
  48. data/lib/datadog/ci/transport/gzip.rb +22 -0
  49. data/lib/datadog/ci/transport/http.rb +77 -0
  50. data/lib/datadog/ci/version.rb +2 -2
  51. data/sig/datadog/ci/configuration/components.rbs +4 -0
  52. data/sig/datadog/ci/configuration/settings.rbs +2 -0
  53. data/sig/datadog/ci/contrib/cucumber/configuration/settings.rbs +1 -1
  54. data/sig/datadog/ci/contrib/cucumber/integration.rbs +2 -1
  55. data/sig/datadog/ci/contrib/integration.rbs +44 -0
  56. data/sig/datadog/ci/contrib/minitest/configuration/settings.rbs +1 -1
  57. data/sig/datadog/ci/contrib/minitest/integration.rbs +4 -3
  58. data/sig/datadog/ci/contrib/rspec/configuration/settings.rbs +1 -1
  59. data/sig/datadog/ci/contrib/rspec/integration.rbs +3 -2
  60. data/sig/datadog/ci/contrib/settings.rbs +25 -0
  61. data/sig/datadog/ci/ext/environment/providers/aws_code_pipeline.rbs +19 -0
  62. data/sig/datadog/ci/ext/environment/providers/base.rbs +2 -0
  63. data/sig/datadog/ci/ext/environment/providers.rbs +1 -1
  64. data/sig/datadog/ci/ext/settings.rbs +2 -0
  65. data/sig/datadog/ci/ext/transport.rbs +29 -0
  66. data/sig/datadog/ci/{test.rbs → recorder.rbs} +1 -1
  67. data/sig/datadog/ci/test_visibility/flush.rbs +17 -0
  68. data/sig/datadog/ci/test_visibility/serializers/base.rbs +73 -0
  69. data/sig/datadog/ci/test_visibility/serializers/factories/test_level.rbs +13 -0
  70. data/sig/datadog/ci/test_visibility/serializers/span.rbs +18 -0
  71. data/sig/datadog/ci/test_visibility/serializers/test_v1.rbs +23 -0
  72. data/sig/datadog/ci/test_visibility/transport.rbs +35 -0
  73. data/sig/datadog/ci/transport/api/base.rbs +21 -0
  74. data/sig/datadog/ci/transport/api/builder.rbs +12 -0
  75. data/sig/datadog/ci/transport/api/ci_test_cycle.rbs +21 -0
  76. data/sig/datadog/ci/transport/api/evp_proxy.rbs +19 -0
  77. data/sig/datadog/ci/transport/gzip.rbs +9 -0
  78. data/sig/datadog/ci/transport/http.rbs +36 -0
  79. metadata +52 -8
  80. data/lib/datadog/ci/flush.rb +0 -38
  81. data/sig/datadog/ci/flush.rbs +0 -15
@@ -0,0 +1,25 @@
1
+ module Datadog
2
+ module CI
3
+ module Contrib
4
+ class Settings
5
+ include Core::Configuration::Base
6
+ extend Datadog::Core::Configuration::Options::ClassMethods
7
+ include Datadog::Core::Configuration::Options::InstanceMethods
8
+
9
+ extend Datadog::Core::Configuration::Base::ClassMethods
10
+
11
+ def configure: (?::Hash[Symbol, untyped] options) ?{ (Datadog::CI::Contrib::Settings) -> Datadog::CI::Contrib::Settings } -> Datadog::CI::Contrib::Settings?
12
+
13
+ def []: (Symbol name) -> Datadog::CI::Contrib::Settings
14
+
15
+ def []=: (untyped name, untyped value) -> untyped
16
+
17
+ # default configuration options
18
+ #
19
+ def enabled: () -> bool
20
+ def service_name: () -> String
21
+ def operation_name: () -> String
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,19 @@
1
+ module Datadog
2
+ module CI
3
+ module Ext
4
+ module Environment
5
+ module Providers
6
+ class AwsCodePipeline < Base
7
+ def self.handles?: (Hash[String, String?] env) -> bool
8
+
9
+ def provider_name: () -> "awscodepipeline"
10
+
11
+ def pipeline_id: () -> String?
12
+
13
+ def ci_env_vars: () -> String?
14
+ end
15
+ end
16
+ end
17
+ end
18
+ end
19
+ end
@@ -8,6 +8,8 @@ module Datadog
8
8
  @branch: String?
9
9
  @tag: String?
10
10
 
11
+ def self.handles?: (Hash[String, String?] env) -> bool
12
+
11
13
  def initialize: (Hash[String, String?] env) -> void
12
14
 
13
15
  def job_name: () -> nil
@@ -3,7 +3,7 @@ module Datadog
3
3
  module Ext
4
4
  module Environment
5
5
  module Providers
6
- PROVIDERS: ::Array[[String, untyped]]
6
+ PROVIDERS: ::Array[untyped]
7
7
 
8
8
  def self.for_environment: (Hash[String, String?] env) -> Providers::Base
9
9
  end
@@ -3,6 +3,8 @@ module Datadog
3
3
  module Ext
4
4
  module Settings
5
5
  ENV_MODE_ENABLED: String
6
+ ENV_AGENTLESS_MODE_ENABLED: String
7
+ ENV_AGENTLESS_URL: String
6
8
  end
7
9
  end
8
10
  end
@@ -0,0 +1,29 @@
1
+ module Datadog
2
+ module CI
3
+ module Ext
4
+ module Transport
5
+ DEFAULT_DD_SITE: "datadoghq.com"
6
+
7
+ HEADER_DD_API_KEY: "DD-API-KEY"
8
+
9
+ HEADER_CONTENT_TYPE: "Content-Type"
10
+
11
+ HEADER_CONTENT_ENCODING: "Content-Encoding"
12
+
13
+ HEADER_EVP_SUBDOMAIN: "X-Datadog-EVP-Subdomain"
14
+
15
+ HEADER_CONTAINER_ID: "Datadog-Container-ID"
16
+
17
+ EVP_PROXY_PATH_PREFIX: "/evp_proxy/v2/"
18
+
19
+ TEST_VISIBILITY_INTAKE_HOST_PREFIX: "citestcycle-intake"
20
+
21
+ TEST_VISIBILITY_INTAKE_PATH: "/api/v2/citestcycle"
22
+
23
+ CONTENT_TYPE_MESSAGEPACK: "application/msgpack"
24
+
25
+ CONTENT_ENCODING_GZIP: "gzip"
26
+ end
27
+ end
28
+ end
29
+ end
@@ -1,6 +1,6 @@
1
1
  module Datadog
2
2
  module CI
3
- module Test
3
+ module Recorder
4
4
  self.@environment_tags: Hash[String, String]
5
5
 
6
6
  def self.trace: (untyped span_name, ?::Hash[untyped, untyped] options) ?{ (untyped, untyped) -> untyped } -> untyped
@@ -0,0 +1,17 @@
1
+ module Datadog
2
+ module CI
3
+ module TestVisibility
4
+ module Flush
5
+ module Tagging
6
+ def get_trace: (Datadog::Tracing::TraceOperation trace_op) -> untyped
7
+ end
8
+ class Finished < Tracing::Flush::Finished
9
+ prepend Tagging
10
+ end
11
+ class Partial < Tracing::Flush::Partial
12
+ prepend Tagging
13
+ end
14
+ end
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,73 @@
1
+ module Datadog
2
+ module CI
3
+ module TestVisibility
4
+ module Serializers
5
+ class Base
6
+ MINIMUM_TIMESTAMP_NANO: 946684800000000000
7
+ MINIMUM_DURATION_NANO: 0
8
+ MAXIMUM_DURATION_NANO: 9223372036854775807
9
+
10
+ @content_fields_count: Integer
11
+ @start: Integer
12
+ @duration: Integer
13
+
14
+ attr_reader trace: Datadog::Tracing::TraceSegment
15
+ attr_reader span: Datadog::Tracing::Span
16
+
17
+ def initialize: (Datadog::Tracing::TraceSegment trace, Datadog::Tracing::Span span) -> void
18
+
19
+ def to_msgpack: (?untyped? packer) -> untyped
20
+
21
+ def valid?: () -> bool
22
+ def content_fields: () -> ::Array[String | Hash[String, String]]
23
+ def content_map_size: () -> Integer
24
+
25
+ def runtime_id: () -> String
26
+
27
+ def trace_id: () -> String
28
+
29
+ def span_id: () -> String
30
+
31
+ def parent_id: () -> String
32
+
33
+ def type: () -> nil
34
+
35
+ def version: () -> 1
36
+
37
+ def span_type: () -> String
38
+
39
+ def name: () -> String
40
+
41
+ def resource: () -> String
42
+
43
+ def service: () -> String
44
+
45
+ def start: () -> Integer
46
+
47
+ def duration: () -> Integer
48
+
49
+ def meta: () -> Hash[String, untyped]
50
+
51
+ def metrics: () -> Hash[String, untyped]
52
+
53
+ def error: () -> Integer
54
+
55
+ def self.calculate_content_map_size: (Array[String | Hash[String, String]] fields_list) -> Integer
56
+
57
+ private
58
+
59
+ def valid_start_time?: () -> bool
60
+ def valid_duration?: () -> bool
61
+ def required_fields_present?: () -> bool
62
+ def required_fields: () -> Array[String]
63
+
64
+ def write_field: (untyped packer, String field_name, ?String? method) -> untyped
65
+ def time_nano: (Time time) -> Integer
66
+ def duration_nano: (Float duration) -> Integer
67
+
68
+ def content_fields_count: () -> Integer
69
+ end
70
+ end
71
+ end
72
+ end
73
+ end
@@ -0,0 +1,13 @@
1
+ module Datadog
2
+ module CI
3
+ module TestVisibility
4
+ module Serializers
5
+ module Factories
6
+ module TestLevel
7
+ def self?.serializer: (Datadog::Tracing::TraceSegment trace, Datadog::Tracing::Span span) -> Datadog::CI::TestVisibility::Serializers::Base
8
+ end
9
+ end
10
+ end
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,18 @@
1
+ module Datadog
2
+ module CI
3
+ module TestVisibility
4
+ module Serializers
5
+ class Span < Base
6
+ CONTENT_FIELDS: Array[String | Hash[String, String]]
7
+ CONTENT_MAP_SIZE: Integer
8
+ REQUIRED_FIELDS: Array[String]
9
+
10
+ def required_fields: () -> Array[String]
11
+ def content_fields: () -> Array[String | Hash[String, String]]
12
+ def content_map_size: () -> Integer
13
+ def type: () -> "span"
14
+ end
15
+ end
16
+ end
17
+ end
18
+ end
@@ -0,0 +1,23 @@
1
+ module Datadog
2
+ module CI
3
+ module TestVisibility
4
+ module Serializers
5
+ class TestV1 < Base
6
+ CONTENT_FIELDS: Array[String | Hash[String, String]]
7
+ CONTENT_MAP_SIZE: Integer
8
+ REQUIRED_FIELDS: Array[String]
9
+
10
+ def required_fields: () -> Array[String]
11
+ def content_fields: () -> Array[String | Hash[String, String]]
12
+ def content_map_size: () -> Integer
13
+
14
+ def type: () -> "test"
15
+
16
+ def name: () -> ::String
17
+
18
+ def resource: () -> ::String
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,35 @@
1
+ module Datadog
2
+ module CI
3
+ module TestVisibility
4
+ class Transport
5
+ DEFAULT_MAX_PAYLOAD_SIZE: Integer
6
+
7
+ attr_reader serializers_factory: singleton(Datadog::CI::TestVisibility::Serializers::Factories::TestLevel)
8
+ attr_reader dd_env: String?
9
+ attr_reader api: Datadog::CI::Transport::Api::Base
10
+ attr_reader max_payload_size: Integer
11
+
12
+ @dd_env: String?
13
+ @serializers_factory: singleton(Datadog::CI::TestVisibility::Serializers::Factories::TestLevel)
14
+ @max_payload_size: Integer
15
+
16
+ def initialize: (
17
+ api: Datadog::CI::Transport::Api::Base,
18
+ ?dd_env: ::String?,
19
+ ?serializers_factory: singleton(Datadog::CI::TestVisibility::Serializers::Factories::TestLevel),
20
+ ?max_payload_size: Integer
21
+ ) -> void
22
+
23
+ def send_traces: (Array[Datadog::Tracing::TraceSegment] traces) -> ::Array[Datadog::CI::Transport::HTTP::ResponseDecorator]
24
+
25
+ private
26
+
27
+ def send_payload: (String encoded_payload) -> Datadog::CI::Transport::HTTP::ResponseDecorator
28
+ def pack_events: (Array[String] encoded_events) -> String
29
+ def encode_traces: (Array[Datadog::Tracing::TraceSegment] traces) -> ::Array[String]
30
+ def encode_span: (Datadog::Tracing::TraceSegment trace, Datadog::Tracing::Span span) -> String?
31
+ def encoder: () -> singleton(Datadog::Core::Encoding::MsgpackEncoder)
32
+ end
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,21 @@
1
+ module Datadog
2
+ module CI
3
+ module Transport
4
+ module Api
5
+ class Base
6
+ attr_reader http: Datadog::CI::Transport::HTTP
7
+
8
+ @http: Datadog::CI::Transport::HTTP
9
+
10
+ def initialize: (http: Datadog::CI::Transport::HTTP) -> void
11
+
12
+ def request: (path: String, payload: String, ?verb: ::String) -> untyped
13
+
14
+ private
15
+
16
+ def headers: () -> Hash[String, String]
17
+ end
18
+ end
19
+ end
20
+ end
21
+ end
@@ -0,0 +1,12 @@
1
+ module Datadog
2
+ module CI
3
+ module Transport
4
+ module Api
5
+ module Builder
6
+ def self.build_ci_test_cycle_api: (untyped settings) -> Datadog::CI::Transport::Api::CiTestCycle
7
+ def self.build_evp_proxy_api: (untyped agent_settings) -> Datadog::CI::Transport::Api::EvpProxy
8
+ end
9
+ end
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,21 @@
1
+ module Datadog
2
+ module CI
3
+ module Transport
4
+ module Api
5
+ class CiTestCycle < Base
6
+ attr_reader api_key: String
7
+
8
+ @api_key: String
9
+
10
+ def initialize: (api_key: String, http: Datadog::CI::Transport::HTTP) -> void
11
+
12
+ def request: (path: String, payload: String, ?verb: ::String) -> Datadog::CI::Transport::HTTP::ResponseDecorator
13
+
14
+ private
15
+
16
+ def headers: () -> Hash[String, String]
17
+ end
18
+ end
19
+ end
20
+ end
21
+ end
@@ -0,0 +1,19 @@
1
+ module Datadog
2
+ module CI
3
+ module Transport
4
+ module Api
5
+ class EvpProxy < Base
6
+ @container_id: String?
7
+
8
+ def request: (path: String, payload: String, ?verb: ::String) -> Datadog::CI::Transport::HTTP::ResponseDecorator
9
+
10
+ private
11
+
12
+ def container_id: () -> String?
13
+
14
+ def headers: () -> Hash[String, String]
15
+ end
16
+ end
17
+ end
18
+ end
19
+ end
@@ -0,0 +1,9 @@
1
+ module Datadog
2
+ module CI
3
+ module Transport
4
+ module Gzip
5
+ def self?.compress: (String input) -> String
6
+ end
7
+ end
8
+ end
9
+ end
@@ -0,0 +1,36 @@
1
+ class SimpleDelegator
2
+ end
3
+
4
+ module Datadog
5
+ module CI
6
+ module Transport
7
+ class HTTP
8
+ @adapter: Datadog::Core::Transport::HTTP::Adapters::Net
9
+
10
+ attr_reader host: String
11
+ attr_reader port: Integer?
12
+ attr_reader ssl: bool
13
+ attr_reader timeout: Integer
14
+ attr_reader compress: bool
15
+
16
+ DEFAULT_TIMEOUT: 30
17
+
18
+ def initialize: (host: String, ?port: Integer?, ?ssl: bool, ?timeout: Integer, ?compress: bool) -> void
19
+
20
+ def request: (?verb: String, payload: String, headers: Hash[String, String], path: String) -> ResponseDecorator
21
+
22
+ private
23
+
24
+ def adapter: () -> Datadog::Core::Transport::HTTP::Adapters::Net
25
+
26
+ def build_env: (payload: String, headers: Hash[String, String], path: String, verb: String) -> Datadog::Core::Transport::HTTP::Env
27
+
28
+ class ResponseDecorator < ::SimpleDelegator
29
+ def initialize: (untyped anything) -> void
30
+ def trace_count: () -> Integer
31
+ end
32
+ end
33
+ end
34
+ end
35
+ end
36
+
metadata CHANGED
@@ -1,15 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: datadog-ci
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Datadog, Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-09-14 00:00:00.000000000 Z
12
- dependencies: []
11
+ date: 2023-10-25 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: msgpack
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
13
27
  description: |2
14
28
  datadog-ci is a Datadog's CI visibility library for Ruby. It traces
15
29
  tests as they are being executed and brings developers visibility into
@@ -36,6 +50,7 @@ files:
36
50
  - lib/datadog/ci/contrib/cucumber/instrumentation.rb
37
51
  - lib/datadog/ci/contrib/cucumber/integration.rb
38
52
  - lib/datadog/ci/contrib/cucumber/patcher.rb
53
+ - lib/datadog/ci/contrib/integration.rb
39
54
  - lib/datadog/ci/contrib/minitest/configuration/settings.rb
40
55
  - lib/datadog/ci/contrib/minitest/ext.rb
41
56
  - lib/datadog/ci/contrib/minitest/hooks.rb
@@ -46,11 +61,13 @@ files:
46
61
  - lib/datadog/ci/contrib/rspec/ext.rb
47
62
  - lib/datadog/ci/contrib/rspec/integration.rb
48
63
  - lib/datadog/ci/contrib/rspec/patcher.rb
64
+ - lib/datadog/ci/contrib/settings.rb
49
65
  - lib/datadog/ci/ext/app_types.rb
50
66
  - lib/datadog/ci/ext/environment.rb
51
67
  - lib/datadog/ci/ext/environment/extractor.rb
52
68
  - lib/datadog/ci/ext/environment/providers.rb
53
69
  - lib/datadog/ci/ext/environment/providers/appveyor.rb
70
+ - lib/datadog/ci/ext/environment/providers/aws_code_pipeline.rb
54
71
  - lib/datadog/ci/ext/environment/providers/azure.rb
55
72
  - lib/datadog/ci/ext/environment/providers/base.rb
56
73
  - lib/datadog/ci/ext/environment/providers/bitbucket.rb
@@ -69,9 +86,21 @@ files:
69
86
  - lib/datadog/ci/ext/git.rb
70
87
  - lib/datadog/ci/ext/settings.rb
71
88
  - lib/datadog/ci/ext/test.rb
89
+ - lib/datadog/ci/ext/transport.rb
72
90
  - lib/datadog/ci/extensions.rb
73
- - lib/datadog/ci/flush.rb
74
- - lib/datadog/ci/test.rb
91
+ - lib/datadog/ci/recorder.rb
92
+ - lib/datadog/ci/test_visibility/flush.rb
93
+ - lib/datadog/ci/test_visibility/serializers/base.rb
94
+ - lib/datadog/ci/test_visibility/serializers/factories/test_level.rb
95
+ - lib/datadog/ci/test_visibility/serializers/span.rb
96
+ - lib/datadog/ci/test_visibility/serializers/test_v1.rb
97
+ - lib/datadog/ci/test_visibility/transport.rb
98
+ - lib/datadog/ci/transport/api/base.rb
99
+ - lib/datadog/ci/transport/api/builder.rb
100
+ - lib/datadog/ci/transport/api/ci_test_cycle.rb
101
+ - lib/datadog/ci/transport/api/evp_proxy.rb
102
+ - lib/datadog/ci/transport/gzip.rb
103
+ - lib/datadog/ci/transport/http.rb
75
104
  - lib/datadog/ci/utils/git.rb
76
105
  - lib/datadog/ci/version.rb
77
106
  - sig/datadog/ci.rbs
@@ -83,6 +112,7 @@ files:
83
112
  - sig/datadog/ci/contrib/cucumber/instrumentation.rbs
84
113
  - sig/datadog/ci/contrib/cucumber/integration.rbs
85
114
  - sig/datadog/ci/contrib/cucumber/patcher.rbs
115
+ - sig/datadog/ci/contrib/integration.rbs
86
116
  - sig/datadog/ci/contrib/minitest/configuration/settings.rbs
87
117
  - sig/datadog/ci/contrib/minitest/ext.rbs
88
118
  - sig/datadog/ci/contrib/minitest/hooks.rbs
@@ -93,11 +123,13 @@ files:
93
123
  - sig/datadog/ci/contrib/rspec/ext.rbs
94
124
  - sig/datadog/ci/contrib/rspec/integration.rbs
95
125
  - sig/datadog/ci/contrib/rspec/patcher.rbs
126
+ - sig/datadog/ci/contrib/settings.rbs
96
127
  - sig/datadog/ci/ext/app_types.rbs
97
128
  - sig/datadog/ci/ext/environment.rbs
98
129
  - sig/datadog/ci/ext/environment/extractor.rbs
99
130
  - sig/datadog/ci/ext/environment/providers.rbs
100
131
  - sig/datadog/ci/ext/environment/providers/appveyor.rbs
132
+ - sig/datadog/ci/ext/environment/providers/aws_code_pipeline.rbs
101
133
  - sig/datadog/ci/ext/environment/providers/azure.rbs
102
134
  - sig/datadog/ci/ext/environment/providers/base.rbs
103
135
  - sig/datadog/ci/ext/environment/providers/bitbucket.rbs
@@ -116,9 +148,21 @@ files:
116
148
  - sig/datadog/ci/ext/git.rbs
117
149
  - sig/datadog/ci/ext/settings.rbs
118
150
  - sig/datadog/ci/ext/test.rbs
151
+ - sig/datadog/ci/ext/transport.rbs
119
152
  - sig/datadog/ci/extensions.rbs
120
- - sig/datadog/ci/flush.rbs
121
- - sig/datadog/ci/test.rbs
153
+ - sig/datadog/ci/recorder.rbs
154
+ - sig/datadog/ci/test_visibility/flush.rbs
155
+ - sig/datadog/ci/test_visibility/serializers/base.rbs
156
+ - sig/datadog/ci/test_visibility/serializers/factories/test_level.rbs
157
+ - sig/datadog/ci/test_visibility/serializers/span.rbs
158
+ - sig/datadog/ci/test_visibility/serializers/test_v1.rbs
159
+ - sig/datadog/ci/test_visibility/transport.rbs
160
+ - sig/datadog/ci/transport/api/base.rbs
161
+ - sig/datadog/ci/transport/api/builder.rbs
162
+ - sig/datadog/ci/transport/api/ci_test_cycle.rbs
163
+ - sig/datadog/ci/transport/api/evp_proxy.rbs
164
+ - sig/datadog/ci/transport/gzip.rbs
165
+ - sig/datadog/ci/transport/http.rbs
122
166
  - sig/datadog/ci/utils/git.rbs
123
167
  - sig/datadog/ci/version.rbs
124
168
  homepage: https://github.com/DataDog/datadog-ci-rb
@@ -147,7 +191,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
147
191
  - !ruby/object:Gem::Version
148
192
  version: 2.0.0
149
193
  requirements: []
150
- rubygems_version: 3.4.18
194
+ rubygems_version: 3.4.21
151
195
  signing_key:
152
196
  specification_version: 4
153
197
  summary: Datadog CI visibility for your ruby application
@@ -1,38 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "datadog/tracing/metadata/ext"
4
- require "datadog/tracing/flush"
5
-
6
- module Datadog
7
- module CI
8
- module Flush
9
- # Common behavior for CI flushing
10
- module Tagging
11
- # Decorate a trace with CI tags
12
- def get_trace(trace_op)
13
- trace = trace_op.flush!
14
-
15
- # Origin tag is required on every span
16
- trace.spans.each do |span|
17
- span.set_tag(
18
- Tracing::Metadata::Ext::Distributed::TAG_ORIGIN,
19
- trace.origin
20
- )
21
- end
22
-
23
- trace
24
- end
25
- end
26
-
27
- # Consumes only completed traces (where all spans have finished)
28
- class Finished < Tracing::Flush::Finished
29
- prepend Tagging
30
- end
31
-
32
- # Performs partial trace flushing to avoid large traces residing in memory for too long
33
- class Partial < Tracing::Flush::Partial
34
- prepend Tagging
35
- end
36
- end
37
- end
38
- end
@@ -1,15 +0,0 @@
1
- module Datadog
2
- module CI
3
- module Flush
4
- module Tagging
5
- def get_trace: (untyped trace_op) -> untyped
6
- end
7
- class Finished < Tracing::Flush::Finished
8
- prepend Tagging
9
- end
10
- class Partial < Tracing::Flush::Partial
11
- prepend Tagging
12
- end
13
- end
14
- end
15
- end