kragent66-glitch commented on issue #27038:
URL: https://github.com/apache/beam/issues/27038#issuecomment-5503264813

   Hi @lostluck, after investigating, I found that this issue is related to the 
Setup() method not receiving the bundle context when it doesn't accept a 
context.Context argument. I've written a test case that confirms if Setup(ctx 
context.Context) is used, the metric is correctly captured. If the user uses 
Setup() without context and passes context.Background() to the metric API, the 
metric is correctly (but perhaps unexpectedly) dropped because 
context.Background() has no counter set. I'll provide a PR with a test case to 
clarify this convention.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to