PANIC Configuration
The level of detail in PANIC file can be customized using the panconf.xml configuration file which controls the amount of data captured on a per variable or a per user basis. By default PANIC only dumps at most X array elements and truncates strings at Y bytes in order to keep a reasonable the size for PANIC files.
When KCML starts up it attempts to locate "panconf.xml" in the kcml directory, or for the file specified by the environment variable KCML_PANIC_CONF if it is defined. If found it parses the file looking for entries for the current user which it holds as the default for the number of array elements and the length of strings to be used in the event of a PANIC. It also records the variables for which special handling is required.
Typical XML might be:
<?xml version="1.0"?> <panconf> <user name="rjc"> <arrayelems>52</arrayelems> <stringlen>71</stringlen </user> <var name="a$()"> <arrayelems>3</arrayelems> <stringlen>123</stringlen </var> </panconf>
The name attribute can be a pattern. There will be a caseless match for the <var> name and a case-sensitive match for <user> name attribute value. Tags can be nested.
<?xml version="1.0"?> <panconf> <var name="b$()"> <arrayelems>4</arrayelems> <stringlen>64</stringlen </var> <user name="fred"> <arrayelems>52</arrayelems> <stringlen>71</stringlen <var name="b$()"> <arrayelems>16</arrayelems> <stringlen>128</stringlen </var> </user> </panconf>
Session history
The session history in the PANIC file contains edited highlights of the session. Always included are the session start and end times but other events can be recorded by specifying <history> tags in the panic configuration file. For each event type there is a count to limit the maximum number of events recorded of that type as only the most recent events are kept. The type can be an exact name from the list of possible types:
| Start |
| End |
| DollarRelease |
| DollarEnd |
| Event |
| FormStart |
| FormEnd |
| Function |
| DebuggerBreakIn |
| ImmediateStatement |
or use "*" to match several types. For example:
<history type="form*" count="50"/> <history type="dollarrelease*" count="20"/>
will record at most 50 of each type of form event and also the last 20 occurrences of $RELEASE.
| stringlen | Maximum length of string. |
|||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| arrayelems | Maximum number of array elements. |
|||||||||||||||||||
| poolhandles | Maximum number of pool handles. |
|||||||||||||||||||
| user | Name a user to which the child elements apply
|
|||||||||||||||||||
| var | Name a variable to control in the panic file.
|
|||||||||||||||||||
| library | Name a library to control in the panic file.
|
|||||||||||||||||||
| history | Control type and quantity of sesssion history information.
|
|||||||||||||||||||
| error | Nominate a run-time error not to force a panic file. Session will stil terminate
|
|||||||||||||||||||
| panconf | Root node
|
Compatibility
Introduced with KCML 6.90.
See also: