Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[o11y] Add KV span tags #3261

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

fhanau
Copy link
Collaborator

@fhanau fhanau commented Dec 20, 2024

#3256 needs to land first.

@fhanau fhanau requested a review from mikea December 20, 2024 01:25
@fhanau fhanau requested review from a team as code owners December 20, 2024 01:25
@fhanau fhanau force-pushed the felix/subrequest-client-spans-kv branch from 04c7f43 to 076a736 Compare December 20, 2024 01:31
jsg::Optional<kj::OneOf<kj::String, GetOptions>> options,
CompatibilityFlags::Reader flags) {
jsg::Promise<KvNamespace::GetResult> KvNamespace::get(
jsg::Lock& js, kj::String name, jsg::Optional<kj::OneOf<kj::String, GetOptions>> options) {
return js.evalNow([&] {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Not entirely sure if I'm handling async behavior correctly here? With the get/getWithMetadata implementation being moved to getWithMetadataImpl(), is the js.evalNow() closure still needed here? Should there be one added to getWithMetadata()?

js.evalNow

jsg::Promise<GetResult> get(jsg::Lock& js,
kj::String name,
jsg::Optional<kj::OneOf<kj::String, GetOptions>> options,
CompatibilityFlags::Reader flags);
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Minor cleanup: compat flags parameter is not needed here, that should simplify the generated code slightly.

@fhanau fhanau force-pushed the felix/subrequest-client-spans-kv branch from 076a736 to 0d0a53f Compare December 20, 2024 15:59
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.

1 participant