Atlassian Confluence SDK Problem starting App 404
Asked Answered
W

2

6

when starting a Confluence plugin I always get the following error:

[INFO] [talledLocalContainer] 2020-08-06 20:48:58,116 ERROR [main] [ContainerBase.[Catalina].[localhost].[/confluence]] log Exception sending context initialized event to listener instance of class [com.atlassian.confluence.setup.ConfluenceConfigurationListener]
INFO] [talledLocalContainer] java.lang.ExceptionInInitializerError
[INFO] [talledLocalContainer]   at com.ibm.icu.text.Collator.<clinit>(Collator.java:946)
[INFO] [talledLocalContainer]   at java.lang.Class.forName0(Native Method)
[INFO] [talledLocalContainer]   at java.lang.Class.forName(Class.java:264)
[INFO] [talledLocalContainer]   at org.h2.value.CompareMode.<clinit>(CompareMode.java:57)
[INFO] [talledLocalContainer]   at org.h2.engine.SessionRemote.<init>(SessionRemote.java:95)
[INFO] [talledLocalContainer]   at org.h2.jdbc.JdbcConnection.<init>(JdbcConnection.java:116)
[INFO] [talledLocalContainer] Aug 06, 2020 8:48:58 PM org.apache.catalina.core.StandardContext startInternal
[INFO] [talledLocalContainer]   at org.h2.jdbc.JdbcConnection.<init>(JdbcConnection.java:100)
[INFO] [talledLocalContainer]   at org.h2.Driver.connect(Driver.java:69)
[INFO] [talledLocalContainer] SEVERE: One or more listeners failed to start. Full details will be found in the appropriate container log file
[INFO] [talledLocalContainer]   at org.h2.server.TcpServer.initManagementDb(TcpServer.java:92)
[INFO] [talledLocalContainer]   at org.h2.server.TcpServer.start(TcpServer.java:238)
[INFO] [talledLocalContainer] Aug 06, 2020 8:48:58 PM org.apache.catalina.core.StandardContext startInternal
[INFO] [talledLocalContainer]   at org.h2.tools.Server.start(Server.java:484)
[INFO] [talledLocalContainer] SEVERE: Context [/confluence] startup failed due to previous errors
[...]
[INFO] [talledLocalContainer] Aug 06, 2020 8:49:07 PM org.apache.coyote.AbstractProtocol start
[INFO] [talledLocalContainer] INFO: Starting ProtocolHandler ["http-nio-1990"]
[INFO] [talledLocalContainer] Aug 06, 2020 8:49:07 PM org.apache.coyote.AbstractProtocol start
[INFO] [talledLocalContainer] INFO: Starting ProtocolHandler ["ajp-nio-8009"]
[INFO] [talledLocalContainer] Aug 06, 2020 8:49:07 PM org.apache.catalina.startup.Catalina start
[INFO] [talledLocalContainer] INFO: Server startup in 29245 ms
[INFO] [talledLocalContainer] Tomcat 9.x started on port [1990]
[INFO] confluence started successfully in 103s at http://localhost:1990/confluence
[INFO] Type Ctrl-C to shutdown gracefully

I have tried several plugins and in Windows, Mac and Ubuntu. Unfortunately I always get this error when starting the current and also an older SDK. I have tried Oracle and OpenJdk, both version 8. The result is a 404 page when calling http://127.0.0.1:1990/confluence

My Setting

ATLAS Version:    8.2.2
ATLAS Home:       /usr/share/atlassian-plugin-sdk-8.2.2
ATLAS Scripts:    /usr/share/atlassian-plugin-sdk-8.2.2/bin
ATLAS Maven Home: /usr/share/atlassian-plugin-sdk-8.2.2/apache-maven-3.5.4
AMPS Version:     8.1.0
--------
Executing: /usr/share/atlassian-plugin-sdk-8.2.2/apache-maven-3.5.4/bin/mvn --version -gs /usr/share/atlassian-plugin-sdk-8.2.2/apache-maven-3.5.4/conf/settings.xml
Apache Maven 3.5.4 (1edded0938998edf8bf061f1ceb3cfdeccf443fe; 2018-06-17T20:33:14+02:00)
Maven home: /usr/share/atlassian-plugin-sdk-8.2.2/apache-maven-3.5.4
Java version: 1.8.0_265, vendor: Private Build, runtime: /usr/lib/jvm/java-8-openjdk-amd64/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "5.4.0-42-generic", arch: "amd64", family: "unix"

The Tomcat log does not contain any errors...

Do you have the same problem, or do you know a solution?

Woodrum answered 6/8, 2020 at 19:6 Comment(0)
W
4

For all who also have this problem - the solution is to use a Java 8 version older than u261 or a Confluence version bigger than 7.0.0

Woodrum answered 10/8, 2020 at 9:6 Comment(0)
B
5

Just to help others who come to this question as well with the same issue as both of us, You need to edit the pom.xml file and update the following properties:

  • project > properties > confluence.version
  • project > properties > confluence.data.version

The values are the version found on the confluence server page. Finally, make sure to run atlas-clean then you can run atlas-run.

Baseman answered 18/8, 2020 at 15:26 Comment(3)
Thanks a bunch! in short (for search engines) - current confluence plugin SDK with default settings will not let user to start the default sample. I got JDK 1.8.0_265 installed and ATLAS version 8.2.2, maybe it makes some sense, but anyhow atlas-run for dummy plugin will crash with java.lang.ExceptionInInitializerError. One need to manually change pom.xml to make it use confluence version from 6.14.0 to 7.7.4 (I used the latest one from release page at the moment). By the way it was hard to find the solution, at least atlassian resources doesn't highlight this one.Supralapsarian
Can confirm! Tried to update an old plugin and wasn't able to run 'atlas-run'. So I created a new plugin, tried different jdk versions, rebooted, ... The error is hard to spot, and a freshly created jira plugin works without any problems...Looper
Tried different versions which all had their problems. Settled on the latest version of this moment (8.7.2) and got it working. The java version (21.0.1, adoptium Temurin) is however not supported (but working).Whirlabout
W
4

For all who also have this problem - the solution is to use a Java 8 version older than u261 or a Confluence version bigger than 7.0.0

Woodrum answered 10/8, 2020 at 9:6 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.