Java SDK throws exception when sending query using key containing whitespace
Thu, 10/04/2012 - 17:09
Using 2.0b and the Java API 1.1 preview, there appears to be a bug when doing a query with a key that has internal whitespace:
INFO CouchbaseClient - lookin for:/default/_design/accounts/_view/acc_by_username?limit=1000&skip=0&key="aaron davidson"
ERROR java.lang.RuntimeException: Failed to access the view
at com.couchbase.client.CouchbaseClient.query(CouchbaseClient.java:591)
...
If I manually replace the query string "aaron davidson" with "aaron%20davidson" the query works and no exception is thrown. The API should probably handle this case when constructing the RESTful URL.
Hi Aaron,
thanks for raising this - it may be an issue in the SDK. I openend an Issue for you and will track it down further: http://www.couchbase.com/issues/browse/JCBC-126
Thanks,
Michael