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

unable to deploy plugin because of NPE at HostComponentSpringStage.java:235 Edited

Hello,

we have our own plugin which was working earlier and stopped working after Jira software upgrade to 8.4.2 server. I get the following error message and the plugin doesn't deploy while server startup. Your help is much appreciated.

2019-11-06 00:51:10,115 localhost-startStop-1 ERROR [c.a.plugin.loaders.ScanningPluginLoader] Unable to deploy plugin 'com.example.proaction.projectinfo' from 'Unit: C:\D-Drive\asop_workspace\proaction-project-view-plugin-for-jira\project-info\target\jira\home\plugins\installed-plugins\projectinfo-1.0.8-SNAPSHOT.jar (1572981099922)'.
2019-11-06 00:51:10,119 localhost-startStop-1 ERROR [c.a.plugin.loaders.ScanningPluginLoader] Because of the following exception:
java.lang.NullPointerException
at com.atlassian.plugin.osgi.factory.transform.stage.HostComponentSpringStage.addHostComponentsUsedInSuperClasses(HostComponentSpringStage.java:235)
at com.atlassian.plugin.osgi.factory.transform.stage.HostComponentSpringStage.findUsedHostComponents(HostComponentSpringStage.java:220)
at com.atlassian.plugin.osgi.factory.transform.stage.HostComponentSpringStage.execute(HostComponentSpringStage.java:69)
at com.atlassian.plugin.osgi.factory.transform.DefaultPluginTransformer.transform(DefaultPluginTransformer.java:140)
at com.atlassian.plugin.osgi.factory.OsgiPluginFactory.createOsgiPluginJar(OsgiPluginFactory.java:307)
at com.atlassian.plugin.osgi.factory.OsgiPluginFactory.create(OsgiPluginFactory.java:224)
at com.atlassian.jira.plugin.MasterPluginFactory.create(MasterPluginFactory.java:73)
at com.atlassian.plugin.loaders.ScanningPluginLoader.deployPluginFromUnit(ScanningPluginLoader.java:145)
at com.atlassian.plugin.loaders.ScanningPluginLoader.loadAllPlugins(ScanningPluginLoader.java:90)
at com.atlassian.plugin.loaders.PermissionCheckingPluginLoader.loadAllPlugins(PermissionCheckingPluginLoader.java:28)
at com.atlassian.plugin.manager.DefaultPluginManager.lambda$earlyStartup$3(DefaultPluginManager.java:539)
at com.atlassian.plugin.manager.PluginTransactionContext.wrap(PluginTransactionContext.java:63)
at com.atlassian.plugin.manager.DefaultPluginManager.earlyStartup(DefaultPluginManager.java:523)
at com.atlassian.jira.plugin.JiraPluginManager.earlyStartup(JiraPluginManager.java:119)
at com.atlassian.jira.component.pico.ComponentManager$PluginSystem.earlyStartup(ComponentManager.java:669)
at com.atlassian.jira.component.pico.ComponentManager.earlyStartPluginSystem(ComponentManager.java:238)
at com.atlassian.jira.upgrade.PluginSystemLauncher.start(PluginSystemLauncher.java:45)
at com.atlassian.jira.startup.DefaultJiraLauncher.lambda$postDbLaunch$2(DefaultJiraLauncher.java:145)
at com.atlassian.jira.config.database.DatabaseConfigurationManagerImpl.doNowOrEnqueue(DatabaseConfigurationManagerImpl.java:301)
at com.atlassian.jira.config.database.DatabaseConfigurationManagerImpl.doNowOrWhenDatabaseActivated(DatabaseConfigurationManagerImpl.java:196)
at com.atlassian.jira.startup.DefaultJiraLauncher.postDbLaunch(DefaultJiraLauncher.java:137)
at com.atlassian.jira.startup.DefaultJiraLauncher.lambda$start$0(DefaultJiraLauncher.java:104)
at com.atlassian.jira.util.devspeed.JiraDevSpeedTimer.run(JiraDevSpeedTimer.java:31)
at com.atlassian.jira.startup.DefaultJiraLauncher.start(DefaultJiraLauncher.java:102)
at com.atlassian.jira.startup.LauncherContextListener.initSlowStuff(LauncherContextListener.java:154)
at com.atlassian.jira.startup.LauncherContextListener.initSlowStuffInBackground(LauncherContextListener.java:139)
at com.atlassian.jira.startup.LauncherContextListener.contextInitialized(LauncherContextListener.java:101)
... 8 filtered
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)

 Here's my pom.xml

<?xml version="1.0" encoding="UTF-8"?>

<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

<modelVersion>4.0.0</modelVersion>
<groupId>com.example.proaction</groupId>
<artifactId>projectinfo</artifactId>
<version>1.0.8-SNAPSHOT</version>

<organization>
<name>example</name>
<url>http://www.example.com/</url>
</organization>

<packaging>atlassian-plugin</packaging>
<name>projectinfo</name>
<description>This is the com.example.proaction:projectinfo plugin for Atlassian JIRA.</description>

<dependencies>
<dependency>
<groupId>com.atlassian.jira</groupId>
<artifactId>jira-api</artifactId>
<version>${jira.version}</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>com.atlassian.jira</groupId>
<artifactId>jira-core</artifactId>
<version>${jira.version}</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>com.atlassian.plugin</groupId>
<artifactId>atlassian-spring-scanner-annotation</artifactId>
<version>${atlassian.spring.scanner.version}</version>
<scope>compile</scope>
</dependency>

<dependency>
<groupId>com.atlassian.plugin</groupId>
<artifactId>atlassian-spring-scanner-runtime</artifactId>
<version>${atlassian.spring.scanner.version}</version>
<scope>runtime</scope>
</dependency>

<dependency>
<groupId>com.atlassian.inject</groupId>
<artifactId>atlassian-inject</artifactId>
<version>1.0.0</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<version>2.2.2-atlassian-1</version>
</dependency>

<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.1.1</version>
<scope>test</scope>
</dependency>

<!-- https://mvnrepository.com/artifact/com.atlassian.sal/sal-api -->
<dependency>
<groupId>com.atlassian.sal</groupId>
<artifactId>sal-api</artifactId>
<version>3.0.7</version>
<scope>provided</scope>
</dependency>

<!-- https://mvnrepository.com/artifact/org.apache.velocity/velocity -->
<dependency>
<groupId>org.apache.velocity</groupId>
<artifactId>velocity</artifactId>
<version>1.7</version>
</dependency>

<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
<version>2.12.1</version>
</dependency>

<!-- https://mvnrepository.com/artifact/com.atlassian.crowd/embedded-crowd-api -->
<dependency>
<groupId>com.atlassian.crowd</groupId>
<artifactId>embedded-crowd-api</artifactId>
<version>2.8.0-OD-6-JIRA-05</version>
</dependency>

<!-- https://mvnrepository.com/artifact/com.atlassian.plugins/atlassian-plugins-webfragment -->
<dependency>
<groupId>com.atlassian.plugins</groupId>
<artifactId>atlassian-plugins-webfragment-api</artifactId>
<version>4.1.0</version>
<scope>provided</scope>
</dependency>

<!-- https://mvnrepository.com/artifact/com.atlassian.plugins/atlassian-plugins-core -->
<dependency>
<groupId>com.atlassian.plugins</groupId>
<artifactId>atlassian-plugins-core</artifactId>
<version>2.6.0</version>
</dependency>

<!-- https://mvnrepository.com/artifact/com.atlassian.jira/jira-projects-api -->
<dependency>
<groupId>com.atlassian.jira</groupId>
<artifactId>jira-projects-api</artifactId>
<version>4.1.13</version>
</dependency>

<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
<version>2.5</version>
<scope>provided</scope>
</dependency>

<!-- https://mvnrepository.com/artifact/velocity-tools/velocity-tools-generic -->
<dependency>
<groupId>velocity-tools</groupId>
<artifactId>velocity-tools-generic</artifactId>
<version>1.4</version>
</dependency>

<dependency>
<groupId>org.json</groupId>
<artifactId>json</artifactId>
<version>20090211</version>
</dependency>

<!-- https://mvnrepository.com/artifact/com.google.guava/guava -->
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>r05</version>
</dependency>

<!-- https://mvnrepository.com/artifact/org.apache.lucene/lucene-core -->
<dependency>
<groupId>org.apache.lucene</groupId>
<artifactId>lucene-core</artifactId>
<version>8.1.1</version>
</dependency>

</dependencies>

<build>
<defaultGoal>package</defaultGoal>
<plugins>
<plugin>
<groupId>com.atlassian.maven.plugins</groupId>
<artifactId>jira-maven-plugin</artifactId>
<version>${amps.version}</version>
<extensions>true</extensions>
<configuration>
<productVersion>${jira.version}</productVersion>
<productDataVersion>${jira.version}</productDataVersion>
<startupTimeout>1200000</startupTimeout>
<shutdownTimeout>900000</shutdownTimeout>

<instructions>
<Export-Package>
com.example.proaction.projectinfo
</Export-Package>

<Import-Package>org.springframework.osgi.*;resolution:="optional",
org.eclipse.gemini.blueprint.*;resolution:="optional",
com.atlassian.sal.api;version="0.0.0";resolution:="optional",
com.atlassian.plugin.spring.scanner.annotation.*;version="0.0.0";resolution:="optional",
com.example.proaction.projectinfo;version="0.0.0";resolution:="optional",
com.atlassian.inject;version="0.0.0";resolution:="optional",
*;</Import-Package>
<Spring-Context>*</Spring-Context>
</instructions>
</configuration>
</plugin>


<plugin>
<groupId>com.atlassian.plugin</groupId>
<artifactId>atlassian-spring-scanner-maven-plugin</artifactId>
<version>${atlassian.spring.scanner.version}</version>
<executions>
<execution>
<goals>
<goal>atlassian-spring-scanner</goal>
</goals>
<phase>process-classes</phase>
</execution>
</executions>
<configuration>
<scannedDependencies>
<dependency>
<groupId>com.atlassian.plugin</groupId>
<artifactId>atlassian-spring-scanner-external-jar</artifactId>
</dependency>
</scannedDependencies>
<verbose>false</verbose>
</configuration>
</plugin>

<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<fork>true</fork>
<executable>C:\Program Files\Java\jdk1.8.0_91\bin\javac.exe</executable>
</configuration>
</plugin>
</plugins>
</build>

<properties>
<jira.version>8.4.2</jira.version>
<amps.version>8.0.2</amps.version>
<atlassian.spring.scanner.version>1.2.13</atlassian.spring.scanner.version>
<quick.reload.version>3.0.0</quick.reload.version>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<atlassian.plugin.key>${project.groupId}.${project.artifactId}</atlassian.plugin.key>
<maven.test.skip>true</maven.test.skip>
</properties>

</project>

 Thanks in advance for your time.

-Kumar

0 answers

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted in Jira

Demo Den Ep. 7: New Jira Cloud Reports

Learn how to use two new reports for next-gen projects in Jira Cloud:  Cumulative flow diagram and Sprint burndown chart. Ivan Teong, Product Manager, Jira Software, demos the Cumulative ...

237 views 1 2
Join discussion

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