Hi all
I have a question. Plugins themselves are sperated by default from Jira and from other plugins. As far as I understand, only the plugin can access to Jira or to Plugins which are explicitly imported.
Now, i have this singleton in my plugin. This plugins contains a list of elements, which shall be consumed by a scheduled service. But i can't get this singleton instance which has already been created by the plugin. The service creates its own instance, which is... not good (from my view)
Does anybody have any hint how to work around this case, or just make this singleton accessible for the Scheduler? I don't want to implement my own Scheduler, since there could appear other problems when disabling the plugins or stuff.
Anybody?
Thx a lot!!
cheers muealle
If you write a V1 plugin, all plugins and JIRA live in the same "world" from a ClassLoader's point of view. You can access classes as you wish then.
When using a V2 plugin, all plugins are enclosed in an OSGi bundle that shields the plugin from other plugins. Using singletons is generally a bad idea but may work as a quick solution.
I would suggest to:
Yeah, it's actually a V2 plugin. But there was another problem apparently. The good news is, it works know. Don't know really why. The acces from scheduler to the plugin is now possible without a hassle.
Thanks for your reply anyway!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.