(ctx context.Context, source string)
| 10 | ) |
| 11 | |
| 12 | func ContextWithRequestSource(ctx context.Context, source string) context.Context { |
| 13 | metadataMap := MapFromContext(ctx) |
| 14 | if metadataMap == nil { |
| 15 | metadataMap = make(map[string]string) |
| 16 | } |
| 17 | metadataMap[RequestSourceKey] = source |
| 18 | return ContextWithRequestMetadataMap(ctx, metadataMap) |
| 19 | } |
| 20 | |
| 21 | func RequestFromRuler(ctx context.Context) bool { |
| 22 | metadataMap := MapFromContext(ctx) |