You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-dev@lucene.apache.org by "Hoss Man (JIRA)" <ji...@apache.org> on 2009/01/16 21:01:02 UTC
[jira] Created: (SOLR-965) Better exception logging when no ping
query configured
Better exception logging when no ping query configured
------------------------------------------------------
Key: SOLR-965
URL: https://issues.apache.org/jira/browse/SOLR-965
Project: Solr
Issue Type: Improvement
Reporter: Hoss Man
user noted that with the example multicore configs, http://localhost:8983/solr/core1/admin/ping results in a 500 error and logs quite a bit of crap starting with a NullPointerException.
The failing ping is the correct behavior, because the example multicore configs don't define a pingQuery -- but the code path of the failure and the exceptions logged are less then ideal. ping.jsp (which is still used if the PingRequestHandler doesn't get registered) and SolrConfig.getPingQueryRequest should me modified to log an (on topic) error and fail fast when there is no <pingQuery> declaration.
A quick skim of PingRequestHandlers suggests we may also want to add some better logging (specifically: warnings about configuring it with good defaults) if it gets called without any params.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (SOLR-965) Better exception logging when no ping
query configured
Posted by "Hoss Man (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-965?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hoss Man updated SOLR-965:
--------------------------
Affects Version/s: 1.3
Fix Version/s: 1.4
> Better exception logging when no ping query configured
> ------------------------------------------------------
>
> Key: SOLR-965
> URL: https://issues.apache.org/jira/browse/SOLR-965
> Project: Solr
> Issue Type: Improvement
> Affects Versions: 1.3
> Reporter: Hoss Man
> Fix For: 1.4
>
>
> user noted that with the example multicore configs, http://localhost:8983/solr/core1/admin/ping results in a 500 error and logs quite a bit of crap starting with a NullPointerException.
> The failing ping is the correct behavior, because the example multicore configs don't define a pingQuery -- but the code path of the failure and the exceptions logged are less then ideal. ping.jsp (which is still used if the PingRequestHandler doesn't get registered) and SolrConfig.getPingQueryRequest should me modified to log an (on topic) error and fail fast when there is no <pingQuery> declaration.
> A quick skim of PingRequestHandlers suggests we may also want to add some better logging (specifically: warnings about configuring it with good defaults) if it gets called without any params.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (SOLR-965) Better exception logging when no ping
query configured
Posted by "Hoss Man (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-965?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hoss Man resolved SOLR-965.
---------------------------
Resolution: Fixed
Assignee: Hoss Man
thanks mark ... i added a little warning logging on init if hte deprecated feature was used, and tweaked your error message so it directed people to use PingRequestHandler instead of the old admin/pingQuery if they ever encountered that error.
Committed revision 769574.
> Better exception logging when no ping query configured
> ------------------------------------------------------
>
> Key: SOLR-965
> URL: https://issues.apache.org/jira/browse/SOLR-965
> Project: Solr
> Issue Type: Improvement
> Affects Versions: 1.3
> Reporter: Hoss Man
> Assignee: Hoss Man
> Fix For: 1.4
>
> Attachments: SOLR-965.patch
>
>
> user noted that with the example multicore configs, http://localhost:8983/solr/core1/admin/ping results in a 500 error and logs quite a bit of crap starting with a NullPointerException.
> The failing ping is the correct behavior, because the example multicore configs don't define a pingQuery -- but the code path of the failure and the exceptions logged are less then ideal. ping.jsp (which is still used if the PingRequestHandler doesn't get registered) and SolrConfig.getPingQueryRequest should me modified to log an (on topic) error and fail fast when there is no <pingQuery> declaration.
> A quick skim of PingRequestHandlers suggests we may also want to add some better logging (specifically: warnings about configuring it with good defaults) if it gets called without any params.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (SOLR-965) Better exception logging when no ping
query configured
Posted by "Hoss Man (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-965?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12664653#action_12664653 ]
Hoss Man commented on SOLR-965:
-------------------------------
example of the exception in case anyone searches for it...
{noformat}
SEVERE: java.lang.NullPointerException
at org.apache.solr.common.util.StrUtils.splitSmart(StrUtils.java:37)
at org.apache.solr.search.OldLuceneQParser.parse(LuceneQParserPlugin.java:103)
at org.apache.solr.search.QParser.getQuery(QParser.java:126)
at org.apache.solr.handler.component.QueryComponent.prepare(QueryComponent.java:82)
at org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:150)
at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:131)
at org.apache.solr.core.SolrCore.execute(SolrCore.java:1325)
at org.apache.solr.core.SolrCore.execute(SolrCore.java:1349)
at org.apache.jsp.admin.ping_jsp._jspService(org.apache.jsp.admin.ping_jsp:180)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:80)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:373)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:464)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:358)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
...
{noformat}
> Better exception logging when no ping query configured
> ------------------------------------------------------
>
> Key: SOLR-965
> URL: https://issues.apache.org/jira/browse/SOLR-965
> Project: Solr
> Issue Type: Improvement
> Reporter: Hoss Man
>
> user noted that with the example multicore configs, http://localhost:8983/solr/core1/admin/ping results in a 500 error and logs quite a bit of crap starting with a NullPointerException.
> The failing ping is the correct behavior, because the example multicore configs don't define a pingQuery -- but the code path of the failure and the exceptions logged are less then ideal. ping.jsp (which is still used if the PingRequestHandler doesn't get registered) and SolrConfig.getPingQueryRequest should me modified to log an (on topic) error and fail fast when there is no <pingQuery> declaration.
> A quick skim of PingRequestHandlers suggests we may also want to add some better logging (specifically: warnings about configuring it with good defaults) if it gets called without any params.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (SOLR-965) Better exception logging when no ping
query configured
Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-965?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mark Miller updated SOLR-965:
-----------------------------
Attachment: SOLR-965.patch
Here is a simple patch that throws and exception if the ping query params are 0.
In the multicore scenario, you get:
HTTP ERROR: 500
Ping requires that the PingRequestHandler, admin/pingQuery is defined in solrconfig.xml with both QT and Q params
java.lang.IllegalStateException: Ping requires that the PingRequestHandler, admin/pingQuery is defined in solrconfig.xml with both QT and Q params
at org.apache.solr.core.SolrConfig.getPingQueryRequest(SolrConfig.java:228)
at org.apache.solr.core.SolrCore.getPingQueryRequest(SolrCore.java:781)
at org.apache.jsp.admin.ping_jsp._jspService(org.apache.jsp.admin.ping_jsp:177)
I couldn't get the current ping.jsp error handling to work - I would get state exceptions errors that the response was already committed if a resp.sendError was hit
in the jsp. So I just throw an exception instead, and the dispatchfilter catches the exception and does the resp.sendError.
- Mark
> Better exception logging when no ping query configured
> ------------------------------------------------------
>
> Key: SOLR-965
> URL: https://issues.apache.org/jira/browse/SOLR-965
> Project: Solr
> Issue Type: Improvement
> Affects Versions: 1.3
> Reporter: Hoss Man
> Fix For: 1.4
>
> Attachments: SOLR-965.patch
>
>
> user noted that with the example multicore configs, http://localhost:8983/solr/core1/admin/ping results in a 500 error and logs quite a bit of crap starting with a NullPointerException.
> The failing ping is the correct behavior, because the example multicore configs don't define a pingQuery -- but the code path of the failure and the exceptions logged are less then ideal. ping.jsp (which is still used if the PingRequestHandler doesn't get registered) and SolrConfig.getPingQueryRequest should me modified to log an (on topic) error and fail fast when there is no <pingQuery> declaration.
> A quick skim of PingRequestHandlers suggests we may also want to add some better logging (specifically: warnings about configuring it with good defaults) if it gets called without any params.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Issue Comment Edited: (SOLR-965) Better exception logging
when no ping query configured
Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-965?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12702388#action_12702388 ]
Mark Miller edited comment on SOLR-965 at 4/24/09 7:28 AM:
-----------------------------------------------------------
Here is a simple patch that throws an exception if the ping query params are 0.
In the multicore scenario, you get:
HTTP ERROR: 500
Ping requires that the PingRequestHandler, admin/pingQuery is defined in solrconfig.xml with both QT and Q params
java.lang.IllegalStateException: Ping requires that the PingRequestHandler, admin/pingQuery is defined in solrconfig.xml with both QT and Q params
at org.apache.solr.core.SolrConfig.getPingQueryRequest(SolrConfig.java:228)
at org.apache.solr.core.SolrCore.getPingQueryRequest(SolrCore.java:781)
at org.apache.jsp.admin.ping_jsp._jspService(org.apache.jsp.admin.ping_jsp:177)
I couldn't get the current ping.jsp error handling to work - I would get state exceptions errors that the response was already committed if a resp.sendError was hit
in the jsp. So I just throw an exception instead, and the dispatchfilter catches the exception and does the resp.sendError.
- Mark
was (Author: markrmiller@gmail.com):
Here is a simple patch that throws and exception if the ping query params are 0.
In the multicore scenario, you get:
HTTP ERROR: 500
Ping requires that the PingRequestHandler, admin/pingQuery is defined in solrconfig.xml with both QT and Q params
java.lang.IllegalStateException: Ping requires that the PingRequestHandler, admin/pingQuery is defined in solrconfig.xml with both QT and Q params
at org.apache.solr.core.SolrConfig.getPingQueryRequest(SolrConfig.java:228)
at org.apache.solr.core.SolrCore.getPingQueryRequest(SolrCore.java:781)
at org.apache.jsp.admin.ping_jsp._jspService(org.apache.jsp.admin.ping_jsp:177)
I couldn't get the current ping.jsp error handling to work - I would get state exceptions errors that the response was already committed if a resp.sendError was hit
in the jsp. So I just throw an exception instead, and the dispatchfilter catches the exception and does the resp.sendError.
- Mark
> Better exception logging when no ping query configured
> ------------------------------------------------------
>
> Key: SOLR-965
> URL: https://issues.apache.org/jira/browse/SOLR-965
> Project: Solr
> Issue Type: Improvement
> Affects Versions: 1.3
> Reporter: Hoss Man
> Fix For: 1.4
>
> Attachments: SOLR-965.patch
>
>
> user noted that with the example multicore configs, http://localhost:8983/solr/core1/admin/ping results in a 500 error and logs quite a bit of crap starting with a NullPointerException.
> The failing ping is the correct behavior, because the example multicore configs don't define a pingQuery -- but the code path of the failure and the exceptions logged are less then ideal. ping.jsp (which is still used if the PingRequestHandler doesn't get registered) and SolrConfig.getPingQueryRequest should me modified to log an (on topic) error and fail fast when there is no <pingQuery> declaration.
> A quick skim of PingRequestHandlers suggests we may also want to add some better logging (specifically: warnings about configuring it with good defaults) if it gets called without any params.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.