Specifications
Example: Develop Java Transaction Rules
11. Define the transactions as described in the example of developing a Java
transaction rule. The transaction definitions will use Java-specific events
such as JKeyPress, JSetLabel and JAddComponent.
12. Update Application Response with the new rule set.
Example: Develop Java Transaction Rules
To monitor response times for transactions in Java application or applets, you
need to define a rule set with transaction definitions that specify Java event
actions. Study the following examples to learn how to create transaction
definitions to monitor various transactions in the Live Exceptions Java
application.
Login Transaction
transaction "LELogin"
module "LELogin"
{
event "LEStarted" Java JInvokeApp { Class="com.concord.apps.liveExceptions.LeApp"
Args != contains:"-status" }
choice
{
event "LoginStartedClick" Java JMouseRelease { Title="Login"
Class="javax.swing.JButton" Text="OK" }
event "LoginStartedKey" Java JKeyPress { Title="Login" Key=10 }
}
event "LoginFinished" Windows SetTitle { Title=contains:"eHealth Live Exceptions"
}
}
except
{
event "BadPassword" Windows SetTitle { Title="Login incorrect" }
}
failure1 "Exception"
{
event "LEStarted" Java JInvokeApp {
Class="com.concord.apps.liveExceptions.LeApp"}
event "Exception" Windows SetFocus { Title="LiveHealth Internal Error Messages" }
}
Open Subjects to Monitor Transaction
Monitor Transactions in Java Applications 107