Add tracing spans to PUT, DELETE requests and tree service #242

Merged
fyrchik merged 3 commits from dstepanov-yadro/frostfs-node:tracing/put into master 2023-04-14 10:25:55 +00:00
  1. Added tracing to put, delete, search requests.
  2. Added tracing to tree service operations.
  3. Reverted commits with tracing for check ACL and signature operations: there were many such traces, but they did not carry a payload.

I apologize for one large commit: after adding context to one func, linter started issuing that it was necessary to use context in calling func, so it turned out that everything had to be done in one commit.

1. Added tracing to put, delete, search requests. 2. Added tracing to tree service operations. 3. Reverted commits with tracing for check ACL and signature operations: there were many such traces, but they did not carry a payload. I apologize for one large commit: after adding `context` to one func, linter started issuing that it was necessary to use `context` in calling func, so it turned out that everything had to be done in one commit.
dstepanov-yadro force-pushed tracing/put from 5720755e64 to 89b0c6ce4a 2023-04-12 14:33:32 +00:00 Compare
dstepanov-yadro force-pushed tracing/put from 207d65db44 to 1a65c7e64f 2023-04-13 12:39:16 +00:00 Compare
dstepanov-yadro changed title from WIP: Add tracing spans to PUT, DELETE requests and tree service to Add tracing spans to PUT, DELETE requests and tree service 2023-04-13 12:54:39 +00:00
dstepanov-yadro requested review from storage-core-committers 2023-04-13 12:54:45 +00:00
dstepanov-yadro requested review from storage-core-developers 2023-04-13 12:54:45 +00:00
ale64bit requested changes 2023-04-13 14:08:20 +00:00
@ -48,6 +48,12 @@ func (r GetRes) Object() *objectSDK.Object {
//
// Returns an error if executions are blocked (see BlockExecution).
func (e *StorageEngine) Get(ctx context.Context, prm GetPrm) (res GetRes, err error) {
ctx, span := tracing.StartSpanFromContext(ctx, "StorageEngine.get",
Collaborator

s/get/Get

s/get/Get
Poster
Collaborator

fixed

fixed
ale64bit marked this conversation as resolved
@ -182,2 +265,3 @@
// TreeList implements the pilorama.Forest interface.
func (e *StorageEngine) TreeList(cid cidSDK.ID) ([]string, error) {
func (e *StorageEngine) TreeList(ctx context.Context, cid cidSDK.ID) ([]string, error) {
ctx, span := tracing.StartSpanFromContext(ctx, "StorageEngine.TreeDrop",
Collaborator

s/TreeDrop/TreeList

s/TreeDrop/TreeList
Poster
Collaborator

fixed

fixed
ale64bit marked this conversation as resolved
@ -402,6 +403,9 @@ func (x PutObjectRes) ID() oid.ID {
//
// Returns any error which prevented the operation from completing correctly in error return.
func PutObject(ctx context.Context, prm PutObjectPrm) (*PutObjectRes, error) {
ctx, span := tracing.StartSpanFromContext(ctx, "client.Put")
Collaborator

s/Put/PutObject

s/Put/PutObject
Poster
Collaborator

fixed

fixed
ale64bit marked this conversation as resolved
Collaborator

You should apologize to forgejo instead; it can barely handle it :)

You should apologize to forgejo instead; it can barely handle it :)
dstepanov-yadro force-pushed tracing/put from 1a65c7e64f to 952f5fe5ee 2023-04-13 14:21:19 +00:00 Compare
ale64bit approved these changes 2023-04-13 14:24:42 +00:00
acid-ant approved these changes 2023-04-13 15:07:00 +00:00
dstepanov-yadro force-pushed tracing/put from 952f5fe5ee to 941e8cde03 2023-04-14 06:55:34 +00:00 Compare
fyrchik approved these changes 2023-04-14 10:25:46 +00:00
fyrchik merged commit 6121b541b5 into master 2023-04-14 10:25:55 +00:00
Sign in to join this conversation.
No reviewers
No Milestone
No Assignees
4 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: TrueCloudLab/frostfs-node#242
There is no content yet.