hung-cao / solrmeter

Automatically exported from code.google.com/p/solrmeter
0 stars 0 forks source link

Random characters added to query while url encoding #103

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

So in my queries file, I have an entry like this:
numNights:[7 TO 14] AND numAdults:2 AND tourDate:[2012-08-09T01:00:00.000Z TO 
2012-08-31T01:00:00.000Z]

I have added a bunch of extra params to the test.

When I ran the test, it failed with the following error msg:
Error on Query 
q=%EF%BB%BFnumNights%3A%5B7+TO+14%5D+AND+numAdults%3A2+AND+tourDate%3A%5B2012-08
-09T01%3A00%3A00.000Z+TO+2012-08-31T01%3A00%3A00.000Z%5D&qt=&fl=*%2Cscore&facet=
true&sort=commercialPriority+desc&facet.mincount=1&facet.query=price%3A%5B3001+T
O+*%5D&start=0&facet.limit=8&group.field=hotelIdName&facet.field=partyCompositio
nf&facet.field=price&group.sort=price+asc&group=true&group.offset=0&rows=2000&fa
cet.method=fc

Not sure why the characters %EF%BB%BF are being appended to my query before 
being fired on Solr

What version of the product are you using? On what operating system?

Using ver 0.2.0 for Solr 3.6. Running on 32 bit Win XP, with JDK 1.6

Please provide any additional information below.

Original issue reported on code.google.com by bhaveam...@gmail.com on 10 Aug 2012 at 4:42

GoogleCodeExporter commented 9 years ago
Hmmmm just guessing here, but maybe the charset of your text file is different 
from the charset you set in SolrMeter? If you haven't set a file charset in 
SolrMeter it uses by default UTF-8, but you can change it setting the property: 
'files.charset'

Original comment by tflo...@gmail.com on 10 Aug 2012 at 4:55

GoogleCodeExporter commented 9 years ago
No I checked it before hand. Both are set to UTF-8

Original comment by bhaveam...@gmail.com on 10 Aug 2012 at 5:02

GoogleCodeExporter commented 9 years ago
Could you upload a piece of your queries file?

Original comment by tflo...@gmail.com on 10 Aug 2012 at 5:42

GoogleCodeExporter commented 9 years ago

Original comment by bhaveam...@gmail.com on 10 Aug 2012 at 5:51

Attachments:

GoogleCodeExporter commented 9 years ago
This issue was closed by revision r296.

Original comment by tflo...@gmail.com on 10 Aug 2012 at 11:44

GoogleCodeExporter commented 9 years ago
Thanks for reporting this issue! After some debugging and a couple of (Friday) 
beers, it looks like the issue is the one described here:
http://bugs.sun.com/view_bug.do?bug_id=4508058
and 
http://bugs.sun.com/view_bug.do?bug_id=6378911

Try with the last build: 
https://plugtree-org.ci.cloudbees.com/job/solrmeter/lastSuccessfulBuild/artifact
/releases/solrmeter.jar

Original comment by tflo...@gmail.com on 11 Aug 2012 at 12:05

GoogleCodeExporter commented 9 years ago
Tried with the new jar - Now it is refusing to query Solr. I get the following 
error:
----
[Thread-817]| 
INFO|[com.plugtree.solrmeter.model.SolrServerRegistry]|11:17:45,502 | 
Connecting to Solr: http://10.4
0.14.93:8080/solr/search
Exception in thread "Thread-817" java.lang.NullPointerException
        at com.plugtree.solrmeter.model.operation.QueryOperation.execute(QueryOperation.java:55)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.executeOperation(RandomOperationExe
cutorThread.java:83)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.run(RandomOperationExecutorThread.j
ava:62)
Exception in thread "Thread-809" java.lang.NullPointerException
        at com.plugtree.solrmeter.model.operation.QueryOperation.execute(QueryOperation.java:55)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.executeOperation(RandomOperationExe
cutorThread.java:83)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.run(RandomOperationExecutorThread.j
ava:62)
Exception in thread "Thread-826" java.lang.NullPointerException
        at com.plugtree.solrmeter.model.operation.QueryOperation.execute(QueryOperation.java:55)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.executeOperation(RandomOperationExe
cutorThread.java:83)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.run(RandomOperationExecutorThread.j
ava:62)
Exception in thread "Thread-815" java.lang.NullPointerException
        at com.plugtree.solrmeter.model.operation.QueryOperation.execute(QueryOperation.java:55)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.executeOperation(RandomOperationExe
cutorThread.java:83)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.run(RandomOperationExecutorThread.j
ava:62)
Exception in thread "Thread-827" java.lang.NullPointerException
        at com.plugtree.solrmeter.model.operation.QueryOperation.execute(QueryOperation.java:55)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.executeOperation(RandomOperationExe
cutorThread.java:83)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.run(RandomOperationExecutorThread.j
ava:62)
Exception in thread "Thread-820" java.lang.NullPointerException
        at com.plugtree.solrmeter.model.operation.QueryOperation.execute(QueryOperation.java:55)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.executeOperation(RandomOperationExe
cutorThread.java:83)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.run(RandomOperationExecutorThread.j
ava:62)
Exception in thread "Thread-822" java.lang.NullPointerException
        at com.plugtree.solrmeter.model.operation.QueryOperation.execute(QueryOperation.java:55)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.executeOperation(RandomOperationExe
cutorThread.java:83)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.run(RandomOperationExecutorThread.j
ava:62)
Exception in thread "Thread-814" java.lang.NullPointerException
        at com.plugtree.solrmeter.model.operation.QueryOperation.execute(QueryOperation.java:55)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.executeOperation(RandomOperationExe
cutorThread.java:83)
        at com.plugtree.solrmeter.model.operation.RandomOperationExecutorThread.run(RandomOperationExecutorThread.j
ava:62)
----

Original comment by bhaveam...@gmail.com on 13 Aug 2012 at 10:19

GoogleCodeExporter commented 9 years ago
Do you see any error on the Solr server logs? the line 55 of the QueryOperation 
is a log line after executing the query with the line:

logger.debug(response.getResults().getNumFound() + " results found in " + 
response.getQTime() + " ms");

I've been using the last revision during the weekend and I didn't see this 
error.

Original comment by tflo...@gmail.com on 13 Aug 2012 at 10:31