发明名称 On demand tracing of application code execution
摘要 On demand tracing of application code execution includes: during the execution of the application code, writing trace statements to a circular trace buffer (at a selected and potentially variable detail level); determining whether a pre-defined trigger event has occurred; in response to determining that the trigger event has occurred, outputting one or more trace statements in the circular trace buffer according to pre-defined trace parameters; determining whether a trigger end event has occurred; and in response to determining that the trigger end event has occurred, terminating the outputting of the trace statements. The trigger event and the trigger end event may be defined by names of application code variables, values for the variables, and operators to be used. The trigger end event may further be defined by a time duration for which trace statements are to be outputted, or a number of trace statements to be outputted.
申请公布号 US8799719(B2) 申请公布日期 2014.08.05
申请号 US201113110919 申请日期 2011.05.19
申请人 International Business Machines Corporation 发明人 Shazly Hassan A.
分类号 G06F11/00 主分类号 G06F11/00
代理机构 North Shore Patents, P.C. 代理人 North Shore Patents, P.C. ;Baillie Michele Liu
主权项 1. A computer program product for tracing execution of application code, the computer program product comprising: a computer readable storage hardware having computer readable program code embodied therewith, the computer readable program code configured to: execute the application code comprising a plurality of trace statements encoded within:in response to executing a current trace statement within the application code, write the current trace statement to a circular trace buffer and determine whether a pre-defined trigger event has occurred; andin response to determining that the trigger event has occurred, output the current trace statement from the circular trace buffer,output from the circular trace buffer a number of trace statements before the trigger event according to a pre-defined before-trigger-event parameter, andoutput from the circular trace buffer a number of trace statements after the trigger event until a trigger end event has occurred according to a pre-defined after-trigger-event parameter, wherein the trigger end event comprises a trace end event, wherein the trace end event is defined by parameters comprising a name of a variable in the application code to be used as the trace end event, a value for the variable, and an operator defining a relationship between the variable and the value for the variable, wherein the computer readable program code configured to output from the circular trace buffer the number of trace statements after the trigger event until the trigger end event has occurred according to the pre-defined after-trigger-event parameter is further configured to: determine whether the variable in the application code satisfies the operator and the value; andin response to determining that the variable in the application code satisfies the operator and the value, terminate the outputting of the trace statements from the circular buffer.
地址 Armonk NY US