-
Type:
Bug
-
Resolution: Tracked Elsewhere
-
Priority:
Low
-
None
-
Affects Version/s: 7.0.5
-
Component/s: UPM (Universal Plugin Manager)
-
7
To reproduce:
Install the Atlassian SDK
(https://sdkrepo.atlassian.com/deb-archive/atlassian-plugin-sdk_6.2.2_all.deb)
- run atlas-create-jira-plugin
[INFO] using latest stable product version: 7.0.5 [INFO] determining latest stable data version... [INFO] using latest stable data version: 7.0.5 Define value for groupId: : org.example Define value for artifactId: : bugged-modules Define value for version: 1.0.0-SNAPSHOT: : Define value for package: org.example: : Confirm properties configuration: groupId: org.example artifactId: bugged-modules version: 1.0.0-SNAPSHOT package: org.example Y: : y [INFO] Setting property: classpath.resource.loader.class => 'org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'. [INFO] Setting property: velocimacro.messages.on => 'false'. [INFO] Setting property: resource.loader => 'classpath'. [INFO] Setting property: resource.manager.logwhenfound => 'false'. [INFO] Generating project in Batch mode [INFO] Archetype repository missing. Using the one from [com.atlassian.maven.archetypes:jira-plugin-archetype:5 -> https://maven.atlassian.com/public] found in catalog internal [WARNING] org.apache.velocity.runtime.exception.ReferenceException: reference : template = archetype-resources/pom.xml [line 49,column 22] : ${atlassian.spring.scanner.version} is not a valid reference. [WARNING] org.apache.velocity.runtime.exception.ReferenceException: reference : template = archetype-resources/pom.xml [line 56,column 22] : ${atlassian.spring.scanner.version} is not a valid reference. [WARNING] org.apache.velocity.runtime.exception.ReferenceException: reference : template = archetype-resources/pom.xml [line 121,column 47] : ${atlassian.plugin.key} is not a valid reference. [WARNING] org.apache.velocity.runtime.exception.ReferenceException: reference : template = archetype-resources/pom.xml [line 172,column 31] : ${project.groupId} is not a valid reference. [WARNING] org.apache.velocity.runtime.exception.ReferenceException: reference : template = archetype-resources/pom.xml [line 172,column 50] : ${project.artifactId} is not a valid reference. [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS
cd bugged-modules
[INFO] Building bugged-modules 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-jira-plugin:6.2.1:create-plugin-module (default-cli) @ bugged-modules ---
Choose Plugin Module:
pick (for example) 4 custom field
Enter New Classname MyCustomField: : Enter Package Name org.example.jira.customfields: : Show Advanced Setup? (Y/y/N/n) N: : n [INFO] Adding the following items to the project: [INFO] [class: org.example.jira.customfields.MyCustomField] [INFO] [class: ut.org.example.jira.customfields.MyCustomFieldTest] [INFO] [dependency: org.mockito:mockito-all] [INFO] [dependency: org.slf4j:slf4j-api] [INFO] [module: customfield-type] [INFO] [resource: edit.vm] [INFO] [resource: view.vm] [INFO] i18n strings: 2 Add Another Plugin Module? (Y/y/N/n) N: : n [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS
- atlas-run
- go to local jira instance
- login admin:admin
- go to issues -> custom fields
- add custom field
-see log for depency injection failure
INFO] [talledLocalContainer] Dec 31, 2015 10:54:04 AM com.sun.jersey.server.impl.application.WebApplicationImpl _initiate [INFO] [talledLocalContainer] INFO: Initiating Jersey application, version 'Jersey: 1.8-atlassian-16 03/23/2015 10:20 PM' [INFO] [talledLocalContainer] 2015-12-31 10:54:06,699 http-nio-36969-exec-9 ERROR admin 654x145x1 1iz796r 127.0.0.1 /secure/admin/ViewCustomFields.jspa [c.a.plugin.module.PrefixDelegatingModuleFactory] Detected an error instantiating the module via Spring. This usually means that you haven't created a <component-import> for the interface you're trying to use. https://developer.atlassian.com/x/TAEr for more details. [INFO] [talledLocalContainer] 2015-12-31 10:54:06,701 http-nio-36969-exec-9 ERROR admin 654x145x1 1iz796r 127.0.0.1 /secure/admin/ViewCustomFields.jspa [c.a.plugin.manager.DefaultPluginManager] Exception when retrieving plugin module my-custom-field [INFO] [talledLocalContainer] com.atlassian.util.concurrent.LazyReference$InitializationException: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.example.jira.customfields.MyCustomField': Unsatisfied dependency expressed through constructor argument with index 0 of type [com.atlassian.jira.issue.customfields.persistence.CustomFieldValuePersister]: : No qualifying bean of type [com.atlassian.jira.issue.customfields.persistence.CustomFieldValuePersister] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this
The log suggeste adding a component-import, but that doesnt resolve the problem (it does show a extra module in the add-on view in JIRA, but still fails to inject)
- was cloned as
-
AMPS-1309 Loading...