Tutorial: Hello World Macro fails

I tried to create a Macro for Confluence and i do this with the Atlassian Tutorial (https://developer.atlassian.com/docs/getting-started/set-up-the-atlassian-plugin-sdk-and-build-a-pro…)

The first steps were fine and i can see the macro in the add-on list.

BUT:
When I want to add the Macro to a testpage, i am not able to do this. Even opening the Macro-Browser fails, also if i want to add a macro from the list that is already given. In the terminal i can see something like:

[INFO] [talledLocalContainer] caused by: java.lang.NoClassDefFoundError: Could not initialize class com.benryan.conversion.macro.ConverterMacro
[INFO] [talledLocalContainer] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

I am looking on the tutorial, the com.benryan.conversion.macro.ConverterMacro is not referred anywhere. You have typed or imported something wrong. Diff your code with code in their repo

Thank you for advice, I did but it is still not working.

Even when i try to navigate to the administration and click on “Macro Usage” there is a page-load error.

Terminal says:

INFO] [talledLocalContainer] Parameters
[INFO] [talledLocalContainer] --------------------------
[INFO] [talledLocalContainer] caused by: javax.servlet.ServletException: Servlet execution threw an exception
[INFO] [talledLocalContainer] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:315)
[INFO] [talledLocalContainer] caused by: java.lang.NoClassDefFoundError: Could not initialize class com.benryan.conversion.macro.ConverterMacro
[INFO] [talledLocalContainer] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

Thank you for the fast answer! I did but it is still not working.

Even when i try to navigate to the administration and click on “Macro Usage” there is a page-load error.

Terminal says:

INFO] [talledLocalContainer] Parameters
[INFO] [talledLocalContainer] --------------------------
[INFO] [talledLocalContainer] caused by: javax.servlet.ServletException: Servlet execution threw an exception
[INFO] [talledLocalContainer] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:315)
[INFO] [talledLocalContainer] caused by: java.lang.NoClassDefFoundError: Could not initialize class com.benryan.conversion.macro.ConverterMacro
[INFO] [talledLocalContainer] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

Resolved Problem! @Panos it was the wrong java installation

1 Like