activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hiram Chirino (Resolved) (JIRA)" <>
Subject [jira] [Resolved] (APLO-122) org.josql.QueryParseException when using a negation
Date Wed, 21 Dec 2011 19:51:32 GMT


Hiram Chirino resolved APLO-122.

       Resolution: Fixed
    Fix Version/s: 1.0
         Assignee: Hiram Chirino

Just committed a change wich add  a NOT(Boolean) query function.  Return a ErrorDTO holding
the error message for all 40x and 50x status codes.  Really return a 500 error result and
log as a warning on all unexpected exceptions. Updated management api to reflect the change
in the error handling.
> org.josql.QueryParseException when using a negation
> ---------------------------------------------------
>                 Key: APLO-122
>                 URL:
>             Project: ActiveMQ Apollo
>          Issue Type: Bug
>            Reporter: Lionel Cons
>            Assignee: Hiram Chirino
>             Fix For: 1.0
> When trying to use the "NOT" operator in the REST interface, Apollo reports an exception:
> org.josql.QueryParseException: Unable to find function (method): "NOT(java.lang.Boolean)"
in any user-defined function handlers or the default function handler
> 	at org.josql.expressions.Function.init(
> 	at org.josql.expressions.BinaryExpression.init(
> 	at org.josql.Query.init(
> 	at org.josql.Query.parse(
> 	at org.apache.activemq.apollo.web.resources.BrokerResource.narrow(BrokerResource.scala:449)
> 	at org.apache.activemq.apollo.web.resources.BrokerResource$$anonfun$queues$1$$anonfun$20.apply(BrokerResource.scala:528)
> 	at org.apache.activemq.apollo.web.resources.BrokerResource$$anonfun$queues$1$$anonfun$20.apply(BrokerResource.scala:528)
> 	at org.fusesource.hawtdispatch.Future$$anon$2.merge(Future.scala:125)
> 	at org.fusesource.hawtdispatch.SettableFuture$class.set(Future.scala:46)
> 	at org.fusesource.hawtdispatch.Future$$anon$2.set(Future.scala:124)
> 	at org.fusesource.hawtdispatch.SettableFuture$class.apply(Future.scala:41)
> 	at org.fusesource.hawtdispatch.Future$$anon$2.apply(Future.scala:124)
> 	at org.fusesource.hawtdispatch.SettableFuture$$anonfun$map$1.apply(Future.scala:105)
> 	at org.fusesource.hawtdispatch.SettableFuture$$anonfun$map$1.apply(Future.scala:105)
> 	at org.fusesource.hawtdispatch.SettableFuture$$anonfun$set$1.apply(Future.scala:57)
> 	at org.fusesource.hawtdispatch.SettableFuture$$anonfun$set$1.apply(Future.scala:57)
> 	at scala.Option.foreach(Option.scala:197)
> FWIW, the expression I tried to use was "(id LIKE '%bar%') AND NOT (id LIKE '%foo%')".
> First, I would have expected such an exception to cause the REST interface to report
a "server error". Instead, it only reported "404 Not Found".
> Then, why can't I use the unary NOT this way?

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message