Yago Riveiro created SOLR-5788: ---------------------------------- Summary: Document update in case of error doesn't returns the error message correctly Key: SOLR-5788 URL: https://issues.apache.org/jira/browse/SOLR-5788 Project: Solr Issue Type: Bug Affects Versions: 4.6.1 Reporter: Yago Riveiro
I found a issue when updating a document. If for any reason the update can't be done, example: the schema doesn't match with the incoming doc; the error raise to the user is something like: {noformat} curl 'http://localhost:8983/solr/collection1/update?commit=true' --data-binary @doc.json -H 'Content-type:application/json' {"responseHeader":{"status":400,"QTime":52},"error":{"msg":"Bad Request\n\n\n\nrequest: http://localhost:8983/solr/collection1_shard3_replica1/update?update.distrib=TOLEADER&distrib.from=http%3A%2F%2Flocalhost%3A8983%2Fsolr%2Fcollection1_shard1_replica2%2F&wt=javabin&version=2","code":400}} {noformat} In case that the update was done on the leader, the error message is (IMHO) the correct and with valuable info: {noformat} curl 'http://localhost:8983/solr/collection1/update?commit=true' --data-binary @doc.json -H 'Content-type:application/json' {"responseHeader":{"status":400,"QTime":19},"error":{"msg":"ERROR: [doc=01!12967564] Error adding field 'source'='[Direct]' msg=For input string: \"Direct\","code":400}} {noformat} -- This message was sent by Atlassian JIRA (v6.1.5#6160) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org