Configuring the Mode for Agents to Log In to the CC-Gateway
Before integration development of agent capabilities, you need to configure the mode for agents to log in to the CC-Gateway. You can use either the HTTPS or WebSocket mode. You can determine whether to use the HTTPS or WebSocket mode based on configuration files.
To change the login mode, you need to modify parameters in the CC-Gateway configuration files. If the NSLB is used, ensure that proxy policies exist for both modes in the NSLB.
The WebSocket mode cannot be used in integrated deployment scenarios. If both WebSocket and HTTPS modes need to be used, you can prepare a dedicated CC-Gateway server and add routing rules on the NSLB to route WebSocket requests to the dedicated CC-Gateway server.
Modifying the CC-Gateway Configuration Files
- In the /home/elpis/tomcat/webapps/agentgateway/WEB-INF/config/basic.properties file, modify the configuration as required.
WEBSOCKET_PROTOCOL_SWITCH = OFF (The default value OFF indicates that the HTTPS mode is used.) WEBSOCKET_PROTOCOL_SWITCH = ON (The value ON indicates that the WebSocket mode is used.)
- In the /home/elpis/tomcat/conf/catalina.properties file, modify the configuration as required.
openas.annotation.enable = true (The value true indicates that the WebSocket mode is used.) openas.annotation.enable = false (The value false indicates that the HTTPS mode is used.)
Modifying NSLB Routing Rules
You have configured the mode for agents to log in to the CC-Gateway by modifying the CC-Gateway configuration files basic.properties and catalina.properties. However, if requests are transmitted to the CC-Gateway through the NSLB, you need to configure the JSON rules of the NSLB. The NSLB can function as a proxy for both HTTPS and WebSocket modes at the same time.
Go to /home/nslb/aicc_nslbrule and find the JSON rule files corresponding to the two modes.
- ccgateway_proxy.json: used for the HTTPS mode
- ccgateway_websocket_proxy.json: used for the WebSocket mode
name==aicc-gw-wss (Change the default name to a customized one, for example, aicc-gw-wss and avoid setting it to the same name as that of the HTTPS mode.) listen==38043 (Change the default value 8043 to a customized value, for example, 38043 and avoid setting it to 8043, which is the default value of the HTTPS mode.)
$ nslbctl import ccgateway_websocket_proxy.json append
A message is displayed, indicating that the import is successful.
# nslbctl list
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot