-
Notifications
You must be signed in to change notification settings - Fork 739
[C++ SDK] Fixed missing headers in stream request #30245
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
Conversation
|
🟢 |
|
⚪ ⚪ Ya make output | Test bloat | Test bloat
🟢
*please be aware that the difference is based on comparing your commit and the last completed build from the post-commit, check comparation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR refactors authentication and metadata handling for gRPC requests in the C++ SDK. It introduces a new TAuthenticationError exception type to distinguish authentication failures from general contract violations, and consolidates duplicate metadata creation logic into a centralized MakeCallMeta method. The PR also adds support for OpenTelemetry trace context propagation via the TraceParent field.
Key changes:
- Introduced
TAuthenticationErrorexception class for authentication-specific errors - Refactored duplicated metadata creation logic into
TGRpcConnectionsImpl::MakeCallMeta() - Added
TraceParentfield toTRpcRequestSettingsfor OpenTelemetry trace context support
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| ydb/public/sdk/cpp/include/ydb-cpp-sdk/client/types/exceptions/exceptions.h | Adds new TAuthenticationError exception class declaration |
| ydb/public/sdk/cpp/src/client/types/exceptions/exceptions.cpp | Implements constructor for TAuthenticationError |
| ydb/public/sdk/cpp/src/client/impl/internal/rpc_request_settings/settings.h | Adds TraceParent field and removes inline header insertion logic |
| ydb/public/sdk/cpp/src/client/impl/internal/grpc_connections/grpc_connections.h | Refactors three methods to use centralized MakeCallMeta() and catch TAuthenticationError (missing required include) |
| ydb/public/sdk/cpp/src/client/impl/internal/grpc_connections/grpc_connections.cpp | Implements MakeCallMeta() method with TraceParent support and updates GetAuthInfo() error handling |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
ydb/public/sdk/cpp/src/client/impl/internal/grpc_connections/grpc_connections.h
Show resolved
Hide resolved
| } catch (const TAuthenticationError& e) { | ||
| throw e; |
Copilot
AI
Dec 5, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The catch block for TAuthenticationError at lines 25-26 is redundant. It catches the exception only to immediately rethrow it unchanged. This block can be removed since the exception will naturally propagate without it, simplifying the code.
| } catch (const TAuthenticationError& e) { | |
| throw e; |
|
⚪
🟢
*please be aware that the difference is based on comparing your commit and the last completed build from the post-commit, check comparation |
Changelog entry
...
Changelog category
Description for reviewers
...