[GH-ISSUE #594] [FEATURE REQUEST] Do you consider to return the whole metadata struct? #291

Closed
opened 2026-03-02 05:20:13 +03:00 by kerem · 1 comment
Owner

Originally created by @VolunPotest on GitHub (Dec 29, 2022).
Original GitHub issue: https://github.com/hibiken/asynq/issues/594

Originally assigned to: @hibiken on GitHub.

Hi. Thank you for the response for the previous issue.

Do you consider returning the whole metadata struct?
Something like this?

// GetMetadata extracts metadata from a context, if any.
func GetMetadata(ctx context.Context) (metadata taskMetadata, ok bool) {
metadata, ok = ctx.Value(metadataCtxKey).(taskMetadata)
return
}

Thank you

Originally created by @VolunPotest on GitHub (Dec 29, 2022). Original GitHub issue: https://github.com/hibiken/asynq/issues/594 Originally assigned to: @hibiken on GitHub. Hi. Thank you for the response for the previous issue. Do you consider returning the whole metadata struct? Something like this? // GetMetadata extracts metadata from a context, if any. func GetMetadata(ctx context.Context) (metadata taskMetadata, ok bool) { metadata, ok = ctx.Value(metadataCtxKey).(taskMetadata) return } Thank you
kerem 2026-03-02 05:20:13 +03:00
Author
Owner

@hibiken commented on GitHub (Jan 2, 2023):

At this point, I don't have a plan to expose the whole task metadata.

Let me know if you have a specific use case for this.

<!-- gh-comment-id:1369259388 --> @hibiken commented on GitHub (Jan 2, 2023): At this point, I don't have a plan to expose the whole task metadata. Let me know if you have a specific use case for this.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
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
starred/asynq#291
No description provided.