ASAP 2.7 Extension Manual
Implementing the ASAP Extension in an Application
HP NonStop ASAP Extension Manual—425265-004
4-24
Obtaining the Last Sample Time
Obtaining the Last Sample Time
A program can obtain the last ASAP sample time by calling the
ASAP_GETLASTSAMPLETIME_ procedure. The time unit returned is the number of
seconds since system cold load that ASAP last sampled the shared memory segment
to gather and compute application statistics.
ASAP_GETLASTSAMPLETIME_
ASAP_GETLASTSAMPLETIME_ returns the time, in the number of seconds since
system cold load, of the last time that ASAP sampled the shared memory segment to
gather application data.
error
INT
indicates the outcome of the procedure call:
seg^offset
INT(32)
is the offset into the shared memory segment allocated to the metrics for this
domain. This was initially returned to the caller in its call to
ASAP_REGISTER_.
error^detail
INT .EXT:ref:1
is returned here when this parameter is used and an error occurs.
error := ASAP_GETLASTSAMPLETIME_( seg^offset !i
[,error^detail] !o
,sample^secs !o
) EXTENSIBLE;
Error Description
–1 Calling process is not named.
–2 Parameter error. error^detail contains the parameter in error unless it
is itself in error.
–3 File-system error. error^detail contains the file-system error number.
–4 Memory-not-mine error. Memory slot is now owned by another domain or is
corrupt.
–6 Memory address trap detected. The supplied shared memory address
causes a memory trap.