<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style></head><body lang=SL link=blue vlink="#954F72"><div class=WordSection1><p class=MsoNormal><span lang=EN-US>Hey Sanne,<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>This error comes from jboss-modules and its maven loader.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>We do try to load settings.xml and read configuration for remote repositories as well as local repositories (if user doesn’t use standard .m2/repository)<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>There are two system properties you can pass to the server to tell him where to look<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>To define remote repo to look at:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>-Dremote.maven.repo=http://path/to/repo<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>To define local repo to load from<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>-Dmaven.repo.local=/path/on/local/disk<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>To tell him custom settings.xml should be used<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>-jboss.modules.settings.xml.url=file://path/to/settings.xml<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Also usually it is a good practice that in testsuite you pass local repo to surefire.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>This works great in cases users have custom settings and you can just pass them from current maven execution settings<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Adding something like <o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>-Dmaven.repo.local=${settings.localRepository}<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>To surefire args or sys props passed to Wildfly it should resolve most of issues users could face.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>When it comes to improving error reporting, sure that should be done.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>--<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>tomaz<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><o:p> </o:p></p><div style='mso-element:para-border-div;border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal style='border:none;padding:0cm'><b>From: </b><a href="mailto:sanne@hibernate.org">Sanne Grinovero</a><br><b>Sent: </b>sreda, 24. januar 2018 11:46<br><b>To: </b><a href="mailto:wildfly-dev@lists.jboss.org">Wildfly Dev mailing list</a><br><b>Subject: </b>[wildfly-dev] WildFly provisioned "thin" giving confusing errors onincorrect global Maven settings</p></div><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>TLDR: provisioning works fine, booting the server works not.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Hi all,</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>with all Hibernate ORM contributors now forced to run WildFly</p><p class=MsoNormal>"provisioned in thin format" for integration tests, several people</p><p class=MsoNormal>have been reporting cryptic errors such as:</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal> Failed to resolve artifact 'xerces:xercesImpl:2.11.0.SP5'</p><p class=MsoNormal>(position: END_TAG seen ...resources>\n <artifact</p><p class=MsoNormal>name="xerces:xercesImpl:2.11.0.SP5"/>... @26:56)</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>The common pattern seems to be an exception reported as "Caused by:</p><p class=MsoNormal>org.jboss.modules.xml.XmlPullParserException".</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Turns out the problem is that they didn't have the JBoss Nexus</p><p class=MsoNormal>repository activated.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>The provisioning tool is running with the JBoss repository being</p><p class=MsoNormal>enabled - as I hardcoded this as a default - so the dependencies are</p><p class=MsoNormal>actually copied into the local cache, but Maven (Aether) is keeping</p><p class=MsoNormal>track of these being sourced from the JBoss Nexus, so these</p><p class=MsoNormal>dependencies are unresolvable when a subsequent process is started</p><p class=MsoNormal>without having the JBoss Nexus repository enabled.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>This could be caused by not having activated some Maven profile, or</p><p class=MsoNormal>simply because the user doesn't mention the JBoss Nexus at all in his</p><p class=MsoNormal>Maven global settings file, or has no global file at all.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>There's a number of open JIRAs and StackOverflow questions related,</p><p class=MsoNormal>people are a bit lost and it seems a widespread problem [1].</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I'm looking for two things:</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal> A# Could the exception be made clearer? It seems to suggest the XML</p><p class=MsoNormal>is malformed, or perhaps the download corrupted, the local Maven cache</p><p class=MsoNormal>needing to be nuked.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal> B# Is there a way to boot WildFly with custom Maven configuration</p><p class=MsoNormal>settings? I would want to avoid having all contributors to have to</p><p class=MsoNormal>figure out they have to adjust their global Maven settings.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I guess in an ideal world we'd also want to avoid needing any</p><p class=MsoNormal>dependency which isn't available in Maven Central, but that seems an</p><p class=MsoNormal>harder, long term goal.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>For the time being I'll be changing our builds to use the provisioning</p><p class=MsoNormal>but avoiding the "thin" format; I'm a bit sad about that as it was</p><p class=MsoNormal>very convenient, so I'm looking forward for better suggestions :)</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Thanks,</p><p class=MsoNormal>Sanne</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>1 - https://stackoverflow.com/questions/41826619/wildfly-swarm-deployment-issue-failed-to-resolve-artifact-xalanserializer2</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>_______________________________________________</p><p class=MsoNormal>wildfly-dev mailing list</p><p class=MsoNormal>wildfly-dev@lists.jboss.org</p><p class=MsoNormal>https://lists.jboss.org/mailman/listinfo/wildfly-dev</p><p class=MsoNormal><o:p> </o:p></p></div></body></html>