libdatadog 25.0.0.1.0 → 26.0.0.1.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.
Files changed (84) hide show
  1. checksums.yaml +4 -4
  2. data/lib/libdatadog/version.rb +1 -1
  3. data/lib/libdatadog.rb +6 -0
  4. data/vendor/{libdatadog-25.0.0/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl → libdatadog-26.0.0/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu}/LICENSE-3rdparty.yml +11292 -5944
  5. data/vendor/{libdatadog-25.0.0/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl → libdatadog-26.0.0/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu}/include/datadog/common.h +156 -179
  6. data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/profiling.h +32 -62
  7. data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/lib/libdatadog_profiling.so +0 -0
  8. data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/lib/pkgconfig/datadog_profiling_with_rpath.pc +1 -1
  9. data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl}/LICENSE-3rdparty.yml +11292 -5944
  10. data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl}/include/datadog/common.h +156 -179
  11. data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl}/include/datadog/profiling.h +32 -62
  12. data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/lib/libdatadog_profiling.so +0 -0
  13. data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/lib/pkgconfig/datadog_profiling_with_rpath.pc +1 -1
  14. data/vendor/{libdatadog-25.0.0/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/LICENSE-3rdparty.yml +11292 -5944
  15. data/vendor/libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin/bin/libdatadog-crashtracking-receiver +0 -0
  16. data/vendor/{libdatadog-25.0.0/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/include/datadog/common.h +156 -179
  17. data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/include/datadog/profiling.h +32 -62
  18. data/vendor/libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin/lib/libdatadog_profiling.dylib +0 -0
  19. data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/lib/pkgconfig/datadog_profiling_with_rpath.pc +1 -1
  20. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/LICENSE +202 -0
  21. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/LICENSE-3rdparty.yml +55070 -0
  22. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/NOTICE +4 -0
  23. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/blazesym.h +1497 -0
  24. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/common.h +2651 -0
  25. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/crashtracker.h +953 -0
  26. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/data-pipeline.h +183 -0
  27. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/ddsketch.h +89 -0
  28. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/ffe.h +175 -0
  29. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/library-config.h +113 -0
  30. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/log.h +63 -0
  31. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/profiling.h +941 -0
  32. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/telemetry.h +286 -0
  33. data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/lib/libdatadog_profiling.so +0 -0
  34. data/vendor/libdatadog-26.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/lib/pkgconfig/datadog_profiling_with_rpath.pc +15 -0
  35. data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/LICENSE-3rdparty.yml +11292 -5944
  36. data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/common.h +156 -179
  37. data/vendor/{libdatadog-25.0.0/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/profiling.h +32 -62
  38. data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/lib/libdatadog_profiling.so +0 -0
  39. data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/lib/pkgconfig/datadog_profiling_with_rpath.pc +1 -1
  40. metadata +81 -65
  41. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/LICENSE +0 -0
  42. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/NOTICE +0 -0
  43. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/bin/libdatadog-crashtracking-receiver +0 -0
  44. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/blazesym.h +0 -0
  45. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/crashtracker.h +0 -0
  46. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/data-pipeline.h +0 -0
  47. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/ddsketch.h +0 -0
  48. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/ffe.h +0 -0
  49. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/library-config.h +0 -0
  50. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/log.h +0 -0
  51. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/telemetry.h +0 -0
  52. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/LICENSE +0 -0
  53. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/NOTICE +0 -0
  54. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/bin/libdatadog-crashtracking-receiver +0 -0
  55. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/blazesym.h +0 -0
  56. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/crashtracker.h +0 -0
  57. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/data-pipeline.h +0 -0
  58. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/ddsketch.h +0 -0
  59. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/ffe.h +0 -0
  60. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/library-config.h +0 -0
  61. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/log.h +0 -0
  62. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/telemetry.h +0 -0
  63. /data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/LICENSE +0 -0
  64. /data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/NOTICE +0 -0
  65. /data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/include/datadog/blazesym.h +0 -0
  66. /data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/include/datadog/crashtracker.h +0 -0
  67. /data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/include/datadog/data-pipeline.h +0 -0
  68. /data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/include/datadog/ddsketch.h +0 -0
  69. /data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/include/datadog/ffe.h +0 -0
  70. /data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/include/datadog/library-config.h +0 -0
  71. /data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/include/datadog/log.h +0 -0
  72. /data/vendor/{libdatadog-25.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-26.0.0/arm64-darwin/libdatadog-aarch64-apple-darwin}/include/datadog/telemetry.h +0 -0
  73. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/bin/libdatadog-crashtracking-receiver +0 -0
  74. /data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/LICENSE +0 -0
  75. /data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/NOTICE +0 -0
  76. /data/vendor/{libdatadog-25.0.0 → libdatadog-26.0.0}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/bin/libdatadog-crashtracking-receiver +0 -0
  77. /data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/blazesym.h +0 -0
  78. /data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/crashtracker.h +0 -0
  79. /data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/data-pipeline.h +0 -0
  80. /data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/ddsketch.h +0 -0
  81. /data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/ffe.h +0 -0
  82. /data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/library-config.h +0 -0
  83. /data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/log.h +0 -0
  84. /data/vendor/{libdatadog-25.0.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu → libdatadog-26.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/telemetry.h +0 -0
@@ -0,0 +1,183 @@
1
+ // Copyright 2021-Present Datadog, Inc. https://www.datadoghq.com/
2
+ // SPDX-License-Identifier: Apache-2.0
3
+
4
+
5
+ #ifndef DDOG_DATA_PIPELINE_H
6
+ #define DDOG_DATA_PIPELINE_H
7
+
8
+ #include <stdarg.h>
9
+ #include <stdbool.h>
10
+ #include <stdint.h>
11
+ #include <stdlib.h>
12
+ #include "common.h"
13
+
14
+ #ifdef __cplusplus
15
+ extern "C" {
16
+ #endif // __cplusplus
17
+
18
+ /**
19
+ * Frees `error` and all its contents. After being called error will not point to a valid memory
20
+ * address so any further actions on it could lead to undefined behavior.
21
+ */
22
+ void ddog_trace_exporter_error_free(struct ddog_TraceExporterError *error);
23
+
24
+ /**
25
+ * Return a read-only pointer to the response body. This pointer is only valid as long as
26
+ * `response` is valid.
27
+ */
28
+ const uint8_t *ddog_trace_exporter_response_get_body(const struct ddog_TraceExporterResponse *response,
29
+ uintptr_t *out_len);
30
+
31
+ /**
32
+ * Free `response` and all its contents. After being called response will not point to a valid
33
+ * memory address so any further actions on it could lead to undefined behavior.
34
+ */
35
+ void ddog_trace_exporter_response_free(struct ddog_TraceExporterResponse *response);
36
+
37
+ void ddog_trace_exporter_config_new(struct ddog_TraceExporterConfig **out_handle);
38
+
39
+ /**
40
+ * Frees TraceExporterConfig handle internal resources.
41
+ */
42
+ void ddog_trace_exporter_config_free(struct ddog_TraceExporterConfig *handle);
43
+
44
+ /**
45
+ * Sets traces destination.
46
+ */
47
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_url(struct ddog_TraceExporterConfig *config,
48
+ ddog_CharSlice url);
49
+
50
+ /**
51
+ * Sets tracer's version to be included in the headers request.
52
+ */
53
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_tracer_version(struct ddog_TraceExporterConfig *config,
54
+ ddog_CharSlice version);
55
+
56
+ /**
57
+ * Sets tracer's language to be included in the headers request.
58
+ */
59
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_language(struct ddog_TraceExporterConfig *config,
60
+ ddog_CharSlice lang);
61
+
62
+ /**
63
+ * Sets tracer's language version to be included in the headers request.
64
+ */
65
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_lang_version(struct ddog_TraceExporterConfig *config,
66
+ ddog_CharSlice version);
67
+
68
+ /**
69
+ * Sets tracer's language interpreter to be included in the headers request.
70
+ */
71
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_lang_interpreter(struct ddog_TraceExporterConfig *config,
72
+ ddog_CharSlice interpreter);
73
+
74
+ /**
75
+ * Sets hostname information to be included in the headers request.
76
+ */
77
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_hostname(struct ddog_TraceExporterConfig *config,
78
+ ddog_CharSlice hostname);
79
+
80
+ /**
81
+ * Sets environment information to be included in the headers request.
82
+ */
83
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_env(struct ddog_TraceExporterConfig *config,
84
+ ddog_CharSlice env);
85
+
86
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_version(struct ddog_TraceExporterConfig *config,
87
+ ddog_CharSlice version);
88
+
89
+ /**
90
+ * Sets service name to be included in the headers request.
91
+ */
92
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_service(struct ddog_TraceExporterConfig *config,
93
+ ddog_CharSlice service);
94
+
95
+ /**
96
+ * Enables health metrics emission.
97
+ */
98
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_enable_health_metrics(struct ddog_TraceExporterConfig *config,
99
+ bool is_enabled);
100
+
101
+ /**
102
+ * Enables telemetry metrics.
103
+ */
104
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_enable_telemetry(struct ddog_TraceExporterConfig *config,
105
+ const struct ddog_TelemetryClientConfig *telemetry_cfg);
106
+
107
+ /**
108
+ * Set client-side stats computation status.
109
+ */
110
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_compute_stats(struct ddog_TraceExporterConfig *config,
111
+ bool is_enabled);
112
+
113
+ /**
114
+ * Sets `Datadog-Client-Computed-Stats` header to `true`.
115
+ * This indicates that the upstream system has already computed the stats,
116
+ * and no further stats computation should be performed.
117
+ *
118
+ * <div class="warning">
119
+ * This method must not be used when `compute_stats` is enabled, as it could
120
+ * result in duplicate stats computation.
121
+ * </div>
122
+ *
123
+ * A common use case is in Application Security Monitoring (ASM) scenarios:
124
+ * when APM is disabled but ASM is enabled, setting this header to `true`
125
+ * ensures that no stats are computed at any level (exporter or agent).
126
+ */
127
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_client_computed_stats(struct ddog_TraceExporterConfig *config,
128
+ bool client_computed_stats);
129
+
130
+ /**
131
+ * Sets the `X-Datadog-Test-Session-Token` header. Only used for testing with the test agent.
132
+ */
133
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_test_session_token(struct ddog_TraceExporterConfig *config,
134
+ ddog_CharSlice token);
135
+
136
+ /**
137
+ * Sets the timeout in ms for all agent's connections.
138
+ */
139
+ struct ddog_TraceExporterError *ddog_trace_exporter_config_set_connection_timeout(struct ddog_TraceExporterConfig *config,
140
+ uint64_t timeout_ms);
141
+
142
+ /**
143
+ * Create a new TraceExporter instance.
144
+ *
145
+ * # Arguments
146
+ *
147
+ * * `out_handle` - The handle to write the TraceExporter instance in.
148
+ * * `config` - The configuration used to set up the TraceExporter handle.
149
+ */
150
+ struct ddog_TraceExporterError *ddog_trace_exporter_new(struct ddog_TraceExporter **out_handle,
151
+ const struct ddog_TraceExporterConfig *config);
152
+
153
+ /**
154
+ * Free the TraceExporter instance.
155
+ *
156
+ * # Arguments
157
+ *
158
+ * * handle - The handle to the TraceExporter instance.
159
+ */
160
+ void ddog_trace_exporter_free(struct ddog_TraceExporter *handle);
161
+
162
+ /**
163
+ * Send traces to the Datadog Agent.
164
+ *
165
+ * # Arguments
166
+ *
167
+ * * `handle` - The handle to the TraceExporter instance.
168
+ * * `trace` - The traces to send to the Datadog Agent in the input format used to create the
169
+ * TraceExporter. The memory for the trace must be valid for the life of the call to this
170
+ * function.
171
+ * * `trace_count` - The number of traces to send to the Datadog Agent.
172
+ * * `response_out` - Optional handle to store a pointer to the agent response information.
173
+ */
174
+ struct ddog_TraceExporterError *ddog_trace_exporter_send(const struct ddog_TraceExporter *handle,
175
+ ddog_ByteSlice trace,
176
+ uintptr_t trace_count,
177
+ struct ddog_TraceExporterResponse **response_out);
178
+
179
+ #ifdef __cplusplus
180
+ } // extern "C"
181
+ #endif // __cplusplus
182
+
183
+ #endif /* DDOG_DATA_PIPELINE_H */
@@ -0,0 +1,89 @@
1
+ // Copyright 2025-Present Datadog, Inc. https://www.datadoghq.com/
2
+ // SPDX-License-Identifier: Apache-2.0
3
+
4
+
5
+ #ifndef DDOG_DDSKETCH_H
6
+ #define DDOG_DDSKETCH_H
7
+
8
+ #pragma once
9
+
10
+ #include <stdbool.h>
11
+ #include <stddef.h>
12
+ #include <stdint.h>
13
+ #include "common.h"
14
+
15
+ #ifdef __cplusplus
16
+ extern "C" {
17
+ #endif // __cplusplus
18
+
19
+ /**
20
+ * Creates a new DDSketch instance with default configuration.
21
+ */
22
+ struct ddsketch_Handle_DDSketch ddog_ddsketch_new(void);
23
+
24
+ /**
25
+ * Drops a DDSketch instance.
26
+ *
27
+ * # Safety
28
+ *
29
+ * The sketch handle must have been created by this library and not already dropped.
30
+ */
31
+ void ddog_ddsketch_drop(struct ddsketch_Handle_DDSketch *sketch);
32
+
33
+ /**
34
+ * Adds a point to the DDSketch.
35
+ *
36
+ * # Safety
37
+ *
38
+ * The `sketch` parameter must be a valid pointer to a DDSketch handle.
39
+ */
40
+ struct ddog_VoidResult ddog_ddsketch_add(struct ddsketch_Handle_DDSketch *sketch, double point);
41
+
42
+ /**
43
+ * Adds a point with a specific count to the DDSketch.
44
+ *
45
+ * # Safety
46
+ *
47
+ * The `sketch` parameter must be a valid pointer to a DDSketch handle.
48
+ */
49
+ struct ddog_VoidResult ddog_ddsketch_add_with_count(struct ddsketch_Handle_DDSketch *sketch,
50
+ double point,
51
+ double count);
52
+
53
+ /**
54
+ * Returns the count of points in the DDSketch via the output parameter.
55
+ *
56
+ * # Safety
57
+ *
58
+ * The `sketch` parameter must be a valid pointer to a DDSketch handle.
59
+ * The `count_out` parameter must be a valid pointer to uninitialized f64 memory.
60
+ */
61
+ struct ddog_VoidResult ddog_ddsketch_count(struct ddsketch_Handle_DDSketch *sketch,
62
+ double *count_out);
63
+
64
+ /**
65
+ * Returns the protobuf-encoded bytes of the DDSketch.
66
+ * The sketch handle is consumed by this operation.
67
+ *
68
+ * # Safety
69
+ *
70
+ * The `sketch` parameter must be a valid pointer to a DDSketch handle.
71
+ * The returned vector must be freed with `ddog_Vec_U8_drop`.
72
+ */
73
+ struct ddog_Vec_U8 ddog_ddsketch_encode(struct ddsketch_Handle_DDSketch *sketch);
74
+
75
+ /**
76
+ * Frees the memory allocated for a Vec<u8> returned by ddsketch functions.
77
+ *
78
+ * # Safety
79
+ *
80
+ * The vec parameter must be a valid Vec<u8> returned by this library.
81
+ * After being called, the vec will not point to valid memory.
82
+ */
83
+ void ddog_Vec_U8_drop(struct ddog_Vec_U8 _vec);
84
+
85
+ #ifdef __cplusplus
86
+ } // extern "C"
87
+ #endif // __cplusplus
88
+
89
+ #endif /* DDOG_DDSKETCH_H */
@@ -0,0 +1,175 @@
1
+ // Copyright 2025-Present Datadog, Inc. https://www.datadoghq.com/
2
+ // SPDX-License-Identifier: Apache-2.0
3
+
4
+
5
+ #ifndef DDOG_FFE_H
6
+ #define DDOG_FFE_H
7
+
8
+ #pragma once
9
+
10
+ #include <stdbool.h>
11
+ #include <stddef.h>
12
+ #include <stdint.h>
13
+ #include "common.h"
14
+
15
+ #ifdef __cplusplus
16
+ extern "C" {
17
+ #endif // __cplusplus
18
+
19
+ /**
20
+ * Evaluates a feature flag.
21
+ *
22
+ * # Ownership
23
+ *
24
+ * The caller must call `ddog_ffe_assignment_drop` on the returned value to free resources.
25
+ *
26
+ * # Safety
27
+ *
28
+ * - `config` must be a valid `Configuration` handle
29
+ * - `flag_key` must be a valid C string
30
+ * - `context` must be a valid `EvaluationContext` handle
31
+ */
32
+ DDOG_CHECK_RETURN
33
+ ddog_ffe_Handle_ResolutionDetails ddog_ffe_get_assignment(ddog_ffe_Handle_Configuration config,
34
+ const char *flag_key,
35
+ enum ddog_ffe_ExpectedFlagType expected_type,
36
+ ddog_ffe_Handle_EvaluationContext context);
37
+
38
+ /**
39
+ * Get value produced by evaluation.
40
+ *
41
+ * # Ownership
42
+ *
43
+ * The returned `VariantValue` borrows from `assignment`. It must not be used after `assignment` is
44
+ * freed.
45
+ *
46
+ * # Safety
47
+ * `assignment` must be a valid handle.
48
+ */
49
+ struct ddog_ffe_VariantValue ddog_ffe_assignment_get_value(ddog_ffe_Handle_ResolutionDetails assignment);
50
+
51
+ /**
52
+ * Get variant key produced by evaluation. Returns `NULL` if evaluation did not produce any value.
53
+ *
54
+ * # Ownership
55
+ *
56
+ * The returned string borrows from `assignment`. It must not be used after `assignment` is
57
+ * freed.
58
+ *
59
+ * # Safety
60
+ * `assignment` must be a valid handle.
61
+ */
62
+ struct ddog_ffe_BorrowedStr ddog_ffe_assignment_get_variant(ddog_ffe_Handle_ResolutionDetails assignment);
63
+
64
+ /**
65
+ * Get allocation key produced by evaluation. Returns `NULL` if evaluation did not produce any
66
+ * value.
67
+ *
68
+ * # Ownership
69
+ *
70
+ * The returned string borrows from `assignment`. It must not be used after `assignment` is
71
+ * freed.
72
+ *
73
+ * # Safety
74
+ * `assignment` must be a valid handle.
75
+ */
76
+ struct ddog_ffe_BorrowedStr ddog_ffe_assignment_get_allocation_key(ddog_ffe_Handle_ResolutionDetails assignment);
77
+
78
+ /**
79
+ * # Safety
80
+ * `assignment` must be a valid handle.
81
+ */
82
+ enum ddog_ffe_Reason ddog_ffe_assignment_get_reason(ddog_ffe_Handle_ResolutionDetails assignment);
83
+
84
+ /**
85
+ * # Safety
86
+ * `assignment` must be a valid handle.
87
+ */
88
+ enum ddog_ffe_ErrorCode ddog_ffe_assignment_get_error_code(ddog_ffe_Handle_ResolutionDetails assignment);
89
+
90
+ /**
91
+ * # Safety
92
+ * `assignment` must be a valid handle.
93
+ */
94
+ struct ddog_ffe_BorrowedStr ddog_ffe_assignment_get_error_message(ddog_ffe_Handle_ResolutionDetails assignment);
95
+
96
+ /**
97
+ * # Safety
98
+ * `assignment` must be a valid handle.
99
+ */
100
+ bool ddog_ffe_assignment_get_do_log(ddog_ffe_Handle_ResolutionDetails assignment);
101
+
102
+ /**
103
+ * # Safety
104
+ * `assignment` must be a valid handle.
105
+ */
106
+ struct ddog_ffe_ArrayMap_BorrowedStr ddog_ffe_assignnment_get_flag_metadata(ddog_ffe_Handle_ResolutionDetails assignment);
107
+
108
+ /**
109
+ * # Safety
110
+ * `assignment` must be a valid handle.
111
+ */
112
+ struct ddog_ffe_ArrayMap_BorrowedStr ddog_ffe_assignnment_get_extra_logging(ddog_ffe_Handle_ResolutionDetails assignment);
113
+
114
+ /**
115
+ * Frees an Assignment handle.
116
+ *
117
+ * # Safety
118
+ * - `assignment` must be a valid Assignment handle
119
+ */
120
+ void ddog_ffe_assignment_drop(ddog_ffe_Handle_ResolutionDetails *assignment);
121
+
122
+ /**
123
+ * Creates a new Configuration from JSON bytes.
124
+ *
125
+ * # Ownership
126
+ *
127
+ * The caller must call `ddog_ffe_configuration_drop` to release resources allocated for
128
+ * configuration.
129
+ *
130
+ * # Safety
131
+ *
132
+ * - `json_bytes` must point to valid memory.
133
+ */
134
+ DDOG_CHECK_RETURN
135
+ struct ddog_ffe_Result_HandleConfiguration ddog_ffe_configuration_new(struct ddog_ffe_BorrowedStr json_bytes);
136
+
137
+ /**
138
+ * Frees a Configuration.
139
+ *
140
+ * # Safety
141
+ *
142
+ * `config` must be a valid Configuration handle created by `ddog_ffe_configuration_new`.
143
+ */
144
+ void ddog_ffe_configuration_drop(ddog_ffe_Handle_Configuration *config);
145
+
146
+ /**
147
+ * Creates a new EvaluationContext with the given targeting key and attributes.
148
+ *
149
+ * # Ownership
150
+ *
151
+ * `ddog_ffe_evaluation_context_drop` must be called on the result value to free resources.
152
+ *
153
+ * # Safety
154
+ * - `targeting_key` must be a valid C string or NULL.
155
+ * - `attributes` must point to a valid array of valid `AttributePair` structs (can be null if
156
+ * `attributes_count` is 0)
157
+ */
158
+ DDOG_CHECK_RETURN
159
+ ddog_ffe_Handle_EvaluationContext ddog_ffe_evaluation_context_new(const char *targeting_key,
160
+ const struct ddog_ffe_AttributePair *attributes,
161
+ uintptr_t attributes_count);
162
+
163
+ /**
164
+ * Frees an EvaluationContext
165
+ *
166
+ * # Safety
167
+ * `context` must be a valid EvaluationContext handle created by `ddog_ffe_evaluation_context_new`
168
+ */
169
+ void ddog_ffe_evaluation_context_drop(ddog_ffe_Handle_EvaluationContext *context);
170
+
171
+ #ifdef __cplusplus
172
+ } // extern "C"
173
+ #endif // __cplusplus
174
+
175
+ #endif /* DDOG_FFE_H */
@@ -0,0 +1,113 @@
1
+ // Copyright 2021-Present Datadog, Inc. https://www.datadoghq.com/
2
+ // SPDX-License-Identifier: Apache-2.0
3
+
4
+
5
+ #ifndef DDOG_LIBRARY_CONFIG_H
6
+ #define DDOG_LIBRARY_CONFIG_H
7
+
8
+ #pragma once
9
+
10
+ #include "common.h"
11
+
12
+ #ifdef __cplusplus
13
+ extern "C" {
14
+ #endif // __cplusplus
15
+
16
+ struct ddog_Configurator *ddog_library_configurator_new(bool debug_logs, ddog_CharSlice language);
17
+
18
+ void ddog_library_configurator_with_local_path(struct ddog_Configurator *c,
19
+ struct ddog_CStr local_path);
20
+
21
+ void ddog_library_configurator_with_fleet_path(struct ddog_Configurator *c,
22
+ struct ddog_CStr local_path);
23
+
24
+ void ddog_library_configurator_with_process_info(struct ddog_Configurator *c,
25
+ struct ddog_ProcessInfo p);
26
+
27
+ void ddog_library_configurator_with_detect_process_info(struct ddog_Configurator *c);
28
+
29
+ void ddog_library_configurator_drop(struct ddog_Configurator*);
30
+
31
+ struct ddog_LibraryConfigLoggedResult ddog_library_configurator_get(const struct ddog_Configurator *configurator);
32
+
33
+ /**
34
+ * Returns a static null-terminated string, containing the name of the environment variable
35
+ * associated with the library configuration
36
+ */
37
+ struct ddog_CStr ddog_library_config_source_to_string(enum ddog_LibraryConfigSource name);
38
+
39
+ /**
40
+ * Returns a static null-terminated string with the path to the managed stable config yaml config
41
+ * file
42
+ */
43
+ struct ddog_CStr ddog_library_config_fleet_stable_config_path(void);
44
+
45
+ /**
46
+ * Returns a static null-terminated string with the path to the local stable config yaml config
47
+ * file
48
+ */
49
+ struct ddog_CStr ddog_library_config_local_stable_config_path(void);
50
+
51
+ void ddog_library_config_drop(struct ddog_LibraryConfigLoggedResult config_result);
52
+
53
+ /**
54
+ * Allocates and returns a pointer to a new `TracerMetadata` object on the heap.
55
+ *
56
+ * # Safety
57
+ * This function returns a raw pointer. The caller is responsible for calling
58
+ * `ddog_tracer_metadata_free` to deallocate the memory.
59
+ *
60
+ * # Returns
61
+ * A non-null pointer to a newly allocated `TracerMetadata` instance.
62
+ */
63
+ struct ddog_TracerMetadata *ddog_tracer_metadata_new(void);
64
+
65
+ /**
66
+ * Frees a `TracerMetadata` instance previously allocated with `ddog_tracer_metadata_new`.
67
+ *
68
+ * # Safety
69
+ * - `ptr` must be a pointer previously returned by `ddog_tracer_metadata_new`.
70
+ * - Double-freeing or passing an invalid pointer results in undefined behavior.
71
+ * - Passing a null pointer is safe and does nothing.
72
+ */
73
+ void ddog_tracer_metadata_free(struct ddog_TracerMetadata *ptr);
74
+
75
+ /**
76
+ * Sets a field of the `TracerMetadata` object pointed to by `ptr`.
77
+ *
78
+ * # Arguments
79
+ * - `ptr`: Pointer to a `TracerMetadata` instance.
80
+ * - `kind`: The metadata field to set (as defined in `MetadataKind`).
81
+ * - `value`: A null-terminated C string representing the value to set.
82
+ *
83
+ * # Safety
84
+ * - Both `ptr` and `value` must be non-null.
85
+ * - `value` must point to a valid UTF-8 null-terminated string.
86
+ * - If the string is not valid UTF-8, the function does nothing.
87
+ */
88
+ void ddog_tracer_metadata_set(struct ddog_TracerMetadata *ptr,
89
+ enum ddog_MetadataKind kind,
90
+ const char *value);
91
+
92
+ /**
93
+ * Serializes the `TracerMetadata` into a platform-specific memory handle (e.g., memfd on Linux).
94
+ *
95
+ * # Safety
96
+ * - `ptr` must be a valid, non-null pointer to a `TracerMetadata`.
97
+ *
98
+ * # Returns
99
+ * - On Linux: a `TracerMemfdHandle` containing a raw file descriptor to a memory file.
100
+ * - On unsupported platforms: an error.
101
+ * - On failure: propagates any internal errors from the metadata storage process.
102
+ *
103
+ * # Platform Support
104
+ * This function currently only supports Linux via `memfd`. On other platforms,
105
+ * it will return an error.
106
+ */
107
+ struct ddog_Result_TracerMemfdHandle ddog_tracer_metadata_store(struct ddog_TracerMetadata *ptr);
108
+
109
+ #ifdef __cplusplus
110
+ } // extern "C"
111
+ #endif // __cplusplus
112
+
113
+ #endif /* DDOG_LIBRARY_CONFIG_H */
@@ -0,0 +1,63 @@
1
+ // Copyright 2025-Present Datadog, Inc. https://www.datadoghq.com/
2
+ // SPDX-License-Identifier: Apache-2.0
3
+
4
+
5
+ #ifndef DDOG_LOG_H
6
+ #define DDOG_LOG_H
7
+
8
+ #include <stdbool.h>
9
+ #include <stddef.h>
10
+ #include <stdint.h>
11
+ #include <stdio.h>
12
+ #include "common.h"
13
+
14
+ /**
15
+ * Configures the logger to write to stdout or stderr with the specified configuration.
16
+ *
17
+ * # Arguments
18
+ * * `config` - Configuration for standard stream logging including target
19
+ *
20
+ * # Errors
21
+ * Returns an error if the logger cannot be configured.
22
+ */
23
+ struct ddog_Error *ddog_logger_configure_std(struct ddog_StdConfig config);
24
+
25
+ /**
26
+ * Disables logging by configuring a no-op logger.
27
+ *
28
+ * # Errors
29
+ * Returns an error if the logger cannot be configured.
30
+ */
31
+ struct ddog_Error *ddog_logger_disable_std(void);
32
+
33
+ /**
34
+ * Configures the logger to write to a file with the specified configuration.
35
+ *
36
+ * # Arguments
37
+ * * `config` - Configuration for file logging including path
38
+ *
39
+ * # Errors
40
+ * Returns an error if the logger cannot be configured.
41
+ */
42
+ struct ddog_Error *ddog_logger_configure_file(struct ddog_FileConfig config);
43
+
44
+ /**
45
+ * Disables file logging by configuring a no-op file writer.
46
+ *
47
+ * # Errors
48
+ * Returns an error if the logger cannot be configured.
49
+ */
50
+ struct ddog_Error *ddog_logger_disable_file(void);
51
+
52
+ /**
53
+ * Sets the global log level.
54
+ *
55
+ * # Arguments
56
+ * * `log_level` - The minimum level for events to be logged
57
+ *
58
+ * # Errors
59
+ * Returns an error if the log level cannot be set.
60
+ */
61
+ struct ddog_Error *ddog_logger_set_log_level(enum ddog_LogEventLevel log_level);
62
+
63
+ #endif /* DDOG_LOG_H */