[ 
https://issues.apache.org/jira/browse/SOLR-3447?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13273108#comment-13273108
 ] 

ESSOUSSI Jamel commented on SOLR-3447:
--------------------------------------

Hi,

When the schema is not valid and I try to index solr document I get this 
response from solr:

HTTP/1.1 400 Mauvaise Requ.te
Server: Apache-Coyote/1.1
Content-Type: text/html;charset=utf-8
Content-Length: 1125
Date: Thu, 10 May 2012 16:00:00 GMT
Connection: close

<html><head><title>Apache Tomcat/6.0.28 - Rapport d'erreur</title><style><!--H1 
{font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;}
 H2 
{font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;}
 H3 
{font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;}
 BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} 
B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P 
{font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A
 {color : black;}A.name {color : black;}HR {color : #525D76;}--></style> 
</head><body><h1>Etat HTTP 400 - ERROR: [doc=280304571883] unknown field 
'shop_'</h1><HR size="1" noshade="noshade"><p><b>type</b> Rapport 
d'..tat</p><p><b>message</b> <u>ERROR: [doc=280304571883] unknown field 
'shop_'</u></p><p><b>description</b> <u>La requ..te envoy..e par le client 
..tait syntaxiquement incorrecte (ERROR: [doc=280304571883] unknown field 
'shop_').</u></p><HR size="1" noshade="noshade"><h3>Apache 
Tomcat/6.0.28</h3></body></html> 


And when the schema is valid, I get this response :


HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: application/xml;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 10 May 2012 15:53:09 GMT

93
<?xml version="1.0" encoding="UTF-8"?>
<response>
<lst name="responseHeader"><int name="status">0</int><int 
name="QTime">3</int></lst>
</response> 

--> Is that it is normal that the result eq 0 when the schema is good.
--> and if the schema is not good, why solrj is not capable of handling 
solrexception 

Best Reagards

-- Jamel ESSOUSSI
                
> solrj cannot handle org.apache.solr.common.SolrException when the schema is 
> not correct
> ---------------------------------------------------------------------------------------
>
>                 Key: SOLR-3447
>                 URL: https://issues.apache.org/jira/browse/SOLR-3447
>             Project: Solr
>          Issue Type: Bug
>          Components: clients - java
>    Affects Versions: 3.6
>         Environment: jdk 1.6.0_26, tomcat 6.0.35 , solrj 3.6.0 solr-core 
> 3.6.0 and solr.war (4.0)
>            Reporter: ESSOUSSI Jamel
>             Fix For: 3.6
>
>
> Hi;
> I have an incorrect schema, a missing field :
> and when I add a documents (UpdateResponse ur = solrServer.add(docs);), I 
> have not be able to catch exception in solrj and the UpdateResponse cannot 
> handle result.
> Best Regards
> -- Jamel ESSOUSSI

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to