Static content location does not work in EAP undertow mod_cluster balancer
Issue
- We use and EAP 7 instance as an undertow/mod_cluster balancer to other EAP instances. We added a file handler for static content to this balancer instance, but all requests for that content 404:
<subsystem xmlns="urn:jboss:domain:undertow:4.0">
<buffer-cache name="default"/>
<server name="default-server">
<http-listener name="default" socket-binding="http" redirect-socket="https" enable-http2="true"/>
<http-listener name="management" socket-binding="mcmp-management" enable-http2="true"/>
<host name="default-host" alias="localhost">
<location name="/static" handler="static"/>
<filter-ref name="load-balancer"/>
</host>
</server>
<servlet-container name="default"/>
<handlers>
<file name="static" directory-listing="true" path="/path/to/static/content"/>
</handlers>
<filters>
<mod-cluster name="load-balancer" management-socket-binding="mcmp-management" advertise-socket-binding="modcluster" advertise-protocol="ajp"/>
</filters>
</subsystem>
Environment
- JBoss Enterprise Application Platform (EAP) 7.x
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.