Your browser was unable to load all of the resources. They may have been blocked by your firewall, proxy or browser configuration.
Press Ctrl+F5 or Ctrl+Shift+R to have your browser try again.

It appears that there may be a mismatch in the library versions on the Windows 10 build agent. #4563

xema027 ·

OS : Windows10 Enterprise
Java : OpenJDK 17
QB version : 13.0.5

Publish > Artifacts 

Source Directory
${groovy: return "C:\\"}

Files To Publish
**

I have been using a build agent on a Linux environment without any problems.
However, when I set up the build agent on a Windows environment, it fails at a specific step.

I am attempting to recreate the steps mentioned, but I encounter an error like below.

<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1"/>
<title>Error 500 java.lang.NoClassDefFoundError: Could not initialize class org.apache.commons.lang.SystemUtils</title>
</head>
<body><h2>HTTP ERROR 500 java.lang.NoClassDefFoundError: Could not initialize class org.apache.commons.lang.SystemUtils</h2>
<table>
<tr><th>URI:</th><td>/file_transfer</td></tr>
<tr><th>STATUS:</th><td>500</td></tr>
<tr><th>MESSAGE:</th><td>java.lang.NoClassDefFoundError: Could not initialize class org.apache.commons.lang.SystemUtils</td></tr>
<tr><th>SERVLET:</th><td>com.pmease.quickbuild.grid.FileTransferServlet-78fa8b13</td></tr>
<tr><th>CAUSED BY:</th><td>java.lang.NoClassDefFoundError: Could not initialize class org.apache.commons.lang.SystemUtils</td></tr>
</table>
<h3>Caused by:</h3><pre>java.lang.NoClassDefFoundError: Could not initialize class org.apache.commons.lang.SystemUtils
    at com.pmease.quickbuild.util.FileUtils.listFiles(FileUtils.java:494)
    at com.pmease.quickbuild.grid.FileTransferServlet.doGet(FileTransferServlet.java:83)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:687)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
    at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:799)
    at org.eclipse.jetty.servlet.ServletHandler$ChainEnd.doFilter(ServletHandler.java:1631)
    at com.pmease.quickbuild.Quickbuild$DisableTraceFilter.doFilter(Quickbuild.java:1278)
    at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193)
    at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601)
    at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:548)
    at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233)
    at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1624)
    at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233)
    at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1440)
    at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188)
    at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:501)
    at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1594)
    at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186)
    at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1355)
    at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
    at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:146)
    at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
    at org.eclipse.jetty.server.Server.handle(Server.java:516)
    at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:487)
    at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:732)
    at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:479)
    at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277)
    at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
    at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105)
    at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104)
    at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:338)
    at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:315)
    at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:173)
    at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131)
    at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:409)
    at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883)
    at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034)
    at java.base/java.lang.Thread.run(Thread.java:833)
</pre>

</body>
</html>

It seems that QB internally uses an Apache library, which does not support Windows 10. (commons-lang-2.4.jar)

Is there another way to upgrade the build agent to a higher version or update the library version?

  • replies 5
  • views 601
  • stars 0
robinshen ADMIN ·

This works fine at my side. Probably some files of your windows build agent is corrupted. Please download and install agent again to see if it fixes the issue.

xema027 ·

I have finally found the cause of the error.
Previously, I was using the OpenJDK 17 version, but after downgrading to the OpenJDK 8 version with the Zulu build, it works normally.

It is believed that a particular Java build caused an exception throw in SystemUtils.getJavaVersionAsFloat() of Apache Lang, resulting in this issue.
I believe that this issue does not occur in Lang3, so I suggest migrating in the future.

robinshen ADMIN ·

Which openjdk distribution are you using? I tested with Oracle JDK 17 and it is working.

xema027 ·

I am using Oracle's OpenJDK as well. It appears that this was likely an environmental issue on our end. The problem has been resolved, so you may close this issue. Thank you for your assistance.

robinshen ADMIN ·

Thanks for the info.