Support Article
WebSocket error occurs when accessing Designer Studio
SA-67932
Summary
WebSocket error occurs on the Web Server log when accessing Designer Studio through the Apache Web Server.
This occurs when using the below Techstack.
- Pega Platform 7.4
- Windows Server 2012 R2
- Oracle Database 12c R2
- Apache Tomcat 8.5 (Tomcat)
- Apache HTTP Server 2.4 (Apache)
Error Messages
org.apache.catalina.core.StandardWrapperValve.invoke sevlet [WebStandardAsync] Servlet.service() exception
java.lang.UnsupportedOperationException: HTTP upgrade is not supported by this protocol
Steps to Reproduce
- Set up an HTTP server in front of the Tomcat server.
- Access the application through the HTTP server.
- Log in and launch Pega Designer Studio.
Root Cause
Apache Web Server as a Reverse proxy did not have the correct setting to support the WebSocket protocol.
Resolution
To set the Reverse proxy, set the WebSocket protocol for the WebStandardAsync servlet path.
For example,
Apache HTTP server requires the loading of the wstunnel proxy module and the correct servlet path proxied by referring Pega's Install media.
- On the Module loading part, include the below setting,
LoadModule proxy_wstunnel_module modules/mod_proxy_wstunnel.so
- Include the below Location and proxy directives:
<Location /prweb/PRPushServlet>
ProxyPass /prweb/PRPushServlet ws://localhost:8080/prweb/PRPushServlet/
ProxyPassReverse /prweb/PRPushServlet ws://localhost:8080/prweb/PRPushServlet/
</Location>
- Refer the proxied path (URI path) to the WEB-INF/web.xml in the prweb.war of Pega's Install media.
..
<servlet-mapping>
<servlet-name>WebStandardAsync</servlet-name>
<url-pattern>/PRPushServlet</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>WebStandardAsync</servlet-name>
<url-pattern>/PRPushServlet/*</url-pattern>
</servlet-mapping>
..
Published August 19, 2019 - Updated December 2, 2021
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.