Different files are used to configure the HPA Agent :
- 
Agent startup : connection to portal, infrastructure agent, Calypso startup scripts, Oracle
monitoring. All parameters from hpa_agent_config.sh
- Stall tracer : recording information during the stall detection
- Agent profile override override mechanism for profiles
- Agent config exporter Debug session config exporter configuration
- Database export Debug session database export configuration
Agent startup configuration
During installation, the hpa_agent_config.sh has been created and configured for your environment with :
export HPA_EM_HOST=<em host>:5443
export HPA_CALYPSO_ENV=v15-hex1-perf
As agent configuration files and paths are dedicated to one Calypso environment, you MUST create one agent folder per Calypso environment.
Especially in case several Calypso environments are running on the same hosts, dedicated ports sections, see following warnings :
/!\ If multiple Calypso environments........
Others parameters in hpa_agent_config.sh
HPA portal conection
| Variable | Usage | 
|---|---|
| ENABLE | Enable or disable agent during Calypso startup. 1 to enable HPA. 0 to disable it. Default is 1 | 
| HPA_CALYPSO_ENV | name of the Calypso environment. This one must match a key in HPA portal environments. | 
| HPA_EM_HOST | Host of HPA portal server. Follow the pattern : ssl:// Where hpa-server-portis the value defined byHPA_EM_CHANNEL_PORT_SECUREin HPA portal configurationFor example : ssl://myserver:5443 | 
HPA configuration on command line
| Variable | Usage | 
|---|---|
| HPA_SET_JAVA_OPTS | if true, scripts will add HPA configuration to JAVA_OPTS.Default true. | 
| HPA_SET_CALYPSO_OPTS | if true, scripts will add HPA configuration to CALYPSO_OPTS.Default false. | 
| HPA_SET_CALYPSO_JAVA_MEM_OPTS | if true, scripts will add HPA configuration to CALYPSO_JAVA_MEM_OPTS.Default false. | 
| HPA_FORCE_JBOSS_PRELOAD | if true, scripts will add specific Jboss configuration -Djboss.modules.system.pkgs=com.wily,com.wily.*,org.jboss.byteman.Default false. | 
| RESET_VAR_EACH_TIME | if true CALYPSO_JAVA_MEM_OPTSandJAVA_OPTSare cleared before adding HPA parameters | 
HPA Host monitoring
For Host monitoring
| Variable | Usage | 
|---|---|
| HPA_CALYPSO_EPAGENT_PORT | A listening port on localhost for the EPAgent (internal use). Default is 48080 | 
| HPA_CALYPSO_EPAGENT_COLLECTOR_PORT | A listening port on localhost for the EPAgent Collector (scripts can send metrics to HPA portal). Default is 5005 | 
| HPA_CALYPSO_SYSEDGE | A listening port on localhost for the SystemEdge. Collect metrics on the host. Default is 1694 | 
| HPA_INFRASTRUCTURE_ENABLED | Start automatically the infrastructure agent with the first Calypso module. 1 to launch automatically. 0 to disable it Default 0 | 
/!\ If multiple Calypso environments are monitored on the same host, these ports must be changed do not conflict which each others
For Oracle Monitoring
| Variable | Usage | 
|---|---|
| HPA_CALYPSO_DATABASE_ENABLED | see Oracle monitoring | 
| HPA_CALYPSO_DATABASE_RAC_ENABLED | see Oracle monitoring | 
| HPA_CALYPSO_DATABASE_INSTANCE_NAME | see Oracle monitoring | 
| HPA_CALYPSO_DATABASE_HOST | see Oracle monitoring | 
| HPA_CALYPSO_DATABASE_PORT | see Oracle monitoring | 
| HPA_CALYPSO_DATABASE_USER | see Oracle monitoring | 
For Debug session process
| Variable | Usage | 
|---|---|
| HPA_DEBUGSESSION_MONITOR_PORT | To ensure the debug session monitor is unique for a host and a Calypso environment, this process listen on local port. Nothing can be done on this port. Default is 37491 | 
/!\ If multiple Calypso environments are monitored on the same host, these ports must be changed do not conflict which each others
Stall configuration
Behavior
When a stall is detected (a request than ran more than 30 seconds), the agents execute the following actions :
- Detect if the stall detection for this metric should be ignored. Section ignoredClasses
- Record a context. Section conversion
- Mark the execution to prevent information in the next stall detection round
The service use the configuration file :
- 
<agent_home>/override_config/configuration_stall.ymlor by the default :
- 
<agent_home>/default_config/configuration_stall.yml
Configuration file
There is one general parameter stall-duration-in-seconds that indicates duration of a request before beeing marked
as “stalled”.
Section ignoredClasses
This is a list of metrics to ignore. These metrics won’t have neither a stall metric recorded, neither trigger a context recording.
Service evaluate the rules in order.
Two options to describe the metrics to ignore :
- 
ignoreType:REGEXPorDIRECT_VALUE
- 
shouldIgnore: keep or ignore the metrics in case of stall detection.
- 
values: a list of regular expression forREGEXPor a list of metric name forDIRECT_VALUE
Section conversion
This is a list of objects to record in a deeper way. By default, only the classname for the following objects are recorded :
- object that execute request
- parameters of the request
- return value if any
Context tracer use the conversion section to enrich the context. If the element (object, parameter or return value)
match one of the entry, then it executes the associated list of converter :
- converter : METHODorATTRIBUTE
- property : the value of the method to call, or the attribute to read
Method call can be only method without arguments
The action is recursive, the converted result is also evaluated against the configuration.
For example :
- 
TradeReport.getReportTemplatereturns aReportTemplate
- 
ReportTemplate.getAttributesreturns aAttributes
- …
Example of the configuration file.
stall-duration-in-seconds: 30
conversion:
  "com.calypso.tk.core.Trade":
    - property: "toString"
      converter: METHOD
    - property: "getId"
      converter: METHOD
  "com.calypso.tk.report.TradeReport":
    - property: "getReportTemplate"
      converter: METHOD
  "com.calypso.tk.report.ReportTemplate":
    - property: "getAttributes"
      converter: METHOD
  "com.calypso.tk.core.Attributes":
    - property: "hashtable"
      converter: METHOD   
ignoredClasses:
  - ignoreType: REGEXP
    shouldIgnore: true
    values:
      - "PThread.*"
  - ignoreType: DIRECT_VALUE
    shouldIgnore: false
    values:
      - PThread$Internal
      - Frontends|Apps|TimerThread 
Agent profile override
Prerequisites
Agent is installed and configured for a standard installation.
In some case, some properties values from the profile files could be overriden.
Override config path
The modified files are stored in :
<agent_home>/override_config/profiles
In this directory, the following files are authorized :
- same name as the profiles file, example : IntroscopeAgent_navigator.profile, IntroscopeAgent_dataserver.profile
- IntroscopeAgent_common.profile
Override order
The properties in the files are loaded in this order :
- override profile specific
- override common file
- default profile file
An example with the navigator profile, loading order is :
- 
<agent_home>/override_config/profiles/IntroscopeAgent_navigator.profile
- 
<agent_home>/override_config/profiles/IntroscopeAgent_common.profile
- 
<agent_home>/wily/core/config/IntroscopeAgent_navigator.profile
Override properties and hot reloading
The files are are reloaded automatically when they are modified, but not all properties are hot-reloadable. For example :
- 
hpa.dumpDirectoryis not hot-reloadable
- 
hpa.sqlagent.statement.clampis hot-reloadable
Check documentation or ask support for specific property behavior.