This is an automated email from the ASF dual-hosted git repository.
epugh pushed a commit to branch branch_9x
in repository https://gitbox.apache.org/repos/asf/solr.git
The following commit(s) were added to refs/heads/branch_9x by this push:
new 2e5ff51 SOLR-15923: Cue users on 404 that Solr is responding (#535)
2e5ff51 is described below
commit 2e5ff519e70086c602f439e54ec22e017350a8cf
Author: Eric Pugh <[email protected]>
AuthorDate: Wed Jan 26 11:08:36 2022 -0500
SOLR-15923: Cue users on 404 that Solr is responding (#535)
* provide solr specific 404 to cue users that solr is responding
* there are better poets than I in the community!
---
solr/webapp/web/WEB-INF/web.xml | 9 +++++++--
solr/webapp/web/error404.html | 5 +++++
2 files changed, 12 insertions(+), 2 deletions(-)
diff --git a/solr/webapp/web/WEB-INF/web.xml b/solr/webapp/web/WEB-INF/web.xml
index 33cad1f..dfc0c0c 100644
--- a/solr/webapp/web/WEB-INF/web.xml
+++ b/solr/webapp/web/WEB-INF/web.xml
@@ -29,7 +29,7 @@
<filter-name>SolrRequestFilter</filter-name>
<filter-class>org.apache.solr.servlet.SolrDispatchFilter</filter-class>
<!--
- Exclude patterns is a list of directories that would be short circuited by
the
+ Exclude patterns is a list of directories that would be short circuited by
the
SolrDispatchFilter. It includes all Admin UI related static content.
NOTE: It is NOT a pattern but only matches the start of the HTTP
ServletPath.
-->
@@ -98,5 +98,10 @@
<servlet-name>RedirectOldZookeeper</servlet-name>
<url-pattern>/zookeeper</url-pattern>
</servlet-mapping>
--->
+-->
+
+ <error-page>
+ <error-code>404</error-code>
+ <location>/error404.html</location>
+ </error-page>
</web-app>
diff --git a/solr/webapp/web/error404.html b/solr/webapp/web/error404.html
new file mode 100644
index 0000000..7791171
--- /dev/null
+++ b/solr/webapp/web/error404.html
@@ -0,0 +1,5 @@
+<p>
+ Searching for Solr?<br/>
+ You must type the correct path.<br/>
+ Solr will respond.
+</p>