libdatadog 24.0.0.1.0 → 24.0.1.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 (67) hide show
  1. checksums.yaml +4 -4
  2. data/lib/libdatadog/version.rb +1 -1
  3. data/vendor/{libdatadog-24.0.0/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl → libdatadog-24.0.1/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu}/include/datadog/common.h +210 -0
  4. data/vendor/libdatadog-24.0.1/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/ffe.h +175 -0
  5. data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/lib/libdatadog_profiling.so +0 -0
  6. data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/lib/pkgconfig/datadog_profiling_with_rpath.pc +1 -1
  7. data/vendor/{libdatadog-24.0.0/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl → libdatadog-24.0.1/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl}/include/datadog/common.h +210 -0
  8. data/vendor/libdatadog-24.0.1/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/ffe.h +175 -0
  9. data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/lib/libdatadog_profiling.so +0 -0
  10. data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/lib/pkgconfig/datadog_profiling_with_rpath.pc +1 -1
  11. data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/common.h +210 -0
  12. data/vendor/libdatadog-24.0.1/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/ffe.h +175 -0
  13. data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/lib/libdatadog_profiling.so +0 -0
  14. data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/lib/pkgconfig/datadog_profiling_with_rpath.pc +1 -1
  15. data/vendor/{libdatadog-24.0.0/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu → libdatadog-24.0.1/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl}/include/datadog/common.h +210 -0
  16. data/vendor/libdatadog-24.0.1/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/include/datadog/ffe.h +175 -0
  17. data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/lib/libdatadog_profiling.so +0 -0
  18. data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/lib/pkgconfig/datadog_profiling_with_rpath.pc +1 -1
  19. metadata +65 -61
  20. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/LICENSE +0 -0
  21. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/LICENSE-3rdparty.yml +0 -0
  22. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/NOTICE +0 -0
  23. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/bin/libdatadog-crashtracking-receiver +0 -0
  24. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/blazesym.h +0 -0
  25. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/crashtracker.h +0 -0
  26. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/data-pipeline.h +0 -0
  27. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/ddsketch.h +0 -0
  28. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/library-config.h +0 -0
  29. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/log.h +0 -0
  30. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/profiling.h +0 -0
  31. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux/libdatadog-aarch64-unknown-linux-gnu/include/datadog/telemetry.h +0 -0
  32. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/LICENSE +0 -0
  33. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/LICENSE-3rdparty.yml +0 -0
  34. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/NOTICE +0 -0
  35. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/bin/libdatadog-crashtracking-receiver +0 -0
  36. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/blazesym.h +0 -0
  37. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/crashtracker.h +0 -0
  38. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/data-pipeline.h +0 -0
  39. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/ddsketch.h +0 -0
  40. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/library-config.h +0 -0
  41. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/log.h +0 -0
  42. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/profiling.h +0 -0
  43. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/aarch64-linux-musl/libdatadog-aarch64-alpine-linux-musl/include/datadog/telemetry.h +0 -0
  44. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/LICENSE +0 -0
  45. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/LICENSE-3rdparty.yml +0 -0
  46. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/NOTICE +0 -0
  47. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/bin/libdatadog-crashtracking-receiver +0 -0
  48. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/blazesym.h +0 -0
  49. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/crashtracker.h +0 -0
  50. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/data-pipeline.h +0 -0
  51. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/ddsketch.h +0 -0
  52. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/library-config.h +0 -0
  53. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/log.h +0 -0
  54. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/profiling.h +0 -0
  55. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/include/datadog/telemetry.h +0 -0
  56. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/LICENSE +0 -0
  57. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/LICENSE-3rdparty.yml +0 -0
  58. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/NOTICE +0 -0
  59. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/bin/libdatadog-crashtracking-receiver +0 -0
  60. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/include/datadog/blazesym.h +0 -0
  61. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/include/datadog/crashtracker.h +0 -0
  62. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/include/datadog/data-pipeline.h +0 -0
  63. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/include/datadog/ddsketch.h +0 -0
  64. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/include/datadog/library-config.h +0 -0
  65. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/include/datadog/log.h +0 -0
  66. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/include/datadog/profiling.h +0 -0
  67. /data/vendor/{libdatadog-24.0.0 → libdatadog-24.0.1}/x86_64-linux-musl/libdatadog-x86_64-alpine-linux-musl/include/datadog/telemetry.h +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8a7f126298f9d06e0e0bf9108632cf98972af13aa163769d0bf8783706ec7a33
4
- data.tar.gz: eb338d1859fe05794d91582000a5a903c58a05f546a7fdec61d7d92ae911e94a
3
+ metadata.gz: 90524cfcce2464a34195b507f47bee7d470fb7e7e0902ef0f0e7c3385f975f36
4
+ data.tar.gz: 74e5510e1536f7fd298a0ca57035afc53b48520e0d355793c95d6742ea4bd7ef
5
5
  SHA512:
6
- metadata.gz: d08d74c70ce5644e78f47ba1b1151633aa8fb2957d364831fda2deb1cd512c1ff112972dc8c3dcd46a1cd88244082eaa0aa487f9d8df853ee948273b2d0bc252
7
- data.tar.gz: 8a8bd8f07e40b61b3f1e292e3be6925a1617beb4588ba610084f1228edfffd2ca8fa34e22085d27afa1f155a80cb39232515900e7403c4dd4a7a7adc1eb5fb19
6
+ metadata.gz: 99b4405860385e5844c1dd92d01a16ecd4696a7bdebee65550f15e81d0cd13d272501ee580d01bcca6be20499ee52b45a81d26458cd0db58c14c648d54a6d79b
7
+ data.tar.gz: 512879456c5bc6d2a24d565158405fc27ce3e0045624ac40a1dd8c5755cb47d543c13e9dbdef80f63062b1736c7995ab5f0483817813d65dc80ef2bbf6ccd71e
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Libdatadog
4
4
  # Current libdatadog version
5
- LIB_VERSION = "24.0.0"
5
+ LIB_VERSION = "24.0.1"
6
6
 
7
7
  GEM_MAJOR_VERSION = "1"
8
8
  GEM_MINOR_VERSION = "0"
@@ -1558,6 +1558,216 @@ typedef struct ddsketch_Handle_DDSketch {
1558
1558
  struct ddsketch_DDSketch *inner;
1559
1559
  } ddsketch_Handle_DDSketch;
1560
1560
 
1561
+ typedef enum ddog_ffe_ErrorCode {
1562
+ DDOG_FFE_ERROR_CODE_OK,
1563
+ DDOG_FFE_ERROR_CODE_TYPE_MISMATCH,
1564
+ DDOG_FFE_ERROR_CODE_PARSE_ERROR,
1565
+ DDOG_FFE_ERROR_CODE_FLAG_NOT_FOUND,
1566
+ DDOG_FFE_ERROR_CODE_TARGETING_KEY_MISSING,
1567
+ DDOG_FFE_ERROR_CODE_INVALID_CONTEXT,
1568
+ DDOG_FFE_ERROR_CODE_PROVIDER_NOT_READY,
1569
+ DDOG_FFE_ERROR_CODE_GENERAL,
1570
+ } ddog_ffe_ErrorCode;
1571
+
1572
+ typedef enum ddog_ffe_ExpectedFlagType {
1573
+ DDOG_FFE_EXPECTED_FLAG_TYPE_STRING,
1574
+ DDOG_FFE_EXPECTED_FLAG_TYPE_INTEGER,
1575
+ DDOG_FFE_EXPECTED_FLAG_TYPE_FLOAT,
1576
+ DDOG_FFE_EXPECTED_FLAG_TYPE_BOOLEAN,
1577
+ DDOG_FFE_EXPECTED_FLAG_TYPE_OBJECT,
1578
+ DDOG_FFE_EXPECTED_FLAG_TYPE_NUMBER,
1579
+ DDOG_FFE_EXPECTED_FLAG_TYPE_ANY,
1580
+ } ddog_ffe_ExpectedFlagType;
1581
+
1582
+ typedef enum ddog_ffe_Reason {
1583
+ DDOG_FFE_REASON_STATIC,
1584
+ DDOG_FFE_REASON_DEFAULT,
1585
+ DDOG_FFE_REASON_TARGETING_MATCH,
1586
+ DDOG_FFE_REASON_SPLIT,
1587
+ DDOG_FFE_REASON_DISABLED,
1588
+ DDOG_FFE_REASON_ERROR,
1589
+ } ddog_ffe_Reason;
1590
+
1591
+ /**
1592
+ * Remote configuration for the feature flagging client. It's a central piece that defines client
1593
+ * behavior.
1594
+ */
1595
+ typedef struct ddog_ffe_Configuration ddog_ffe_Configuration;
1596
+
1597
+ /**
1598
+ * `Subject` is a bundle of subject attributes and a key.
1599
+ */
1600
+ typedef struct ddog_ffe_EvaluationContext ddog_ffe_EvaluationContext;
1601
+
1602
+ /**
1603
+ * Opaque type representing a result of evaluation.
1604
+ */
1605
+ typedef struct ddog_ffe_ResolutionDetails ddog_ffe_ResolutionDetails;
1606
+
1607
+ /**
1608
+ * An opaque handle for a resource. The inner fields must not be dereferenced.
1609
+ *
1610
+ * This is similar to `libdd_common_ffi::Handle` but only allows shared access to internal
1611
+ * resource, so it's safe to share between thread or access concurrently (if the underlying type
1612
+ * is).
1613
+ *
1614
+ * # Ownership
1615
+ *
1616
+ * `Handle::free()` must be called exactly once on any created Handle. Failure to do that will
1617
+ * result in a memory leak.
1618
+ */
1619
+ typedef struct ddog_ffe_ResolutionDetails *ddog_ffe_Handle_ResolutionDetails;
1620
+
1621
+ /**
1622
+ * An opaque handle for a resource. The inner fields must not be dereferenced.
1623
+ *
1624
+ * This is similar to `libdd_common_ffi::Handle` but only allows shared access to internal
1625
+ * resource, so it's safe to share between thread or access concurrently (if the underlying type
1626
+ * is).
1627
+ *
1628
+ * # Ownership
1629
+ *
1630
+ * `Handle::free()` must be called exactly once on any created Handle. Failure to do that will
1631
+ * result in a memory leak.
1632
+ */
1633
+ typedef struct ddog_ffe_Configuration *ddog_ffe_Handle_Configuration;
1634
+
1635
+ /**
1636
+ * An opaque handle for a resource. The inner fields must not be dereferenced.
1637
+ *
1638
+ * This is similar to `libdd_common_ffi::Handle` but only allows shared access to internal
1639
+ * resource, so it's safe to share between thread or access concurrently (if the underlying type
1640
+ * is).
1641
+ *
1642
+ * # Ownership
1643
+ *
1644
+ * `Handle::free()` must be called exactly once on any created Handle. Failure to do that will
1645
+ * result in a memory leak.
1646
+ */
1647
+ typedef struct ddog_ffe_EvaluationContext *ddog_ffe_Handle_EvaluationContext;
1648
+
1649
+ /**
1650
+ * A string that has been borrowed. Beware that it is NOT nul-terminated!
1651
+ *
1652
+ * # Ownership
1653
+ *
1654
+ * This string is non-owning. You must not free `ptr`.
1655
+ *
1656
+ * # Safety
1657
+ *
1658
+ * - The string is not NUL-terminated, it can only be used with API that accept the len as an
1659
+ * additional parameter.
1660
+ * - The value must not be used after the value it borrowed from has been moved, modified, or
1661
+ * freed.
1662
+ */
1663
+ typedef struct ddog_ffe_BorrowedStr {
1664
+ /**
1665
+ * May be NULL if `len` is `0`.
1666
+ */
1667
+ const uint8_t *ptr;
1668
+ uintptr_t len;
1669
+ } ddog_ffe_BorrowedStr;
1670
+
1671
+ typedef enum ddog_ffe_VariantValue_Tag {
1672
+ /**
1673
+ * Evaluation did not produce any value.
1674
+ */
1675
+ DDOG_FFE_VARIANT_VALUE_NONE,
1676
+ DDOG_FFE_VARIANT_VALUE_STRING,
1677
+ DDOG_FFE_VARIANT_VALUE_INTEGER,
1678
+ DDOG_FFE_VARIANT_VALUE_FLOAT,
1679
+ DDOG_FFE_VARIANT_VALUE_BOOLEAN,
1680
+ DDOG_FFE_VARIANT_VALUE_OBJECT,
1681
+ } ddog_ffe_VariantValue_Tag;
1682
+
1683
+ typedef struct ddog_ffe_VariantValue {
1684
+ ddog_ffe_VariantValue_Tag tag;
1685
+ union {
1686
+ struct {
1687
+ struct ddog_ffe_BorrowedStr string;
1688
+ };
1689
+ struct {
1690
+ int64_t integer;
1691
+ };
1692
+ struct {
1693
+ double float_;
1694
+ };
1695
+ struct {
1696
+ bool boolean;
1697
+ };
1698
+ struct {
1699
+ struct ddog_ffe_BorrowedStr object;
1700
+ };
1701
+ };
1702
+ } ddog_ffe_VariantValue;
1703
+
1704
+ typedef struct ddog_ffe_KeyValue_BorrowedStr {
1705
+ struct ddog_ffe_BorrowedStr key;
1706
+ struct ddog_ffe_BorrowedStr value;
1707
+ } ddog_ffe_KeyValue_BorrowedStr;
1708
+
1709
+ typedef struct ddog_ffe_ArrayMap_BorrowedStr {
1710
+ const struct ddog_ffe_KeyValue_BorrowedStr *elements;
1711
+ uintptr_t count;
1712
+ } ddog_ffe_ArrayMap_BorrowedStr;
1713
+
1714
+ /**
1715
+ * A generic result type for when an operation may fail,
1716
+ * or may return <T> in case of success.
1717
+ */
1718
+ typedef enum ddog_ffe_Result_HandleConfiguration_Tag {
1719
+ DDOG_FFE_RESULT_HANDLE_CONFIGURATION_OK_HANDLE_CONFIGURATION,
1720
+ DDOG_FFE_RESULT_HANDLE_CONFIGURATION_ERR_HANDLE_CONFIGURATION,
1721
+ } ddog_ffe_Result_HandleConfiguration_Tag;
1722
+
1723
+ typedef struct ddog_ffe_Result_HandleConfiguration {
1724
+ ddog_ffe_Result_HandleConfiguration_Tag tag;
1725
+ union {
1726
+ struct {
1727
+ ddog_ffe_Handle_Configuration ok;
1728
+ };
1729
+ struct {
1730
+ struct ddog_Error err;
1731
+ };
1732
+ };
1733
+ } ddog_ffe_Result_HandleConfiguration;
1734
+
1735
+ /**
1736
+ * # Safety
1737
+ * - `string` must be a valid C string.
1738
+ */
1739
+ typedef enum ddog_ffe_AttributeValue_Tag {
1740
+ DDOG_FFE_ATTRIBUTE_VALUE_STRING,
1741
+ DDOG_FFE_ATTRIBUTE_VALUE_NUMBER,
1742
+ DDOG_FFE_ATTRIBUTE_VALUE_BOOLEAN,
1743
+ } ddog_ffe_AttributeValue_Tag;
1744
+
1745
+ typedef struct ddog_ffe_AttributeValue {
1746
+ ddog_ffe_AttributeValue_Tag tag;
1747
+ union {
1748
+ struct {
1749
+ const char *string;
1750
+ };
1751
+ struct {
1752
+ double number;
1753
+ };
1754
+ struct {
1755
+ bool boolean;
1756
+ };
1757
+ };
1758
+ } ddog_ffe_AttributeValue;
1759
+
1760
+ /**
1761
+ * Represents a key-value pair for attributes.
1762
+ *
1763
+ * # Safety
1764
+ * - `name` must be a valid C string.
1765
+ */
1766
+ typedef struct ddog_ffe_AttributePair {
1767
+ const char *name;
1768
+ struct ddog_ffe_AttributeValue value;
1769
+ } ddog_ffe_AttributePair;
1770
+
1561
1771
  typedef enum ddog_crasht_BuildIdType {
1562
1772
  DDOG_CRASHT_BUILD_ID_TYPE_GNU,
1563
1773
  DDOG_CRASHT_BUILD_ID_TYPE_GO,
@@ -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 */
@@ -8,7 +8,7 @@ includedir=${prefix}/include
8
8
 
9
9
  Name: datadog_profiling
10
10
  Description: Contains common code used to implement Datadog's Continuous Profilers. (Dynamic linking variant, sets rpath)
11
- Version: 24.0.0
11
+ Version: 24.0.1
12
12
  Requires:
13
13
  Libs: -L${libdir} -ldatadog_profiling -Wl,-rpath,${libdir}
14
14
  Libs.private:
@@ -1558,6 +1558,216 @@ typedef struct ddsketch_Handle_DDSketch {
1558
1558
  struct ddsketch_DDSketch *inner;
1559
1559
  } ddsketch_Handle_DDSketch;
1560
1560
 
1561
+ typedef enum ddog_ffe_ErrorCode {
1562
+ DDOG_FFE_ERROR_CODE_OK,
1563
+ DDOG_FFE_ERROR_CODE_TYPE_MISMATCH,
1564
+ DDOG_FFE_ERROR_CODE_PARSE_ERROR,
1565
+ DDOG_FFE_ERROR_CODE_FLAG_NOT_FOUND,
1566
+ DDOG_FFE_ERROR_CODE_TARGETING_KEY_MISSING,
1567
+ DDOG_FFE_ERROR_CODE_INVALID_CONTEXT,
1568
+ DDOG_FFE_ERROR_CODE_PROVIDER_NOT_READY,
1569
+ DDOG_FFE_ERROR_CODE_GENERAL,
1570
+ } ddog_ffe_ErrorCode;
1571
+
1572
+ typedef enum ddog_ffe_ExpectedFlagType {
1573
+ DDOG_FFE_EXPECTED_FLAG_TYPE_STRING,
1574
+ DDOG_FFE_EXPECTED_FLAG_TYPE_INTEGER,
1575
+ DDOG_FFE_EXPECTED_FLAG_TYPE_FLOAT,
1576
+ DDOG_FFE_EXPECTED_FLAG_TYPE_BOOLEAN,
1577
+ DDOG_FFE_EXPECTED_FLAG_TYPE_OBJECT,
1578
+ DDOG_FFE_EXPECTED_FLAG_TYPE_NUMBER,
1579
+ DDOG_FFE_EXPECTED_FLAG_TYPE_ANY,
1580
+ } ddog_ffe_ExpectedFlagType;
1581
+
1582
+ typedef enum ddog_ffe_Reason {
1583
+ DDOG_FFE_REASON_STATIC,
1584
+ DDOG_FFE_REASON_DEFAULT,
1585
+ DDOG_FFE_REASON_TARGETING_MATCH,
1586
+ DDOG_FFE_REASON_SPLIT,
1587
+ DDOG_FFE_REASON_DISABLED,
1588
+ DDOG_FFE_REASON_ERROR,
1589
+ } ddog_ffe_Reason;
1590
+
1591
+ /**
1592
+ * Remote configuration for the feature flagging client. It's a central piece that defines client
1593
+ * behavior.
1594
+ */
1595
+ typedef struct ddog_ffe_Configuration ddog_ffe_Configuration;
1596
+
1597
+ /**
1598
+ * `Subject` is a bundle of subject attributes and a key.
1599
+ */
1600
+ typedef struct ddog_ffe_EvaluationContext ddog_ffe_EvaluationContext;
1601
+
1602
+ /**
1603
+ * Opaque type representing a result of evaluation.
1604
+ */
1605
+ typedef struct ddog_ffe_ResolutionDetails ddog_ffe_ResolutionDetails;
1606
+
1607
+ /**
1608
+ * An opaque handle for a resource. The inner fields must not be dereferenced.
1609
+ *
1610
+ * This is similar to `libdd_common_ffi::Handle` but only allows shared access to internal
1611
+ * resource, so it's safe to share between thread or access concurrently (if the underlying type
1612
+ * is).
1613
+ *
1614
+ * # Ownership
1615
+ *
1616
+ * `Handle::free()` must be called exactly once on any created Handle. Failure to do that will
1617
+ * result in a memory leak.
1618
+ */
1619
+ typedef struct ddog_ffe_ResolutionDetails *ddog_ffe_Handle_ResolutionDetails;
1620
+
1621
+ /**
1622
+ * An opaque handle for a resource. The inner fields must not be dereferenced.
1623
+ *
1624
+ * This is similar to `libdd_common_ffi::Handle` but only allows shared access to internal
1625
+ * resource, so it's safe to share between thread or access concurrently (if the underlying type
1626
+ * is).
1627
+ *
1628
+ * # Ownership
1629
+ *
1630
+ * `Handle::free()` must be called exactly once on any created Handle. Failure to do that will
1631
+ * result in a memory leak.
1632
+ */
1633
+ typedef struct ddog_ffe_Configuration *ddog_ffe_Handle_Configuration;
1634
+
1635
+ /**
1636
+ * An opaque handle for a resource. The inner fields must not be dereferenced.
1637
+ *
1638
+ * This is similar to `libdd_common_ffi::Handle` but only allows shared access to internal
1639
+ * resource, so it's safe to share between thread or access concurrently (if the underlying type
1640
+ * is).
1641
+ *
1642
+ * # Ownership
1643
+ *
1644
+ * `Handle::free()` must be called exactly once on any created Handle. Failure to do that will
1645
+ * result in a memory leak.
1646
+ */
1647
+ typedef struct ddog_ffe_EvaluationContext *ddog_ffe_Handle_EvaluationContext;
1648
+
1649
+ /**
1650
+ * A string that has been borrowed. Beware that it is NOT nul-terminated!
1651
+ *
1652
+ * # Ownership
1653
+ *
1654
+ * This string is non-owning. You must not free `ptr`.
1655
+ *
1656
+ * # Safety
1657
+ *
1658
+ * - The string is not NUL-terminated, it can only be used with API that accept the len as an
1659
+ * additional parameter.
1660
+ * - The value must not be used after the value it borrowed from has been moved, modified, or
1661
+ * freed.
1662
+ */
1663
+ typedef struct ddog_ffe_BorrowedStr {
1664
+ /**
1665
+ * May be NULL if `len` is `0`.
1666
+ */
1667
+ const uint8_t *ptr;
1668
+ uintptr_t len;
1669
+ } ddog_ffe_BorrowedStr;
1670
+
1671
+ typedef enum ddog_ffe_VariantValue_Tag {
1672
+ /**
1673
+ * Evaluation did not produce any value.
1674
+ */
1675
+ DDOG_FFE_VARIANT_VALUE_NONE,
1676
+ DDOG_FFE_VARIANT_VALUE_STRING,
1677
+ DDOG_FFE_VARIANT_VALUE_INTEGER,
1678
+ DDOG_FFE_VARIANT_VALUE_FLOAT,
1679
+ DDOG_FFE_VARIANT_VALUE_BOOLEAN,
1680
+ DDOG_FFE_VARIANT_VALUE_OBJECT,
1681
+ } ddog_ffe_VariantValue_Tag;
1682
+
1683
+ typedef struct ddog_ffe_VariantValue {
1684
+ ddog_ffe_VariantValue_Tag tag;
1685
+ union {
1686
+ struct {
1687
+ struct ddog_ffe_BorrowedStr string;
1688
+ };
1689
+ struct {
1690
+ int64_t integer;
1691
+ };
1692
+ struct {
1693
+ double float_;
1694
+ };
1695
+ struct {
1696
+ bool boolean;
1697
+ };
1698
+ struct {
1699
+ struct ddog_ffe_BorrowedStr object;
1700
+ };
1701
+ };
1702
+ } ddog_ffe_VariantValue;
1703
+
1704
+ typedef struct ddog_ffe_KeyValue_BorrowedStr {
1705
+ struct ddog_ffe_BorrowedStr key;
1706
+ struct ddog_ffe_BorrowedStr value;
1707
+ } ddog_ffe_KeyValue_BorrowedStr;
1708
+
1709
+ typedef struct ddog_ffe_ArrayMap_BorrowedStr {
1710
+ const struct ddog_ffe_KeyValue_BorrowedStr *elements;
1711
+ uintptr_t count;
1712
+ } ddog_ffe_ArrayMap_BorrowedStr;
1713
+
1714
+ /**
1715
+ * A generic result type for when an operation may fail,
1716
+ * or may return <T> in case of success.
1717
+ */
1718
+ typedef enum ddog_ffe_Result_HandleConfiguration_Tag {
1719
+ DDOG_FFE_RESULT_HANDLE_CONFIGURATION_OK_HANDLE_CONFIGURATION,
1720
+ DDOG_FFE_RESULT_HANDLE_CONFIGURATION_ERR_HANDLE_CONFIGURATION,
1721
+ } ddog_ffe_Result_HandleConfiguration_Tag;
1722
+
1723
+ typedef struct ddog_ffe_Result_HandleConfiguration {
1724
+ ddog_ffe_Result_HandleConfiguration_Tag tag;
1725
+ union {
1726
+ struct {
1727
+ ddog_ffe_Handle_Configuration ok;
1728
+ };
1729
+ struct {
1730
+ struct ddog_Error err;
1731
+ };
1732
+ };
1733
+ } ddog_ffe_Result_HandleConfiguration;
1734
+
1735
+ /**
1736
+ * # Safety
1737
+ * - `string` must be a valid C string.
1738
+ */
1739
+ typedef enum ddog_ffe_AttributeValue_Tag {
1740
+ DDOG_FFE_ATTRIBUTE_VALUE_STRING,
1741
+ DDOG_FFE_ATTRIBUTE_VALUE_NUMBER,
1742
+ DDOG_FFE_ATTRIBUTE_VALUE_BOOLEAN,
1743
+ } ddog_ffe_AttributeValue_Tag;
1744
+
1745
+ typedef struct ddog_ffe_AttributeValue {
1746
+ ddog_ffe_AttributeValue_Tag tag;
1747
+ union {
1748
+ struct {
1749
+ const char *string;
1750
+ };
1751
+ struct {
1752
+ double number;
1753
+ };
1754
+ struct {
1755
+ bool boolean;
1756
+ };
1757
+ };
1758
+ } ddog_ffe_AttributeValue;
1759
+
1760
+ /**
1761
+ * Represents a key-value pair for attributes.
1762
+ *
1763
+ * # Safety
1764
+ * - `name` must be a valid C string.
1765
+ */
1766
+ typedef struct ddog_ffe_AttributePair {
1767
+ const char *name;
1768
+ struct ddog_ffe_AttributeValue value;
1769
+ } ddog_ffe_AttributePair;
1770
+
1561
1771
  typedef enum ddog_crasht_BuildIdType {
1562
1772
  DDOG_CRASHT_BUILD_ID_TYPE_GNU,
1563
1773
  DDOG_CRASHT_BUILD_ID_TYPE_GO,