You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Jörg Hoh (JIRA)" <ji...@apache.org> on 2010/04/06 16:16:33 UTC

[jira] Created: (SLING-1476) provide number of processed requests

provide number of processed requests
------------------------------------

                 Key: SLING-1476
                 URL: https://issues.apache.org/jira/browse/SLING-1476
             Project: Sling
          Issue Type: New Feature
          Components: Commons
            Reporter: Jörg Hoh
            Priority: Minor



For status monitoring it would be useful to have the number of total processed requests since restart of the JVM. Is it possible to have a "statistics" component which could provide such numbers?

(The "manual" way to do it would be writing a very simple RequestFilter which just increments a counter and expose this object as OSGI component.)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SLING-1476) provide number of processed requests

Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SLING-1476?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Felix Meschberger updated SLING-1476:
-------------------------------------

          Component/s:     (was: Commons)
                       Engine
    Affects Version/s: Engine 2.0.6

> provide number of processed requests
> ------------------------------------
>
>                 Key: SLING-1476
>                 URL: https://issues.apache.org/jira/browse/SLING-1476
>             Project: Sling
>          Issue Type: New Feature
>          Components: Engine
>    Affects Versions: Engine 2.0.6
>            Reporter: Jörg Hoh
>            Priority: Minor
>
> For status monitoring it would be useful to have the number of total processed requests since restart of the JVM. Is it possible to have a "statistics" component which could provide such numbers?
> (The "manual" way to do it would be writing a very simple RequestFilter which just increments a counter and expose this object as OSGI component.)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SLING-1476) provide number of processed requests

Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-1476?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12854645#action_12854645 ] 

Felix Meschberger commented on SLING-1476:
------------------------------------------

Possible attributes:

  * Time of last counter reset
  * Number of requests
  * Number of includes (RequestDispatcher.include/forward)
  * Number of successful requests (200, 201, 2xx)
  * Number of unmodified responses (304)
  * Number of erroneous requests (4xx, 5xx)
  * Total request processing time
  * Average time (ms) per request
  * Average includes per request

Possible operations:

  * Reset counters

> provide number of processed requests
> ------------------------------------
>
>                 Key: SLING-1476
>                 URL: https://issues.apache.org/jira/browse/SLING-1476
>             Project: Sling
>          Issue Type: New Feature
>          Components: Engine
>    Affects Versions: Engine 2.0.6
>            Reporter: Jörg Hoh
>            Priority: Minor
>
> For status monitoring it would be useful to have the number of total processed requests since restart of the JVM. Is it possible to have a "statistics" component which could provide such numbers?
> (The "manual" way to do it would be writing a very simple RequestFilter which just increments a counter and expose this object as OSGI component.)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SLING-1476) provide number of processed requests

Posted by "Jörg Hoh (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SLING-1476?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jörg Hoh updated SLING-1476:
----------------------------

    Attachment: org.apache.sling.jmx.zip


The example bundle, using the package name "org.apache.sling.jmx". Only the source code.

> provide number of processed requests
> ------------------------------------
>
>                 Key: SLING-1476
>                 URL: https://issues.apache.org/jira/browse/SLING-1476
>             Project: Sling
>          Issue Type: New Feature
>          Components: Engine
>    Affects Versions: Engine 2.0.6
>            Reporter: Jörg Hoh
>            Priority: Minor
>         Attachments: org.apache.sling.jmx.zip
>
>
> For status monitoring it would be useful to have the number of total processed requests since restart of the JVM. Is it possible to have a "statistics" component which could provide such numbers?
> (The "manual" way to do it would be writing a very simple RequestFilter which just increments a counter and expose this object as OSGI component.)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SLING-1476) provide number of processed requests

Posted by "Jörg Hoh (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-1476?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12892210#action_12892210 ] 

Jörg Hoh commented on SLING-1476:
---------------------------------

I wanted to have this information ready for monitoring/observation purposes, so I decided to use JMX as a basis for this approach. At the moment I am only thinking of read-only values in JMX.

I implemented a small bundle with 2 services:
 * MBeanAdmin: A utility service, which handles the (un-) registration of MBeans to the JVM-internal MBean-Implementation
 * RequestCounter: A minimalistic service, which counts the number of total requests; this is a sample showing how to implement a MBean within sling and OSGI.

I think, that the way to implement such an MBean is rather straight-forward and easy. So maybe it's worth, that you review that code and include it into sling.


> provide number of processed requests
> ------------------------------------
>
>                 Key: SLING-1476
>                 URL: https://issues.apache.org/jira/browse/SLING-1476
>             Project: Sling
>          Issue Type: New Feature
>          Components: Engine
>    Affects Versions: Engine 2.0.6
>            Reporter: Jörg Hoh
>            Priority: Minor
>
> For status monitoring it would be useful to have the number of total processed requests since restart of the JVM. Is it possible to have a "statistics" component which could provide such numbers?
> (The "manual" way to do it would be writing a very simple RequestFilter which just increments a counter and expose this object as OSGI component.)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.