I'm trying to follow this outdated tutorial. It's making use of the sal and jira versions of the UserManager. The differentiation they use doesn't seem to work with Spring's annotations.
import com.atlassian.sal.api.user.UserManager;
@Component
public class TestClass extends HttpServlet{
@ComponentImport
private UserManager userManager;
private com.atlassian.jira.user.util.UserManager jiraUserManager;
@Autowired
public TestClass(UserManager userManager, com.atlassian.jira.user.util.UserManager jiraUserManager) {
this.userManager = userManager;
this.jiraUserManager = jiraUserManager;
}
}
This is stripped down version of what I have. (see the repo for full code)
The error I'm getting is:
Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [com.atlassian.jira.user.util.UserManager] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {}Any help would be appreciated in resolving this issue.