[MarkLogic Dev General] Capturing elapsed time of requests

John Chertudi Jchertudi at rubicon.com
Tue Oct 1 09:19:00 PDT 2013


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] On Behalf Of Soumadri, Roy Chowdhury
Sent: Tuesday, October 01, 2013 3:18 AM
To: 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/07fa221b/attachment.html 


More information about the General mailing list