Hi.
I try to build plugin with custom web-panel and context-provider using PluginSettingsFactory
SettingsStoreService.class
@Component
public class SettingsStorageService {
@Autowired
final PluginSettingsFactory pluginSettingsFactory;
private String storageKey;
public SettingsStorageService(PluginSettingsFactory pluginSettingsFactory)
{...
MainMenu.class
public class MainMenu extends AbstractJiraContextProvider {
private SettingsStorageService settingsStorageService;
public MainMenu(@ComponentImport PluginSettingsFactory pluginSettingsFactory)
{
settingsStorageService = new SettingsStorageService(pluginSettingsFactory);
}
@Override
public Map getContextMap(ApplicationUser applicationUser, JiraHelper jiraHelper)
{...
But springscanner says
Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException:
Error creating bean with name 'com.avvd.jira.plugin.additional.MainMenu': Unsatisfied dependency expressed through constructor argument with index 0 of type
[com.atlassian.sal.api.pluginsettings.PluginSettingsFactory]: No qualifying bean of type [com.atlassian.sal.api.pluginsettings.PluginSettingsFactory]
found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations:
{@com.atlassian.plugin.spring.scanner.annotation.imports.ComponentImport(value=)}; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException:
No qualifying bean of type [com.atlassian.sal.api.pluginsettings.PluginSettingsFactory]
found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations:
{@com.atlassian.plugin.spring.scanner.annotation.imports.ComponentImport(value=)}
How to make proper ComponentImport in this case?
Thanks for help.
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.