Skip to content
This repository has been archived by the owner on Jun 3, 2024. It is now read-only.

Added support for @CompositeTimed annotation #137

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

alex859
Copy link

@alex859 alex859 commented Sep 7, 2015

It can be sometimes useful having different timers on a method to avoid failing events to falsify the overall timing statistics.
The @CompositeTimed annotation adds 3 timers on a method call:

  • a failure timer that tracks the duration of the method when an exception occurs
  • a success timer for methods calls that end successfully
  • an overall timer
@CompositeTimed(name="compositeMethod", failedSuffix = "Fail", successSuffix = "Success", absolute = true)
public void compositeTimedMethod() throws Exception
{
    ....
}

will create compositeMethod, compositeMethodSuccess and compositeMethodFail timers.

Hope this can help.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant