[
https://issues.apache.org/jira/browse/QPID-8718?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18040843#comment-18040843
]
ASF subversion and git services commented on QPID-8718:
-------------------------------------------------------
Commit 0cd564d1293af088d40dc7a6c54646bdf2d487c0 in qpid-broker-j's branch
refs/heads/main from Daniil Kirilyuk
[ https://gitbox.apache.org/repos/asf?p=qpid-broker-j.git;h=0cd564d129 ]
QPID-8718: [Broker-J] Broker query engine should support newline characters
(#341)
> [Broker-J] Broker query engine should support newline characters
> ----------------------------------------------------------------
>
> Key: QPID-8718
> URL: https://issues.apache.org/jira/browse/QPID-8718
> Project: Qpid
> Issue Type: Bug
> Components: Broker-J
> Affects Versions: qpid-java-broker-10.0.0
> Reporter: Daniil Kirilyuk
> Priority: Minor
> Fix For: qpid-java-broker-10.0.1
>
> Attachments: parsing error.txt
>
>
> When REST API request uses newline characters to format query string then API
> returns http 500 server error. It requires space character around keywords to
> properly parse query.
> {code:java}
> curl -i -X POST -H "Content-Type: application/json" -H "Accept:
> application/json" -d \
> '{
> "sql": "
> SELECT id, name
> FROM queue
> WHERE queueDepthMessages BETWEEN (1000 and 2000)"
> }' \
> http://localhost:8080/api/latest/querybroker/broker{code}
> Stacktrace: [^parsing error.txt]
> *Analysis*
> QueryServlet merges lines from HttpServletRequest using a reader without
> delimiter, leading to SQL query being merged without whitespaces between
> lines.
> *Implementation*
> Merging mechanism was changed, a space delimiter was added.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]