[MarkLogic Dev General] Capturing elapsed time of requests

Whitby, Rob rob.whitby at springer.com
Tue Oct 1 10:17:01 PDT 2013


Would be great if the access log format could be configured to include duration.

________________________________
From: general-bounces at developer.marklogic.com [general-bounces at developer.marklogic.com] on behalf of Geert Josten [geert.josten at dayon.nl]
Sent: 01 October 2013 18:05
To: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Capturing elapsed time of requests

Hi Soumadri Roy,

I had a similar questions a while back, didn’t come up with a solution then. The status calls can give an close impression if run at small interval, and results accumulated somehow.

On the other hand, the XDBC connection is likely to be HTTP based in the end. Have you tried sniffing traffic with something as simple as tcpflow, tcpmon or alike?

Cheers,
Geert

Van: general-bounces at developer.marklogic.com<mailto:general-bounces at developer.marklogic.com> [mailto:general-bounces at developer.marklogic.com<mailto:general-bounces at developer.marklogic.com>] Namens John Chertudi
Verzonden: dinsdag 1 oktober 2013 18:19
Aan: MarkLogic Developer Discussion
Onderwerp: Re: [MarkLogic Dev General] Capturing elapsed time of requests


We have an XDBC App Server attached to one of our version 5.0-5 databases.

MarkLogic captures the logs of all requests in the file system, by default in <MarkLogicInstallDir>\Data\Logs (Windows install) with rotating log files for each App Server. The log files contain a space separated values such as
ClientIP Time RequestURL           HTTPStatus         Duration(ms)     UserAgent
65.116.71.49 - - [30/Sep/2013:17:07:30 Pacific Daylight Time] "POST /eval XDBC/1.0" 401 209 - "Java/1.7.0_11 MarkXDBC/5.0-3"

In a different App Server, we were also able to log the HTTPReferrer, that has been useful for us in finding the source of a request. Any number of these logs can be analyzed in Excel or your favorite RDBMS.

Hope this provides at least once solution. I do believe you would need to have the option to log requests enabled at the Group level.

John Chertudi

From: general-bounces at developer.marklogic.com<mailto:general-bounces at developer.marklogic.com> [mailto:general-bounces at developer.marklogic.com<mailto:general-bounces at developer.marklogic.com>] On Behalf Of Soumadri, Roy Chowdhury
Sent: Tuesday, October 01, 2013 3:18 AM
To: general at developer.marklogic.com<mailto:general at developer.marklogic.com>
Subject: [MarkLogic Dev General] Capturing elapsed time of requests

Hi All,

I need to capture elapsed time for all the requests coming to a particular XDBC server. The details I need to capture is name of the xqy module and the elapsed time. I have gone through the xdmp:server-status and xdmp:request-status, but that only gives details of requests which were running at the particular instance when I executed xdmp:*-status functions. I need a mechanism, something like a trigger, which logs the details when a request hits that XDBC server. Because of the amount of code and huge number of xqueries, it is difficult to write logs in each and every xquery module.

Is there a way directly available in MarkLogic which can help me achieve this?

Regards,
Soumadri Roy


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://developer.marklogic.com/pipermail/general/attachments/20131001/fdf91d13/attachment.html 


More information about the General mailing list