Skip to content

Conversation

@duncanpharvey
Copy link
Collaborator

@duncanpharvey duncanpharvey commented May 6, 2025

What does this PR do?

Enable default datadog-fips features from dogstatsd.

Motivation

Error when building datadog-serverless-compat without the reqwest/rustls-tls feature:

default = [ "reqwest/rustls-tls" ]

serverless-components % sudo RUSTFLAGS="-C linker=x86_64-linux-musl-gcc" cargo build --release -p datadog-serverless-compat --target x86_64-unknown-linux-musl
   Compiling datadog-fips v0.1.0 (/Users/duncan.harvey/go/src/github.com/DataDog/serverless-components/crates/datadog-fips)
error[E0599]: no method named `use_rustls_tls` found for struct `ClientBuilder` in the current scope
  --> crates/datadog-fips/src/reqwest_adapter.rs:14:35
   |
14 |     Ok(reqwest::Client::builder().use_rustls_tls())
   |                                   ^^^^^^^^^^^^^^ method not found in `ClientBuilder`

For more information about this error, try `rustc --explain E0599`.
error: could not compile `datadog-fips` (lib) due to 1 previous error

Additional Notes

  • Skip ubuntu-24.04-arm build for Datadog Serverless Compat since this architecture is not supported by Azure Functions or Google Cloud Run Functions at this time
  • Set fail-fast to false for Github Actions to false to allow for all jobs to run independently of other failures.

Describe how to test/QA your changes

Added build step for datadog-serverless-compat to CI to catch build errors in the future.

@duncanpharvey duncanpharvey force-pushed the duncan-harvey/dogstatsd-datadog-fips-default-features branch from f39a2b5 to 0826e48 Compare May 6, 2025 01:38
@duncanpharvey duncanpharvey marked this pull request as ready for review May 6, 2025 14:33
regex = { version = "1.10.6", default-features = false }
zstd = { version = "0.13.3", default-features = false }
datadog-fips = { path = "../datadog-fips", default-features = false }
datadog-fips = { path = "../datadog-fips", default-features = true }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this may be incorrect. we may need to select which features to include, default or not default. i'd say if you need the default feature from datadog-fips it would be better to add it to the default feature list on line 35 below

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about setting the default features from datadog-serverless-compat?

dogstatsd = { path = "../dogstatsd", default-features = true }

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah, that shouldn't mess with bottlecap, i think. seems fine from that perspective.

Copy link
Contributor

@apiarian-datadog apiarian-datadog left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks fine from the bottlecaps and fips-ish perspective

@duncanpharvey duncanpharvey merged commit 4223ebe into main May 6, 2025
22 checks passed
@duncanpharvey duncanpharvey deleted the duncan-harvey/dogstatsd-datadog-fips-default-features branch May 6, 2025 17:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants