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
We should improve our instrumentation wrappers to reduce the required amount of boilerplate per project.
The end-goal is to drive the instrumentations towards a more declarative approach, as much as possible. There will always be exceptions, so the solution also needs to be flexible with this.
🎤 Why is this feature needed ?
Less maintenance overhead.
✌️ How do you aim to achieve this?
We'll need to write some custom tooling for this.
In the weaviate instrumentation PR, I wrote some simple classes to reduce boilerplate, for instance:
We could try and take this further. Python offers an amazing introspection module in the standard library (inspect), so in theory just by passing the function name we should be able to automatically extract all arguments. That should be the default way to instrument methods.
Using such resources, we can then simply map in a declarative way most of the standard objects / functions, like we already do:
Which component is this feature for?
All Packages
🔖 Feature description
We should improve our instrumentation wrappers to reduce the required amount of boilerplate per project.
The end-goal is to drive the instrumentations towards a more declarative approach, as much as possible. There will always be exceptions, so the solution also needs to be flexible with this.
🎤 Why is this feature needed ?
Less maintenance overhead.
✌️ How do you aim to achieve this?
We'll need to write some custom tooling for this.
In the weaviate instrumentation PR, I wrote some simple classes to reduce boilerplate, for instance:
We could try and take this further. Python offers an amazing introspection module in the standard library (
inspect
), so in theory just by passing the function name we should be able to automatically extract all arguments. That should be the default way to instrument methods.Using such resources, we can then simply map in a declarative way most of the standard objects / functions, like we already do:
But without the need to explicitly add calls to set span attributes, as our instrumentation tooling should automatically take care of that:
🔄️ Additional Information
No response
👀 Have you spent some time to check if this feature request has been raised before?
Are you willing to submit PR?
Yes I am willing to submit a PR!
The text was updated successfully, but these errors were encountered: