Preparing for Confluence 9.0 - EAP out now

OSGi export behaviour differing between Dev and Prod mode was indeed an oversight and will be rectified.

@scott.dudley I understand Lockpoint requires access to the system VelocityEngine. As you might realise, exposing the system VelocityEngine to plugins has some security implications. Could you clarify which VelocityEngine APIs you are calling and for what purpose? Lockpoint is the only marketplace plugin for which this removal is a blocker, however, we will consider introducing a suitable replacement API if it can be done securely.

5 Likes

I have just successfully upgraded my Confluence App to build against Confluence 8.8 (see the other thread) with Java 11.

When I try to do a Java 17 build against the Confluence 9.0.0 all is fine when using atlas-package -DskipTests=true. But when the tests are executed I get strange errors

[ERROR] Failed to execute goal com.atlassian.maven.plugins:confluence-maven-plugin:8.13.0:unit-test (default-unit-test) on project advanced-codeblock-macro: There are test failures.
[ERROR]
[ERROR] Please refer to /Users/clouless/github/foobackend/target/surefire-reports for the individual test results.
[ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[ERROR] The forked VM terminated without properly saying goodbye. VM crash or System.exit called?
[ERROR] Command was /bin/sh -c cd /Users/clouless/github/foobackend && /Library/Java/JavaVirtualMachines/jdk-17.jdk/Contents/Home/bin/java -Xmx1024m -XX:MaxPermSize=256m -jar /Users/clouless/github/foobackend/target/surefire/surefirebooter11001625144626936862.jar /Users/clouless/github/foobackend/target/surefire 2024-02-02T01-19-14_089-jvmRun1 surefire4527158430779660906tmp surefire_011732253693723998288tmp
[ERROR] Error occurred in starting fork, check output in log
[ERROR] Process Exit Code: 1
[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The forked VM terminated without properly saying goodbye. VM crash or System.exit called?
[ERROR] Command was /bin/sh -c cd /Users/clouless/github/foobackend && /Library/Java/JavaVirtualMachines/jdk-17.jdk/Contents/Home/bin/java -Xmx1024m -XX:MaxPermSize=256m -jar /Users/clouless/github/foobackend/target/surefire/surefirebooter11001625144626936862.jar /Users/clouless/github/foobackend/target/surefire 2024-02-02T01-19-14_089-jvmRun1 surefire4527158430779660906tmp surefire_011732253693723998288tmp
[ERROR] Error occurred in starting fork, check output in log
[ERROR] Process Exit Code: 1

With JDK 11 and build against Confluence 8.8 everything works.
Any suggestions?

The dump says:

cat target/surefire-reports/2024-02-02T01-12-22_194-jvmRun1.dumpstream
# Created at 2024-02-02T01:12:22.382
Corrupted STDOUT by directly writing to native stream in forked JVM 1. Stream 'FATAL ERROR in native method: processing of -javaagent failed, processJavaStart failed'.

# Created at 2024-02-02T01:12:22.382
Corrupted STDOUT by directly writing to native stream in forked JVM 1. Stream 'V  [libjvm.dylib+0x4c6d50]  jni_FatalError+0xf8'.
java.lang.IllegalArgumentException: Stream stdin corrupted. Expected comma after third character in command 'V  [libjvm.dylib+0x4c6d50]  jni_FatalError+0xf8'.
	at org.apache.maven.plugin.surefire.booterclient.output.ForkClient$OperationalData.<init>(ForkClient.java:507)
	at org.apache.maven.plugin.surefire.booterclient.output.ForkClient.processLine(ForkClient.java:210)
	at org.apache.maven.plugin.surefire.booterclient.output.ForkClient.consumeLine(ForkClient.java:177)
	at org.apache.maven.plugin.surefire.booterclient.output.ThreadedStreamConsumer$Pumper.run(ThreadedStreamConsumer.java:88)
	at java.base/java.lang.Thread.run(Thread.java:842)

:white_check_mark: UPDATE: This solved all my compile+test problems:

diff --git a/pom.xml b/pom.xml
index 4a9fd69..29f9c37 100644
--- a/pom.xml
+++ b/pom.xml
@@ -186,28 +186,17 @@
         </dependency>
         <dependency>
             <groupId>org.hamcrest</groupId>
-            <artifactId>hamcrest-library</artifactId>
-            <version>1.3</version>
+            <artifactId>hamcrest</artifactId>
+            <version>2.2</version>
             <scope>test</scope>
         </dependency>
         <dependency>
             <groupId>nl.jqno.equalsverifier</groupId>
             <artifactId>equalsverifier</artifactId>
-            <version>3.0</version>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>org.hamcrest</groupId>
-            <artifactId>hamcrest-core</artifactId>
-            <version>1.3</version>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>org.hamcrest</groupId>
-            <artifactId>hamcrest-integration</artifactId>
-            <version>1.3</version>
+            <version>3.15.6</version>
             <scope>test</scope>
         </dependency>
+
         <dependency>
    
@@ -309,10 +298,16 @@
                 <artifactId>maven-surefire-plugin</artifactId>
                 <version>3.2.5</version>
                 <configuration>
-                    <forkCount>3</forkCount>
-                    <reuseForks>true</reuseForks>
+                    <!-- Java 11 -->
+                    <!-- <argLine>
+                        -Xmx1024m
+                        -XX:MaxPermSize=256m
+                        - -illegal-access=permit
+                        - -illegal-access=debug</argLine> -->
+                    <!-- Java 17 -->
                     <argLine>
-                        -Xmx1024m -XX:MaxPermSize=256m --illegal-access=permit --illegal-access=debug
+                        -Xmx1024m
+                        -XX:MaxMetaspaceSize=256m
                         --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED
                         --add-opens java.logging/java.util.logging=ALL-UNNAMED
                         --add-opens java.base/java.time.zone=ALL-UNNAMED
@@ -333,7 +328,15 @@
                         --add-opens java.base/java.util=ALL-UNNAMED
                         --add-opens java.base/java.io=ALL-UNNAMED
                         --add-opens java.base/java.lang=ALL-UNNAMED
+
+                        --add-exports java.base/jdk.internal.misc=ALL-UNNAMED
+                        --add-opens java.security.jgss/sun.security.krb5=ALL-UNNAMED
+                        --add-opens java.security.jgss/sun.security.krb5.internal=ALL-UNNAMED
+                        --add-opens java.base/java.time=ALL-UNNAMED
                     </argLine>
+                    <forkCount>5</forkCount>
+                    <reuseForks>true</reuseForks>
+                    <runOrder>alphabetical</runOrder>
                 </configuration>
             </plugin>
             <plugin>
@@ -403,7 +406,7 @@
             <plugin>
                 <groupId>org.jacoco</groupId>
                 <artifactId>jacoco-maven-plugin</artifactId>
-                <version>0.7.9</version>
+                <version>0.8.11</version>
                 <configuration>
                     <includes>

@@ -449,19 +449,19 @@
       
-        <confluence.version>8.5.0</confluence.version>  
+        <confluence.version>9.0.0-m08</confluence.version>
-        <confluence.data.version>8.5.0</confluence.data.version>
-        <amps.version>8.10.1</amps.version>
+        <confluence.data.version>9.0.0-m08</confluence.data.version>
+        <amps.version>8.13.0</amps.version>
         <plugin.testrunner.version>2.0.1</plugin.testrunner.version>
         <atlassian.spring.scanner.version>2.1.10</atlassian.spring.scanner.version>
         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
-        <maven.compiler.source>11</maven.compiler.source>
-        <maven.compiler.target>11</maven.compiler.target>
+        <maven.compiler.source>17</maven.compiler.source>
+        <maven.compiler.target>17</maven.compiler.target>
         <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
         <testkit.version>6.3.11</testkit.version>

TL;DR:

  • -XX:MaxPermSize=256m is now -XX:MaxMetaspaceSize=256m
  • hamcrest version updated
  • --illegal-access=permit --illegal-access=debug removed
  • added all the --add-opens for all complaining Classes we mock
  • jacoco updated

In my previous comment I wrote about my compile problems and problems with unit tests.
I got these resolved, but now I am having OSGI problems:

:white_check_mark: IT WORKS, but Am I doing it right? I basically only want to use the http client and slf4j logging

=> This pulls in so many “optional” dependencies, that I do not know if this is correct now. Or if I am missing some compile time dependency.

The following setup works and I can run my app, but whatever I do I cannot get my logging working. It just logs nothing, regardless the log level.

pom.xml => dependencies*

...
        <!-- CONFLUENCE 9 START -->
        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <version>33.0.0-jre</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>commons-codec</groupId>
            <artifactId>commons-codec</artifactId>
            <version>1.16.0</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>commons-io</groupId>
            <artifactId>commons-io</artifactId>
            <version>2.15.1</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-lang3</artifactId>
            <version>3.14.0</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.httpcomponents</groupId>
            <artifactId>httpclient</artifactId>
            <version>4.5.14</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-annotations</artifactId>
            <version>2.16.1</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-core</artifactId>
            <version>2.16.1</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-databind</artifactId>
            <version>2.16.1</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.dataformat</groupId>
            <artifactId>jackson-dataformat-xml</artifactId>
            <version>2.16.1</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.dataformat</groupId>
            <artifactId>jackson-dataformat-yaml</artifactId>
            <version>2.16.1</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>commons-logging</groupId>
            <artifactId>commons-logging</artifactId>
            <version>1.3.0</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-api</artifactId>
            <version>2.22.1</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-core</artifactId>
            <version>2.22.1</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-slf4j-impl</artifactId>
            <version>2.22.1</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>2.0.11</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-slf4j2-impl</artifactId>
            <version>2.22.1</version>
            <scope>compile</scope>
        </dependency>
        <!-- CONFLUENCE 9 END -->
...

pom.xml => excludes and OSGI Imports

<plugin>
    <groupId>com.atlassian.maven.plugins</groupId>
    <artifactId>confluence-maven-plugin</artifactId>
    <version>${amps.version}</version>
    <extensions>true</extensions>
    <configuration>
        <banningExcludes>
            <exclude>com.google.code.findbugs:jsr305</exclude>
            <exclude>com.google.guava:guava</exclude>
            <exclude>commons-io:commons-io</exclude>
            <exclude>org.apache.commons:commons-lang3</exclude>
            <exclude>org.slf4j:slf4j-api</exclude>
            <exclude>org.apache.httpcomponents:httpclient</exclude>
            <exclude>org.apache.httpcomponents:httpcore</exclude>
        </banningExcludes>
        <instructions>
            <Atlassian-Plugin-Key>${atlassian.plugin.key}</Atlassian-Plugin-Key>
            <Export-Package />
            <Import-Package>
                com.atlassian.sal.*,
                !com.google.gson.*,
                !com.google.guava.*,
                !org.apache.commons.codec.binary.*,
                !org.apache.commons.io.*,
                !org.apache.commons.lang3.*,
                !org.apache.http.*,
                !org.codehaus.jackson.*,
                !org.apache.commons.logging.*,
                !org.apache.log.*,
                !org.apache.logging.*,
                !org.slf4j.*,
                javax.jms;resolution:=optional,
                javax.script;resolution:=optional,
                javax.sql;resolution:=optional,
                javax.swing.text;resolution:=optional,
                javax.tools;resolution:=optional,
                javax.transaction.xa;resolution:=optional,
                org.apache.avalon.framework.logger;resolution:=optional,
                org.apache.commons.compress.*;resolution:=optional,
                org.apache.commons.csv.*;resolution:=optional,
                org.apache.kafka.*;resolution:=optional,
                org.brotli.dec.*;resolution:=optional,
                org.conscrypt.*;resolution:=optional,
                com.conversantmedia.util.concurrent.*;resolution:=optional,
                com.lmax.disruptor.*;resolution:=optional,
                org.fusesource.*;resolution:=optional,
                org.ietf.jgss.*;resolution:=optional,
                org.jctools.queues.*;resolution:=optional,
                org.zeromq.*;resolution:=optional,
                *
            </Import-Package>
            <Spring-Context>*</Spring-Context>
        </instructions>
        <allowGoogleTracking>false</allowGoogleTracking>
        <productVersion>${confluence.version}</productVersion>
        <productDataVersion>${confluence.data.version}</productDataVersion>
        <compressJs>false</compressJs>
        <compressCss>false</compressCss>
        <compressResources>false</compressResources>
        <skipManifestValidation>true</skipManifestValidation>
        <enableQuickReload>true</enableQuickReload>
    </configuration>
</plugin>

pom.xml => config

        <confluence.version>9.0.0-m08</confluence.version>
        <confluence.data.version>9.0.0-m08</confluence.data.version>
        <amps.version>8.13.0</amps.version>
        <plugin.testrunner.version>2.0.1</plugin.testrunner.version>
        <atlassian.spring.scanner.version>2.1.10</atlassian.spring.scanner.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <maven.compiler.source>17</maven.compiler.source>
        <maven.compiler.target>17</maven.compiler.target>

QUESTION: Is this “correct”? The official docs on logging and it only says to use slf4j (which I do):

private static final Logger log = LoggerFactory.getLogger(TheCurrentClass.class);

I can see my log entries in the log file. Just want someone to confirm my setup, thanks :slight_smile:

Hi @aorlov,
We have the same problem with our add-on. Did you find any solution for this error?

Unresolved requirements: [307](R 307.0)] osgi.wiring.package; (&(osgi.wiring.package=com.opensymphony.module.propertyset)(version>=1.3.0.21Nov03)(version<=1.3.0.21Nov03))]

I tried to find the dependency with the suggested methods but with no luck.

PS From the dependency tree it seems to be needed by atlassian-user package

[INFO] +- com.atlassian.confluence:confluence:jar:9.0.0-m09:provided
[INFO] |  +- com.atlassian.user:atlassian-user:jar:3.0:provided
[INFO] |  |  \- opensymphony:propertyset:jar:1.3-21Nov03:provided

Hi guys,

is there any equivalent for this method in Confluence >= 9?

pageDao.getContentAuthoredByUser

Cheers

We had the same issue with the opensymphony OSGI loading with the Confluence 8.8 rc.

We worked around it by disabling the dev-mode: -Datlassian.dev.mode=false.
That works for atlas-run and regular setups. Afaik in atlas-debug the dev modes is alway turned on.

2 Likes

Thank you @RomanStoffel, I have tried to disable the atlassian.dev.mode option but we are getting the same error.

Hi guys

I also have a problem with our app

[305](R 305.0)] osgi.wiring.package; (&(osgi.wiring.package=com.atlassian.confluence.upgrade)(version>=9.0.0.m10)(version<=9.0.0.m10))

I tried to add dependency but unfortunately without any significant results, has anyone had a similar problem?

<dependency>
  <groupId>com.atlassian.confluence</groupId>
  <artifactId>confluence-upgrade</artifactId>
  <version>9.0.0-m10</version>
  <scope>provided</scope>
</dependency>

Cheers

Thank you, @RomanStoffel!

The following worked to remove all my dependency issues with OSGi (since RC1) when starting the server with atlas-debug and still allowing to upload artifacts to the running server:

            <atlassian.dev.mode>false</atlassian.dev.mode>
            <upm.plugin.upload.enabled>true</upm.plugin.upload.enabled>

Hi @sax

Unfortunately, not.

I also tried add dependency manually - it doesn’t work.

       <dependency>
            <groupId>opensymphony</groupId>
            <artifactId>propertyset</artifactId>
            <version>1.3-21Nov03</version>
        </dependency>

And I tried to exclude it via settings of my plugin:

<plugin>
                <groupId>com.atlassian.maven.plugins</groupId>
                <artifactId>confluence-maven-plugin</artifactId>
                <version>${amps.version}</version>
                <extensions>true</extensions>
                <configuration>
                    <instructions>
                        <Import-Package>            
                            !com.opensymphony.module.propertyset.*
                        </Import-Package>
                    </instructions>

Still no luck :frowning:

Hi @aorlov,
Yes, I also tried the same steps with no luck.

I created this ticket, hopefully we will get some help from Atlassian Support.

1 Like

HI @sax

if in your case issuing the atlas-package command does not return an error, but the application still does not work properly (there are errors regarding OSGI dependencies), I suggest installing the same JAR/OBR file on Confluence 9 installed according to the standard procedure (not via atlas-run or other atlas-* commands)

I described my case with version 8.8 here Confluence 8.8 is available now - #20 by adam.labus, but I also had problems with it during testing

osgi.wiring.package=com.opensymphony.module.propertyset

Cheers
Adam

Hi @adam.labus,
You are right on Confluence 8.8 our app is also functioning correctly when installed “manually” on a stand alone Confluence instance.

However trying with Confluence 9.0-m09 we get the same error also when installed “manually”.

I guess this is because com.opensymphony.module.propertyset is deprecated in 8.8 but removed in 9.0.

Hopefully we can get some help from Atlassian Support.

Cheers

Do we know when is going to be rectified the differences between dev and prod ?

Thx.

1 Like

@scott.dudley Thank you for your comment. I have the similar issue, I use confluence-compat-lib

Caused by: java.lang.ClassNotFoundException: com.atlassian.util.concurrent.Supplier not found by com.my.plugin

I’ve done:

  1. Excluded this package as you suggested:
<Import-Package>
     .....
     !com.atlassian.util.concurrent.*,
</Import-Package>
  1. Added dependency
<dependency>
            <groupId>com.atlassian.util.concurrent</groupId>
            <artifactId>atlassian-util-concurrent</artifactId>
            <version>3.0.0</version> // we should be compatible Confluence 7.0+
        </dependency>

My plugin starts now, but I have this error:

Class com.atlassian.spring.container.LazyComponentReference does not implement the requested interface com.atlassian.util.concurrent.Supplier

I use spring-scanner.

Did you see this error in your plugin? Maybe you have already find the solution?

Kind regards

2 Likes

@WendyR @Kusal @mkemp any update on the mentioned com.atlassian.confluence.userstatus.* being removed? I didn’t find a solution here on CDAC (or anywhere else). Our app is also affected by this, although in a different way than @rw-dennis is:
We have classes extending com.atlassian.confluence.user.actions.AbstractUserProfileAction, and because that class defines public getters/setters for FavouriteManager and StatusTextRenderer (both coming from com.atlassian.confluence.userstatus.*), then our classes also have a classpath dependency on those Confluence classes (although not actually used in our app’s code) :warning:

How can we resolve this? Please don’t say that we must not extend com.atlassian.confluence.user.actions.AbstractUserProfileAction; that would mean a ton of work for us…

1 Like

We currently use Java configuration for Spring/OSGi in our apps. When attempting to install our apps in Confluence 9, they do not enable. If we make the resolutions optional, we fail with the following error:

Caused by: java.lang.ClassNotFoundException: org.eclipse.gemini.blueprint.service.exporter.support.InterfaceDetector not found by ...

The issue stems from com.atlassian.plugins.osgi.javaconfig.OsgiServices.importOsgiService directly importing/calling code from org.eclipse.gemini.blueprint.*. This package is no longer available as it is in the list of removed APIs for Confluence 9. So, essentially com.atlassian.plugins:atlassian-plugins-osgi-javaconfig no longer appears to be compatible with Confluence 9 (at least out-of-the-box).

We attempted to package org.eclipse.gemini.blueprint:gemini-blueprint-core as compile-time dependency, but this led to a cascade of adding more and more dependencies down the line. In the end, we encountered the following error:

Caused by: java.lang.ArrayStoreException: arraycopy: element type mismatch: can not cast one of the elements of java.lang.Object[] to the type of the 
destination array, org.aopalliance.aop.Advice
        at java.base/java.util.ArrayList.toArray(ArrayList.java:401)
        at org.eclipse.gemini.blueprint.service.util.internal.aop.ProxyUtils.createProxy(ProxyUtils.java:38)

In the OSGi browser, we recognized that org.eclipse.gemini.blueprint.* is still in the Export-Package section of gemini-blueprint-core (and that a couple of Atlassian’s plugins still use it successfully, like, for example, the Troubleshooting & Support plugin). However, our plugin is not able to resolve this import.

So, we examined the Troubleshooting & Support plugin further. It also seems to use com.atlassian.plugins:atlassian-plugins-osgi-javaconfig. We couldn’t find a significant difference to our plugin. Hence, we tried to change the plugin key to start with com.atlassian. Surprisingly, this worked. Now, our plugin enables and can resolve the OSGi import to org.eclipse.gemini.blueprint.*. Is this by design? Of course, this is not a viable option in the end.

We also tried to switch to Spring scanner as an alternative. This also works out in the end, but it would require significant effort to switch all our apps. Considering that there might be other apps in the Atlassian Marketplace that use com.atlassian.plugins:atlassian-plugins-osgi-javaconfig (and as Atlassian also promotes its use in this tutorial to overcome shortcomings of other traditional approaches, including Spring scanner), is there a chance that you will either:

  • Not remove org.eclipse.gemini.blueprint.*?
  • Provide an upgrade for com.atlassian.plugins:atlassian-plugins-osgi-javaconfig that it works without relying on the removed org.eclipse.gemini.blueprint.*?
  • Provide any other alternatives or an upgrade guide for plugins using com.atlassian.plugins:atlassian-plugins-osgi-javaconfig?

Or, is there anything else that we might have overlooked? Any further suggestions are welcome. :slightly_smiling_face:

3 Likes

@WendyR @Kusal @mkemp, additionally, concerning Grey API removal of bucket.*:
How can we use com.atlassian.confluence.user.UserAccessor without having a classpath dependency on bucket.user.UserAccessor (because the former extends the later)? Is com.atlassian.confluence.user.UserAccessor not a public API, intended to be available to 3rd-party apps? Because currently, with Confluence 9.x it’s un-usable, i.e. the app won’t enable, and following log-message appears:

[osgi.hook.dmz.DmzResolverHook] filterMatches Package bucket.user is deprecated and is not available for export to plugin de.communardo.confluence.plugins.userprofile

In our app we have no direct usage of bucket.user.*, so after some investigating I believe the only link to that package is because of com.atlassian.confluence.user.UserAccessor extending bucket.user.UserAccessor.

I see 2 possible solutions, both on Atlassian’s side:

  • Un-remove bucket.* from Grey API removal list
  • Make com.atlassian.confluence.user.UserAccessor NOT extend bucket.user.UserAccessor

How to we proceed from here?

EDIT: I should add that we are still using old-school <component> and <component-import>, and not Spring-Scanner. I start to suspect that we might need to switch to Spring-Scanner, in order to have more control over what OSGi Import-Package statements are actually used. I also think that Spring-Scanner is adding less Import-Package statements in general compared to the older approach with <component> and <component-import>. Any insights someone can share?

1 Like

Hi @matthiasbertsch,

I have no solution to the issue you described, but I encountered this when I started Confluence in the development environment in development mode.

With

<atlassian.dev.mode>false</atlassian.dev.mode>

the injection issues stopped.

Just in case your issue is also only visible in the development environment …

Cheers,
Robert

1 Like

Hi @rr1,

Thank you for your suggestion. Unfortunately, the issue remains the same regardless of whether we are running Confluence in development mode or not.

Just as a data point: We are testing against Confluence 9.0.0-m11.