elasticsearch/elasticsearch — Issue #1387: Unclosed double quote causes error
Author: fdv
Created: 2011-10-12 12:36:28+00:00
State: open

When sending a query with an unclosed double quote, I get an error with a stack. Here's my log.

Caused by: org.apache.lucene.queryParser.ParseException: Cannot parse '"test': Lexical error at line 1, column 6. Encountered: after : "\"test"
at org.apache.lucene.queryParser.QueryParser.parse(QueryParser.java:216)
at org.elasticsearch.index.query.QueryStringQueryParser.parse(QueryStringQueryParser.java:184)
... 38 more
Caused by: org.apache.lucene.queryParser.TokenMgrError: Lexical error at line 1, column 6. Encountered: after : "\"test"
at org.apache.lucene.queryParser.QueryParserTokenManager.getNextToken(QueryParserTokenManager.java:1229)
at org.apache.lucene.queryParser.QueryParser.jj_ntk(QueryParser.java:1748)
at org.apache.lucene.queryParser.QueryParser.Modifiers(QueryParser.java:1192)
at org.apache.lucene.queryParser.QueryParser.Query(QueryParser.java:1236)
at org.apache.lucene.queryParser.QueryParser.TopLevelQuery(QueryParser.java:1226)
at org.apache.lucene.queryParser.QueryParser.parse(QueryParser.java:206)
... 39 more