|
eValid -- Automated Web Quality Solution
Browser-Based, Client-Side, Functional Testing & Validation,
Load & Performance Tuning, Page Timing, Website Analysis,
and Rich Internet Application Monitoring.
|
|
eValid -- SaveRecord Command
eValid Home
Summary
This command is intended for use in situations where eValid is monitoring
a complex transaction and where the need is to have a simplified record
of timing data.
Command Description
Monitoring SaveRecord Command |
KEY |
COMMAND SYNTAX: Name(...) |
ORIGIN |
EXPLANATION |
COMMENTS |
PROF |
SaveRecord File "Formatted String" [OVERWRITE] |
Edit |
Writes information to the named file based on the
contents of the "Formatted String".
If the optional tag OVERWRITE is present,
the named file is deleted (if it exists) and
THIS is the first record in the new file.
| |
Meaning of Special Parameters in Formatted String
- %e is replaced by the elapsed cumulative time since the last instance
of a SaveRecord command.
Resets across CallScript boundaries.
- %E is replaced by the elapsed cumulative time of the current playback.
Resets across CallScript boundaries.
- %f is replaced by the elapsed total time since the last ResetTimer command.
Does not reset across CallScript boundaries.
- %F is replaced by the elapsed total time of the current playback session.
Does not reset across CallScript boundaries.
- %k is replaced by the total number of bytes downloaded as a result of
the last command completed that caused a download.
Does not reset across CallScript boundaries.
- %K is replaced by the total number of bytes downloaded
so far in the current playback.
Does not reset across CallScript boundaries.
- \t is replaced by a tab character.
- \n is replaced by a newline character.
- In addition,
all of the C runtime function strftime's formatting codes
(see complete list below) are processed in the normal way,
including for example:
- %T is replaced by the current date/time in the format: YYYY/MM/DD HH:MM:SS.
- %I is replaced by the current time in 12-hour format.
- %Z is replaced by the current time zone abbreviation code (e.g. PDT).
|
Example Standard File
Here is how a typical SaveRecord file would appear when a test is run with multiple instances
of SaveRecord commands.
Contents of Script File
|
...
SaveRecord "c:\\file.log" "%T\tLogin\t%E\t%e\tStartup of shopping activity." OVERWRITE
SaveRecord "c:\\file.log" "%T\tShopping\t%E\t%e\tGo ahead and shop."
SaveRecord "c:\\file.log" "%T\tPick\t%E\t%e\tPick an item for the cart."
SaveRecord "c:\\file.log" "%T\tCheckout\t%E\t%e\tCheckout process has concluded."
...
|
Contents of "File" produced during playback... |
...
2017/10/26 13:25:34 Login 241 0 Startup of shopping activity.
2017/10/26 13:26:45 Shopping 2436 1800 Go ahead and shop.
2017/10/26 13:27:56 Pick 3150 1222 Pick an item for the cart.
2017/10/26 13:32:39 Checkout 8192 2200 Checkout process has concluded.
...
|
Notes:
- The sample output above could also be done with TimeStamp commands.
- The order and presentation of data in the named file is under user control.
- Conversions of %E, %e, %B, and %b have precedence over the corresponding
standard strftime codes.
Example XML-Style Format
Here is how you would use SaveRecord to create an XML-style output:
SaveRecord "c:\file.xml" "<RECORD tag='Login' time1='%E' time2='%e' timestamp='%T'/>"
Complete List of Available Time Variables
Here is the complete list of available symbols:
- %a is replaced by the locale's abbreviated weekday name.
- %A is replaced by the locale's full weekday name.
- %b is replaced by the locale's abbreviated month name.
- %B is replaced by the locale's full month name.
- %c is replaced by the locale's appropriate date and time representation.
- %d is replaced by the day of the month as a decimal number [01,31].
- %e is the elapsed time since the last SaveRecord command in this script playback.
- %E is the elapsed time since this script playback began.
- %H is replaced by the hour (24-hour clock) as a decimal number [00,23].
- %I is replaced by the hour (12-hour clock) as a decimal number [01,12].
- %j is replaced by the day of the year as a decimal number [001,366].
- %m is replaced by the month as a decimal number [01,12].
- %M is replaced by the minute as a decimal number [00,59].
- %p is replaced by the locale's equivalent of either a.m. or p.m.
- %S is replaced by the second as a decimal number [00,61].
- %T is replaced by the time ( %H:%M:%S).
- %U is replaced by the week number of the year (Sunday
as the first day of the week) as a decimal number [00,53].
- %w is replaced by the weekday as a decimal number [0,6],
with 0 representing Sunday.
- %W is replaced by the week number of the year
(Monday as the first day of the week)
as a decimal number [00,53].
Note:
All days in a new year preceding the first Monday of that year
are considered to be in week 0.
- %x is replaced by the locale's appropriate date representation.
- %X is replaced by the locale's appropriate time representation.
- %y is replaced by the year without century as a decimal number [00,99].
- %Y is replaced by the year with century as a decimal number.
- %Z is replaced by the timezone name or abbreviation,
or by no bytes if no timezone information exists.
- %% is replaced by %.
Additional Notes
If a submitted string cannot be processed then for reasons of
safety the resulting line in the output file is blank.
If you see blank lines where you believer there should be content
please check the command carefully to make sure there are no conflicts or errors.
The % character is a "reserved character" inside the "Formatted String"
section of the command. Only the specified symbols may follow a %
in that string, except that to express a % in the output you can include
%% on the input.
Use of any other characters than those supported will cause
the output line to contain an error message.
Normally a SaveRecord command writes to a file in a very reliable manner,
but in case you are running a large number of eValid instances
there is a slight chance that
simultaneous execution of a SaveRecord command
by two (or more) eValid instances
will cause some data to be lost.