Error adding service: org.picocontainer.defaults.UnsatisfiableDependenciesException:

Hi,

I have used componenet import method to obtain functiionalities of a different plugin.But when i try to add the service i get this error.ITsn ot able to instantiate the object in the constructor..


at org.picocontainer.defaults.ConstructorInjectionComponentAdapter.getGreediestSatisifableConstructor(ConstructorInjectionComponentAdapter.java:138)
at org.picocontainer.defaults.ConstructorInjectionComponentAdapter.instantiateComponent(ConstructorInjectionComponentAdapter.java:193)
at org.picocontainer.defaults.InstantiatingComponentAdapter.getComponentInstance(InstantiatingComponentAdapter.java:48)
at org.picocontainer.defaults.DecoratingComponentAdapter.getComponentInstance(DecoratingComponentAdapter.java:42)
at org.picocontainer.defaults.SynchronizedComponentAdapter.getComponentInstance(SynchronizedComponentAdapter.java:35)
at org.picocontainer.defaults.DecoratingComponentAdapter.getComponentInstance(DecoratingComponentAdapter.java:42)
at com.atlassian.jira.config.component.ProfilingComponentAdapter.getComponentInstance(ProfilingComponentAdapter.java:45)
at org.picocontainer.defaults.DefaultPicoContainer.getComponentInstance(DefaultPicoContainer.java:298)
at com.atlassian.jira.util.JiraUtils.loadComponent(JiraUtils.java:113)
at com.atlassian.jira.util.JiraUtils.loadComponent(JiraUtils.java:91)
at com.atlassian.jira.service.OfBizServiceConfigStore.addServiceConfig(OfBizServiceConfigStore.java:54)
at com.atlassian.jira.service.DefaultServiceManager.addService(DefaultServiceManager.java:211)
at com.atlassian.jira.service.DefaultServiceManager.addService(DefaultServiceManager.java:198)
at com.atlassian.jira.service.DefaultServiceManager.addService(DefaultServiceManager.java:184)
at com.atlassian.jira.web.action.admin.ViewServices.doExecute(ViewServices.java:143)
at webwork.action.ActionSupport.execute(ActionSupport.java:165)

3 answers

1 accepted

This widget could not be displayed.

Is that a public component? You can only components which are declared public.

I have declared it public

<component key="archiveProject"
class="com.org.ArchiveProjectImpl"
public="true">
<description>Provides hello world services.</description>
<interface>com.org.ArchiveProject
</interface>
</component>

<pluginname> doesn't have any satisfiable constructors. Unsatisfiable dependencies:

Hi,

i was able to solve this by doing the following:

In atlassian-plugin.xml

<component-import key="archiveProject">
<interface>com.sap.jira.plugins.archiving.component.ArchiveProject
</interface>
</component-import>

Ans call this in a diff plugin by-

ComponentManager.getOSGiComponentInstanceOfType(ArchiveProject.class);

Have the same problem( All the componets are declared as public, but still have

UnsatisfiableDependenciesException

This widget could not be displayed.

Is there any way to instantiate the object of other plugin if component-import doesnt work??

This widget could not be displayed.

Add this in atlassian-plugin.xml

<component-import key="archiveProject">
<interface>com.org.ArchiveProject
</interface>
</component>

use this API to import the component instead of a constructor-

ComponentManager.getOSGiComponentInstanceOfType(ArchiveProject.class);

Suggest an answer

Log in or Sign up to answer
Atlassian Summit 2018

Meet the community IRL

Atlassian Summit is an excellent opportunity for in-person support, training, and networking.

Learn more
Community showcase
Published 10 hours ago in Marketplace Apps

The 7 hacks of highly successful automation

...there's anything I've learnt from working, it's that people are lazy! No offense to anyone reading this, but it's true and we can all admit it. The easier you make something for someone, the more...

54 views 0 8
Read article

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you