-
Notifications
You must be signed in to change notification settings - Fork 213
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Plugin metrics injection #5372
base: main
Are you sure you want to change the base?
Plugin metrics injection #5372
Conversation
Signed-off-by: Santhosh Gandhe <[email protected]>
Signed-off-by: Santhosh Gandhe <[email protected]>
Signed-off-by: Santhosh Gandhe <[email protected]>
beanFactory.registerSingleton(configuration.getClass().getName(), configuration); | ||
} | ||
if (pluginSetting != null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would this change allow us to remove the following line without breaking existing code?
Line 50 in 7cbfb0a
typedArgumentsSuppliers.put(PluginMetrics.class, () -> PluginMetrics.fromPluginSetting(builder.pluginSetting)); |
Also, at a high-level, can we consolidate these completely?
*/ | ||
public BeanFactory createPluginSpecificContext(Class[] markersToScan, Object configuration) { | ||
public BeanFactory createPluginSpecificContext(Class[] markersToScan, Object configuration, final PluginSetting pluginSetting) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change resulted in a lot of other changes. This indicates that we should have a class to handle these parameters. We actually already have something similar in the ComponentPluginArgumentsContext
. I think consolidating this will help clean up the code. See my other comment below.
Description
Making the PluginMetrics as an injectable bean so that we can simply inject this bean in any other spring bean.
Also, clean up some unused variables in Jira source.
Fixed a flaky test in Otel trace processor
Issues Resolved
Resolves #[Issue number to be closed when this PR is merged]
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.