You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "KARR, DAVID" <dk...@att.com> on 2016/09/09 19:40:25 UTC

Practical to write code in webapp that can return metadata from current access log?

I'm considering writing a secondary diagnostics service for my CXF REST app running in Tomcat (TomEE) that can return some information about the number of calls to the main service in a particular time period.  Is there an API I can use in Java that will give me access to the current access log information?  I know that I could always hack something together with a fully qualified path to the file and manual code to parse it, but it seems like this is something that would have been done before, so perhaps there's an easier to use API for this.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Practical to write code in webapp that can return metadata from current access log?

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

David,

On 9/9/16 3:40 PM, KARR, DAVID wrote:
> I'm considering writing a secondary diagnostics service for my CXF 
> REST app running in Tomcat (TomEE) that can return some
> information about the number of calls to the main service in a
> particular time period.  Is there an API I can use in Java that
> will give me access to the current access log information?  I know
> that I could always hack something together with a fully qualified
> path to the file and manual code to parse it, but it seems like
> this is something that would have been done before, so perhaps
> there's an easier to use API for this.

Like this?

https://tomcat.apache.org/presentations.html

See "Monitoring Apache Tomcat with JMX", slides 24-31.

Do you have a single servlet serving these requests? Or do you need
something finer-grained than at the "servlet" or even URL-pattern level?

- -chris
-----BEGIN PGP SIGNATURE-----
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBCAAGBQJX1cjcAAoJEBzwKT+lPKRYA1gP/iVEeO1TkFZIB2V4Iz/aXQCq
y9Kw3w5oofGmvSkycYH6cieF9rMY9x82DLhNsvHJfBWCWUnxayGxSczhbL9udTd4
DUvZNkRkjmrgoGJdGEFkJa3rtUQaIXdu3nUNeofGJ2WWR5AyHUkqohXF0x1X7XOe
ho4kdocm/NeVJrMTck9VSN819213IfnBYO006QQVj2O2/XTaHldK5eePiGM74RyJ
Fker4r4TFux0g44FIyxQDP2uIp1K6yY1Am7nIk7Zc2uI7eGvf7EwZo/LWBYBHJEU
44F3GaXeawS6TLVOE23fbLUBomTYYjOMlH0Ns8/i/ejEsbNawyA/JzJQxjetgSIk
MRvPj3e1qf19X9MX4KroKugj8EZ9Qcm2+eBw0OTjwtt8WSewXB6Ltd3SnsjObR6w
b9KjJdLlu1uRELivAi474D5lZLbNz/+FC8ePUFst57oExBiBkL6iJ8+ds5/o/G6/
iSa8TLgydXE4knMIyS7Rz9zOur6IXIL1vLQnU7NM+MXEKvf+BfipWvCgSCdVwCQQ
bv0krBTDMYkAJ14VrT3f8Hw2gmig/cP2DnHYOxDnc8dSJ+meF4gVmzRaD6bSCjDY
2Z4sLj6PKJl2+SLB/YBV3nYinUeon+v7UrZKhDTwytoQOnf85d/0R9/HQnL9H78T
eML9kRJ8f7ysg7uwp2qz
=x3Jw
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Practical to write code in webapp that can return metadata from current access log?

Posted by Pascal Abaziou <pa...@gmail.com>.
Hi  David, 

As they are sophisticated, diagnostic services are usually given by dedicated solution and not ad-hoc development. I known licensed solutions (app dynamics and there should exists other competitors Here is a quora discussion about open source competitors : https://www.quora.com/Application-Performance-Management-Is-there-an-open-source-competitor-to-AppDynamics 

As you mention «  information about the number of calls to the main service », these informations can also be offered by API management solutions. There’s a number of open source competitors for this orientation.

Kind regards,
Pascal

> Le 9 sept. 2016 à 21:40, KARR, DAVID <dk...@att.com> a écrit :
> 
> I'm considering writing a secondary diagnostics service for my CXF REST app running in Tomcat (TomEE) that can return some information about the number of calls to the main service in a particular time period.  Is there an API I can use in Java that will give me access to the current access log information?  I know that I could always hack something together with a fully qualified path to the file and manual code to parse it, but it seems like this is something that would have been done before, so perhaps there's an easier to use API for this.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org