lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vincenzo D'Amore" <v.dam...@gmail.com>
Subject Re: query logging using query rest api
Date Mon, 02 May 2016 12:05:12 GMT
Hi Matteo, take a look at:

https://cwiki.apache.org/confluence/display/solr/Configuring+Logging

And also the comments:

https://cwiki.apache.org/confluence/display/solr/Configuring+Logging#comment-thread-51808825

I have not tried but it seems interesting.


On Mon, May 2, 2016 at 11:45 AM, Vincenzo D'Amore <v.damore@gmail.com>
wrote:

> Hi Matteo,
>
> trying a few of queries, using POST and GET method, you can see query
> params in logs appears only when you pass them in query string along with
> HTTP GET method.
>
> curl 'localhost:8983/solr/test/query?q=*:*'
>
> The reason of this behaviour (I think) is in the big difference between
> the size of parameters (number and length) usually used in HTTP GET (short)
> and HTTP POST (big).
>
> Let me see if we can change such log behaviour, but I suppose it could be
> quite dangerous...
>
>
>
>
>
>
> On Mon, May 2, 2016 at 11:21 AM, Matteo Grolla <matteo.grolla@gmail.com>
> wrote:
>
>> Hi Vincenzo,
>>          you're right -XGET shouldn't be there but curl is smart enough to
>> ignore it so nothing changes eliminating it, tested.
>>
>> 2016-04-28 11:28 GMT+02:00 Vincenzo D'Amore <v.damore@gmail.com>:
>>
>> > Hi Matteo,
>> >
>> > there is a problem in your curl test: as far as I know you cannot use
>> GET
>> > HTTP method ( -XGET ) and pass parameters in POST (-d).
>> >
>> > Try to remove the -XGET parameter.
>> >
>> > On Thu, Apr 28, 2016 at 11:18 AM, Matteo Grolla <
>> matteo.grolla@gmail.com>
>> > wrote:
>> >
>> > > Hi,
>> > >     I'm experimenting the query rest api with solr 5.4 and I'm
>> noticing
>> > > that query parameters are not logged in solr.log.
>> > > Here are query and log line
>> > >
>> > > curl -XGET 'localhost:8983/solr/test/query' -d '{"query":"*:*"}'
>> > >
>> > > 2016-04-28 09:16:54.008 INFO  (qtp668849042-17) [   x:test]
>> > > o.a.s.c.S.Request [test] webapp=/solr path=/query params={} hits=32
>> > > status=0 QTime=46
>> > >
>> > > Why this behaviour? How can I log request parameters for those
>> queries?
>> > > Thanks
>> > >
>> > > Matteo
>> > >
>> >
>> >
>> >
>> > --
>> > Vincenzo D'Amore
>> > email: v.damore@gmail.com
>> > skype: free.dev
>> > mobile: +39 349 8513251
>> >
>>
>
>
>
> --
> Vincenzo D'Amore
> email: v.damore@gmail.com
> skype: free.dev
> mobile: +39 349 8513251
>



-- 
Vincenzo D'Amore
email: v.damore@gmail.com
skype: free.dev
mobile: +39 349 8513251

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message