The reconnection mechanism seem to be broken in Agent Linux/Unix, opposed to Agents Windows / RA / Java Agents.
In an Engine with 2 JCPs started (one listening on port 8443 and another on 8444), if we stop the JCP to which the Agent Linux/Unix was connected, the Agent will try immediately to reconnect as expected but this never will succeed.
Then it will wait for 600s as it's the default re-connection time.
Here is the snippet of the problem on the Agent Unix:
20221028/083214.522 - U02000010 Connection to Server 'AUTOMIC/unknown' terminated. MESSAGE BELOW INDICATES THAT THE RECONNECTION WILL BE DONE ON 600s 20221028/083214.522 - U02000355 CP selection has been finished but no suitable CP was found. Next reconnect after '600' seconds. BUT AS SEEN BELOW, THE RECONNECTION ATTEMPT IS DONE RIGHT AWAY AS EXPECTED 20221028/083214.844 - U02000004 Connection to Server 'AUTOMIC#CP002' successfully created. 20221028/083214.845 - U02000314 Initial challenge has been requested. PROBLEM ABOVE -- somehow this initial challenge is not sent to the correct JCP port, this is why it never works and after the 600 seconds above the reconnection timer expires and this time it works 20221028/084214.523 - U02000072 Connection to system 'AUTOMIC' initiated. 20221028/084214.523 - U02000379 Initiating connection to server 'AUTOMIC' using WebSocket URI: 'JCP_SERVER_NAME:8443/agent'. ...20221028/084214.543 - U02000314 Initial challenge has been requested. 20221028/084214.549 - U02000401 Received JCP server list: 'https://JCP_SERVER_NAME:8443/' 20221028/084214.594 - U02000316 Challenge procedure has been successfully performed.
Expected Behavior: Same as Agent Windows, RA, in case of connection lost, the re-connection should be immediate to the other JCPs defined in JCP_LIST and this challenge should work fine.
Actual behavior: The immediate re-connection seems to be attempted wrongly as the "Initial challenge has been requested" never works on Agent Unix/Linux.
Release : 21.x
Component: Agent Unix/Linux
Defect
Update to a fix version listed below or a newer version if available.
Fix version:
Component(s): Agent Unix
Automation.Engine 21.0.5