rgw/tracing: end to end trace for multipart upload #47370
rgw/tracing: end to end trace for multipart upload #47370
Conversation
new o-tel trace added for the message header, and encode/decode it for MSOD op Signed-off-by: Omri Zeneva <ozeneva@redhat.com>
in order to propagate the trace info I added the otel-trace as an extra param. in some places, there already was a blkin trace info, and since it is not used in other places we can safely change it to o-tel trace info. Signed-off-by: Omri Zeneva <ozeneva@redhat.com>
… aio_opearte in order to make it possible, I saved the trace info inside the sal::Object, so we can use it later when writing the object to rados it could be used also later for read ops Signed-off-by: Omri Zeneva <ozeneva@redhat.com>
Signed-off-by: Omri Zeneva <ozeneva@redhat.com>
… of the span Signed-off-by: Omri Zeneva <ozeneva@redhat.com>
Signed-off-by: Omri Zeneva <ozeneva@redhat.com>
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
src/rgw/rgw_op.cc
Outdated
|
|
||
| s->trace->SetAttribute(tracing::rgw::UPLOAD_ID, multipart_upload_id); | ||
| multipart_trace = tracing::rgw::tracer.add_span(name(), upload->get_trace()); | ||
| s->object->set_trace(multipart_trace->GetContext()); |
There was a problem hiding this comment.
lets start from regular object trace. please move out of the "if multipart" block, and set the regular trace as its parent
| reqid.name._num, reqid.tid, reqid.inc); | ||
| } | ||
| op->osd_parent_span = tracing::osd::tracer.start_trace("op-request-created"); | ||
| op->osd_parent_span = tracing::osd::tracer.add_span("op-request-created", m->otel_trace); |
There was a problem hiding this comment.
please keep current behavior. if m->otel_trace is null, just start a new trace
| ::ObjectOperation *o, AioCompletionImpl *c, | ||
| const SnapContext& snap_context, int flags, | ||
| const blkin_trace_info *trace_info) | ||
| const jspan_context *trace_info) |
There was a problem hiding this comment.
please keep blkin until we deprecate it completely
| int aio_operate(const object_t& oid, ::ObjectOperation *o, | ||
| AioCompletionImpl *c, const SnapContext& snap_context, | ||
| int flags, const blkin_trace_info *trace_info = nullptr); | ||
| int flags, const jspan_context *trace_info = nullptr); |
There was a problem hiding this comment.
assume you mean we can add the jspan_context, but leave blkin for later removal? I don't want us to have to do an unsafe cast to/from a blkin pointer type
There was a problem hiding this comment.
removing blkin separately somehow feels cleaner, but at the same time, I've confirmed with core that blkin can be unceremoniously removed, just saying
There was a problem hiding this comment.
assume you mean we can add the jspan_context, but leave blkin for later removal? I don't want us to have to do an unsafe cast to/from a blkin pointer type
agree. lets add another function (for now)
removing blkin separately somehow feels cleaner, but at the same time, I've confirmed with core that blkin can be unceremoniously removed, just saying
yes, buts lets remove that in a separate commit, including the removal of all functions that use it, remove it from the git submodules or OS dependencies, make etc.
the only place we should keep it (or a place holder of it) is the wire protocol, so we won't crash if someone sends a message with a blkin trace.
…putobj operations this commit also include changes for the librados interfaces to support the otel trace info Signed-off-by: Omri Zeneva <ozeneva@redhat.com>
|
|
||
| rgw_placement_rule *pdest_placement = &s->dest_placement; | ||
|
|
||
| s->object->set_trace(s->trace->GetContext()); |
There was a problem hiding this comment.
this scenario is not possible. s->trace is initialized unconditionally before the op execution(in rgw_process.cc)
in case we compile with WITH_JAEGER=OFF then s->trace won't be a ptr, but a stub struct (with -> overloading)
|
thank for the review. I will open a new PR with the right new branch name (trace for Put op instead of Multipart) |
The goal of this PR is to unify the trace created for MP upload in the RGW and the subsequent spans created for the same operation in OSDs
Librados already had the blkin_trace_info in some places, but this tracing system isn't used either in RGW or OSD, so we can replace it with open-telemetry trace information.
The blkin trace needs to be removed from all over the place. It needs to be kept for another PR to simplify the current changes made for end-to-end MP tracing.
Screenshot of how the MP trace looks like after this change:
Checklist
Show available Jenkins commands
jenkins retest this pleasejenkins test classic perfjenkins test crimson perfjenkins test signedjenkins test make checkjenkins test make check arm64jenkins test submodulesjenkins test dashboardjenkins test dashboard cephadmjenkins test apijenkins test docsjenkins render docsjenkins test ceph-volume alljenkins test ceph-volume toxjenkins test windows