You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When constructing a new DataDog client with this method, I noticed that if the call to dial fails the error is only logged. Returning the error would let callers take specific actions during their application's initialization.
I realize this proposal is a breaking change; if you all think this is a good idea I would be willing to create the patch!
The text was updated successfully, but these errors were encountered:
For context, this has never really been an issue because it's pretty easy to spot when metrics just don't work.
If this is a feature you need we can introduce a new function that constructs the client but also returns any error that it would observe (NewClientWithError?), I don't think we have to make it a breaking change.
Makes sense, and yes, something like NewClientWithError would work.
Specifically, I'm instrumenting a business critical service and want to have the option to not spin it up if initialization fails (e.g. bad addr, an internal error making the sys calls, etc)
When constructing a new DataDog client with this method, I noticed that if the call to
dial
fails the error is only logged. Returning the error would let callers take specific actions during their application's initialization.I realize this proposal is a breaking change; if you all think this is a good idea I would be willing to create the patch!
The text was updated successfully, but these errors were encountered: