Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

i use the demo of macro develop, but i add some other depency, i can't package it

thomasy Jacky January 2, 2024

i use the source code https://bitbucket.org/serverecosystem/myconfluencemacro.git    to  run it and package it ,the result is right, but i  change the pom.xml , add any another depency, i can't package it  the error info is below:

[INFO] --- maven-confluence-plugin:6.2.6:generate-manifest (default-generate-manifest) @ myConfluenceMacro ---
[INFO] Generating a manifest for this plugin
[INFO] using maven-bundle-plugin v2.5.3
java.lang.ArrayIndexOutOfBoundsException: 19
at aQute.bnd.osgi.Clazz.parseClassFile(Clazz.java:579)
at aQute.bnd.osgi.Clazz.parseClassFile(Clazz.java:497)
at aQute.bnd.osgi.Clazz.parseClassFileWithCollector(Clazz.java:486)
at aQute.bnd.osgi.Clazz.parseClassFile(Clazz.java:476)
at aQute.bnd.osgi.Analyzer.analyzeJar(Analyzer.java:2195)
at aQute.bnd.osgi.Analyzer.analyzeBundleClasspath(Analyzer.java:2101)
at aQute.bnd.osgi.Analyzer.analyze(Analyzer.java:139)
at aQute.bnd.osgi.Builder.analyze(Builder.java:352)
at aQute.bnd.osgi.Analyzer.calcManifest(Analyzer.java:618)
at org.apache.felix.bundleplugin.ManifestPlugin.getAnalyzer(ManifestPlugin.java:213)
at org.apache.felix.bundleplugin.ManifestPlugin.getManifest(ManifestPlugin.java:114)
at org.apache.felix.bundleplugin.ManifestPlugin.execute(ManifestPlugin.java:69)
at org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java:294)
at org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java:285)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:137)
at org.twdata.maven.mojoexecutor.MojoExecutor.executeMojoImpl(MojoExecutor.java:172)
at org.twdata.maven.mojoexecutor.MojoExecutor$ExecutionEnvironmentM3.executeMojo(MojoExecutor.java:476)
at org.twdata.maven.mojoexecutor.MojoExecutor.executeMojo(MojoExecutor.java:75)
at com.atlassian.maven.plugins.amps.MavenGoals.generateBundleManifest(MavenGoals.java:1553)
at com.atlassian.maven.plugins.amps.osgi.GenerateManifestMojo.execute(GenerateManifestMojo.java:65)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:137)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:154)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:146)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:117)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:81)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:56)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:305)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:192)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:105)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:954)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:192)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
at org.codehaus.classworlds.Launcher.main(Launcher.java:47)
[WARNING] Manifest com.atlassian.tutorial:myConfluenceMacro:atlassian-plugin:1.0.0-SNAPSHOT : Unused Import-Package instructions: [com.alibaba.fastjson.*]
[ERROR] Manifest com.atlassian.tutorial:myConfluenceMacro:atlassian-plugin:1.0.0-SNAPSHOT : Exception: 19
[ERROR] Manifest com.atlassian.tutorial:myConfluenceMacro:atlassian-plugin:1.0.0-SNAPSHOT : Invalid class file META-INF/versions/9/module-info.class (java.lang.ArrayIndexOutOfBoundsException: 19)
[ERROR] Error(s) found in manifest configuration

1 answer

0 votes
Brant Schroeder
Community Champion
May 1, 2024

@thomasy Jacky I would suggest submitting this question in the developer community https://community.developer.atlassian.com/   This community is geared towards developers and they will be able to better help you.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
6.13.4
TAGS
AUG Leaders

Atlassian Community Events