Help with NoClassDefFoundError and Connection Reset by Peer Causing Infinite Logging

  • Issue Overview: Encountering java.lang.NoClassDefFoundError: com/solacesystems/common/util/ThreadUtil in Catalina log, causing infinite logging (~5GB disk usage), and java.io.IOException: Connection reset by peer in application log, indicating Solace broker connection failure. Application (Tomcat, Java 1.8.0_442, Solace JMS 10.8.1) terminates unexpectedly.
  • Steps Taken: Verified sol-common-10.8.1.jar contains com.solacesystems.common.util.ThreadUtil.class (via jar tf), ensured all Solace JARs (version 10.8.1) are in $CATALINA_HOME/lib, tested JAR integrity, confirmed intermittent broker connectivity, truncated catalina.out, set log4j.logger.com.solacesystems=ERROR, and configured reconnectRetries=5, reconnectRetryWait=1000.
  • Questions:
    • Why does NoClassDefFoundError occur despite ThreadUtil being present in sol-common-10.8.1.jar? Is it a classloader or runtime issue?
    • What causes the Connection reset by peer error, and which client/broker settings (e.g., VPN, authentication) should I check?
    • How can I prevent infinite logging? Are there Solace client settings to limit reconnection attempts or suppress repeated exceptions?
  • Additional Notes: Application processes messages successfully before failure. Can provide sanitized logs or configuration details if needed. Thank you for any insights!

Hi there, I’m Solly AI, I generate responses to your questions using the power of the Solace Agent Mesh:

Please remember that AI technology can make mistakes so ensure that you read our Disclaimer.

AI Generated responses are a work in progress, your help in evaluating my response would be awesome! If my response makes sense, please mark it as a solution or give a :+1:. If my response doesn’t make sense for your topic, please react to it with a :shaking_face:.

For the NoClassDefFoundError and connection reset issues, here’s what the documentation indicates:

  1. For NoClassDefFoundError:
  • Java version compatibility is a key factor - version 10.10 was the last version of the Solace Java API that supported Java versions prior to 1.8
  • For applications using Java 1.6, you should use Solace JMS API version 10.9 or 10.10
  • The error typically occurs when required classes are not found in the classpath
  1. For connection reset/timeout issues:
  • Connection timeouts can occur due to network connectivity problems
  • The issue may be related to how connections are being managed (setting up/tearing down connections for each message instead of maintaining persistent connections)
  • Using JMS Output nodes with configurable services is recommended over setting up new connections for each message when working with high throughput scenarios

Relevant sources:

For specific configuration steps and troubleshooting commands, please refer to the Solace documentation.