<div dir="ltr">FWIW I tested with the following and it worked fine on WIldFly 10.1.0.Final and WildFly 11.0.0.Beta1 for me.<div><br></div><div><div><font face="monospace, monospace">cd ./wildfly-10.1.0.Final</font></div><div><font face="monospace, monospace">LOGMANAGER_JAR=$(find $(pwd) -name 'jboss-logmanager-*.jar')</font></div><div><font face="monospace, monospace">export JAVA_OPTS="-Djboss.modules.system.pkgs=org.jboss.logmanager \</font></div><div><font face="monospace, monospace">-Djava.util.logging.manager=org.jboss.logmanager.LogManager \</font></div><div><font face="monospace, monospace">-Dsun.util.logging.disableCallerCheck=true \</font></div><div><font face="monospace, monospace">-Xbootclasspath/a:${LOGMANAGER_JAR}"</font></div><div><font face="monospace, monospace">./bin/standalone.sh</font></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Sep 27, 2017 at 8:16 AM, James Perkins <span dir="ltr"><<a href="mailto:jperkins@redhat.com" target="_blank">jperkins@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">My apologies for misunderstanding. The -Xbootclasspath/a is still supported which would likely work for you.</div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Sep 27, 2017 at 7:07 AM, Fabian Stäber <span dir="ltr"><<a href="mailto:fabian@fstab.de" target="_blank">fabian@fstab.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>
<br>
I am sorry, but I still don't get it.<br>
<br>
My agent initializes the java.util.logging.manager (indirectly, because it registers a JMX bean, and platform MBean server has an internal dependency to logging). This is done before any Wildfly code is loaded.<br>
<br>
I understand that this works with Wildfly only if the agent uses org.jboss.logmanager.LogManage<wbr>r as the log manager implementation. With Java 8, this can be done with the following start script:<br>
<br>
cd ./wildfly-10.1.0.Final<br>
LOGMANAGER_JAR=$(find $(pwd) -name 'jboss-logmanager-*.jar')<br>
export JAVA_OPTS="<br>
-Xbootclasspath/p:${LOGMANAGER<wbr>_JAR}<br>
-Djboss.modules.system.pkgs=or<wbr>g.jboss.logmanager,io.promagen<wbr>t.agent<br>
-Djava.util.logging.manager=or<wbr>g.jboss.logmanager.LogManager<br>
-javaagent:promagent.jar=port=<wbr>9300<br>
"<br>
./bin/standalone.sh<br>
<br>
The question is, how do I make jboss-logmanager-2.0.7.Final.j<wbr>ar available to the agent's class loader with Java 9? The "-Xbootclasspath/p:" option was removed, but the agent needs access to the org.jboss.logmanager.LogManage<wbr>r class to initialize logging correctly (Wildfly doesn't seem to run when the agent initializes logging with the default log manager).<br>
<br>
Thanks for your help<br>
<span class="m_-3266563528070080537HOEnZb"><font color="#888888">Fabian<br>
</font></span><div class="m_-3266563528070080537HOEnZb"><div class="m_-3266563528070080537h5"><br>
On Wed, Sep 27, 2017 at 11:45:12AM +0200, Tomaž Cerar wrote:<br>
> Hey,<br>
> Keep in mind that while WildFly 11 does run fine on JDK9.<br>
> It still does that in »classpath« mode not in pure modular(jigsaw) fashion.<br>
><br>
> As such –patch-module for WildFly modules (jboss-modules) does not apply (yet)<br>
><br>
> You should be fine by just using your agent with jboss-modules on CP and system property that James suggested.<br>
><br>
> --<br>
> Tomaz<br>
><br>
> From: James Perkins<br>
> Sent: sreda, 27. september 2017 02:45<br>
> To: Fabian Stäber<br>
> Cc: <a href="mailto:wildfly-dev@lists.jboss.org" target="_blank">wildfly-dev@lists.jboss.org</a><br>
> Subject: Re: [wildfly-dev] Equivalent to-Xbootclasspath/p:jboss-logm<wbr>anager-2.0.7.Final.jar in Java 9<br>
><br>
> There is a system property you need to add to the JAVA_OPTS IIRC. Try adding "-Dsun.util.logging.disableCal<wbr>lerCheck=true". This should avoid the weird issues with the log manager.<br>
><br>
> On Tue, Sep 26, 2017 at 2:18 PM, Fabian Stäber <<a href="mailto:fabian@fstab.de" target="_blank">fabian@fstab.de</a>> wrote:<br>
> Hello,<br>
><br>
> sorry if this is the wrong place to ask, but I am trying to run a Java agent with Wildfly 11 and Java 9. In previous Java versions, I had to add -Xbootclasspath/p:jboss-logman<wbr>ager-2.0.7.Final.jar to JAVA_OPTS to make sure the Wildfly java.util.logging.manager implementation is available to the agent.<br>
><br>
> I understand that in Java 9 the -Xbootclasspath/p option is replaced with the --patch-module option. However, I am having trouble to figure out how to use this option.<br>
><br>
> What is the equivalent to -Xbootclasspath/p:jboss-logman<wbr>ager-2.0.7.Final.jar is in Java 9 with Wildfly 11?<br>
><br>
> Thanks a lot<br>
> Fabian<br>
> ______________________________<wbr>_________________<br>
> wildfly-dev mailing list<br>
> <a href="mailto:wildfly-dev@lists.jboss.org" target="_blank">wildfly-dev@lists.jboss.org</a><br>
> <a href="https://lists.jboss.org/mailman/listinfo/wildfly-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/mailma<wbr>n/listinfo/wildfly-dev</a><br>
><br>
><br>
><br>
><br>
> --<br>
> James R. Perkins<br>
> JBoss by Red Hat<br>
><br>
______________________________<wbr>_________________<br>
wildfly-dev mailing list<br>
<a href="mailto:wildfly-dev@lists.jboss.org" target="_blank">wildfly-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/wildfly-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/mailma<wbr>n/listinfo/wildfly-dev</a></div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="m_-3266563528070080537gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>James R. Perkins</div><div>JBoss by Red Hat</div></div></div></div></div>
</div>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>James R. Perkins</div><div>JBoss by Red Hat</div></div></div></div></div>
</div>