It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Changing the mysql scope (from provided to compile) causes plugin binding error. How do I fix? Edited

I get this error (and don't see my plugin anymore) when mysql scope is changed to compile:

[INFO] [talledLocalContainer] 2020-01-22 14:42:56,521 localhost-startStop-1 ERROR [c.a.p.osgi.factory.OsgiPluginInstalledHelper] Cannot determine required plugins, cannot resolve bundle 'com.dataguardian.timetracking'
[INFO] [talledLocalContainer] 2020-01-22 14:42:56,521 localhost-startStop-1 ERROR [c.a.p.osgi.factory.OsgiPluginInstalledHelper] Cannot determine required plugins, cannot resolve bundle 'com.dataguardian.timetracking.timetracking-tests'

<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>5.1.48</version>
<scope>compile</scope>
</dependency>

 

Some of my LogFile:

[INFO] [talledLocalContainer] 2020-01-22 14:42:58,833 localhost-startStop-1 ERROR [c.a.p.osgi.factory.OsgiPlugin] Detected an error (BundleException) enabling the plugin 'com.dataguardian.timetracking.timetracking' : Unresolved constraint in bundle com.dataguardian.timetracking [177]: Unable to resolve 177.0: missing requirement [177.0] osgi.wiring.package; (osgi.wiring.package=com.mchange.v2.c3p0). This error usually occurs when your plugin imports a package from another bundle with a specific version constraint and either the bundle providing that package doesn't meet those version constraints, or there is no bundle available that provides the specified package. For more details on how to fix this, see https://developer.atlassian.com/x/mQAN
[INFO] [talledLocalContainer] 2020-01-22 14:42:58,833 localhost-startStop-1 WARN [c.a.plugin.impl.AbstractPlugin] Unable to enable plugin 'com.dataguardian.timetracking.timetracking'
[INFO] [talledLocalContainer] 2020-01-22 14:42:58,833 localhost-startStop-1 WARN [c.a.plugin.impl.AbstractPlugin] Because of this exception
[INFO] [talledLocalContainer] com.atlassian.plugin.osgi.container.OsgiContainerException: Cannot start plugin: com.dataguardian.timetracking.timetracking
[INFO] [talledLocalContainer] at com.atlassian.plugin.osgi.factory.OsgiPlugin.enableInternal(OsgiPlugin.java:418)
[INFO] [talledLocalContainer] at com.atlassian.plugin.impl.AbstractPlugin.enable(AbstractPlugin.java:287)
[INFO] [talledLocalContainer] at com.atlassian.plugin.manager.PluginEnabler.actualEnable(PluginEnabler.java:130)
[INFO] [talledLocalContainer] at com.atlassian.plugin.manager.PluginEnabler.enable(PluginEnabler.java:107)
[INFO] [talledLocalContainer] at com.atlassian.plugin.manager.DefaultPluginManager.enableDependentPlugins(DefaultPluginManager.java:1248)
[INFO] [talledLocalContainer] at com.atlassian.plugin.manager.DefaultPluginManager.addPlugins(DefaultPluginManager.java:1218)
[INFO] [talledLocalContainer] at com.atlassian.jira.plugin.JiraPluginManager.addPlugins(JiraPluginManager.java:165)
[INFO] [talledLocalContainer] at com.atlassian.plugin.manager.DefaultPluginManager.earlyStartup(DefaultPluginManager.java:597)
[INFO] [talledLocalContainer] at com.atlassian.jira.plugin.JiraPluginManager.earlyStartup(JiraPluginManager.java:125)
[INFO] [talledLocalContainer] at com.atlassian.jira.component.pico.ComponentManager$PluginSystem.earlyStartup(ComponentManager.java:781)
[INFO] [talledLocalContainer] at com.atlassian.jira.component.pico.ComponentManager.quickStart(ComponentManager.java:213)
[INFO] [talledLocalContainer] at com.atlassian.jira.component.pico.ComponentManager.start(ComponentManager.java:182)
[INFO] [talledLocalContainer] at com.atlassian.jira.upgrade.PluginSystemLauncher.start(PluginSystemLauncher.java:45)
[INFO] [talledLocalContainer] at com.atlassian.jira.startup.DefaultJiraLauncher.lambda$postDbLaunch$2(DefaultJiraLauncher.java:143)
[INFO] [talledLocalContainer] at com.atlassian.jira.config.database.DatabaseConfigurationManagerImpl.doNowOrEnqueue(DatabaseConfigurationManagerImpl.java:304)
[INFO] [talledLocalContainer] at com.atlassian.jira.config.database.DatabaseConfigurationManagerImpl.doNowOrWhenDatabaseActivated(DatabaseConfigurationManagerImpl.java:199)
[INFO] [talledLocalContainer] at com.atlassian.jira.startup.DefaultJiraLauncher.postDbLaunch(DefaultJiraLauncher.java:135)
[INFO] [talledLocalContainer] at com.atlassian.jira.startup.DefaultJiraLauncher.lambda$start$0(DefaultJiraLauncher.java:102)
[INFO] [talledLocalContainer] at com.atlassian.jira.util.devspeed.JiraDevSpeedTimer.run(JiraDevSpeedTimer.java:31)
[INFO] [talledLocalContainer] at com.atlassian.jira.startup.DefaultJiraLauncher.start(DefaultJiraLauncher.java:100)
[INFO] [talledLocalContainer] at com.atlassian.jira.startup.LauncherContextListener.initSlowStuff(LauncherContextListener.java:154)
[INFO] [talledLocalContainer] at com.atlassian.jira.startup.LauncherContextListener.initSlowStuffInBackground(LauncherContextListener.java:139)
[INFO] [talledLocalContainer] at com.atlassian.jira.startup.LauncherContextListener.contextInitialized(LauncherContextListener.java:101)
[INFO] [talledLocalContainer] ... 8 filtered
[INFO] [talledLocalContainer] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[INFO] [talledLocalContainer] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[INFO] [talledLocalContainer] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[INFO] [talledLocalContainer] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[INFO] [talledLocalContainer] at java.lang.Thread.run(Thread.java:748)
[INFO] [talledLocalContainer] Caused by: org.osgi.framework.BundleException: Unresolved constraint in bundle com.dataguardian.timetracking [177]: Unable to resolve 177.0: missing requirement [177.0] osgi.wiring.package; (osgi.wiring.package=com.mchange.v2.c3p0)
[INFO] [talledLocalContainer] at org.apache.felix.framework.Felix.resolveBundleRevision(Felix.java:3974)
[INFO] [talledLocalContainer] at org.apache.felix.framework.Felix.startBundle(Felix.java:2037)
[INFO] [talledLocalContainer] at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:955)
[INFO] [talledLocalContainer] at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:942)
[INFO] [talledLocalContainer] at com.atlassian.plugin.osgi.factory.OsgiPlugin.enableInternal(OsgiPlugin.java:399)

1 answer

I have a 1/2 solution. The plugin works if I add (*;resolution:="optional"). 

<Import-Package>
org.springframework.osgi.*;resolution:="optional",
org.eclipse.gemini.blueprint.*;resolution:="optional",
com.mysql.*;resolution:="optional",
*;resolution:="optional"
</Import-Package>

I've been read that this isn't an ideal solution. How can I find out which package is the issue?

Suggest an answer

Log in or Sign up to answer
TAGS

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you