This article addresses random disconnections in the OneClick WebApp, often accompanied by the messages "Reconnecting" or "Session Ended."
These issues typically occur when memory settings are insufficient or the Webswing configuration contains incorrect port references.
Symptoms
Websocket closed to server [...] close code [1006], reason [Closed abnormally.]* DX Spectrum 25.4.5 (or later)
* Linux Operating System
Insufficient memory allocation for OneClick/Tomcat services or misconfigured webswing.server.publicUrl ports in webswing-admin.properties.
$SPECROOT/webtomcat/webswing/admin/webswing-admin.properties.webswing.server.publicUrl port from 8443 to 9443 (or the correct configured port).-1.web server memory can be adjusted in the Spectrum web page, under Administration, Web Server Memory:
or by editing the xmx value in <SPECROOT>/tomcat/bin/catalina.sh
catalina.sh:224:JAVA_OPTS="-DOneClick -server -Xmx49152M -Xms4096M -XX:+UseG1GC -XX:G1HeapRegionSize=8M -XX:G1HeapWastePercent=5 -XX:MaxGCPauseMillis=800 -XX:SurvivorRatio=8 -Dsun.net.inetaddr.ttl=60 -XX:+HeapDumpOnOutOfMemoryError -Djava.awt.headless=true -Djavax.net.ssl.trustStore=$SPECROOT/custom/keystore/cacerts -Dfile.encoding=UTF-8 -Dorg.xerial.snappy.tempdir=$SPECROOT/tmp -Dorg.apache.coyote.USE_CUSTOM_STATUS_MSG_IN_HEADER=true -Dlog4j2.enabled=true -Djdk.corba.allowInputStreamSubclass=true -Djdk.corba.allowOutputStreamSubclass=true -Djavax.xml.soap.SAAJMetaFactory=com.sun.xml.messaging.saaj.soap.SAAJMetaFactoryImpl --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED --add-opens=java.base/javax.crypto=ALL-UNNAMED -Dlog4j2.enabled=true"