Calculate inventory velocity agent

The CALCULATE_INVENTORY_VELOCITY agent is run periodically to process the dump records from the YFS_ITEM_NODE_VELOCITY_DUMP table.

The agent works in two modes:

  • 01 - Run the agent in this mode if you want to calculate new peak item velocity.
  • 10 - Run the agent in this mode if you want to process suddenly hot items.

When you run the agent in mode 01, it calculates a new hourly item velocity that is based on the current hour’s data. The agent processes the records for past 2 hours to determine the new peak hourly window. It calculates an hourly and 5-minute peak that is based on the data present in the YFS_ITEM_NODE_VELOCITY_DUMP table. It compares the newly calculated peak hour against the existing peak hour that is found for the clock hour’s date in the YFS_ITEM_NODE_VELOCITY table. If the new hourly velocity has increased, the record is updated for that date. During this time, if the peak 5-minute window has increased, the record is also updated with the new value. Only when a peak hourly rate changes, the peak 5-minute window changes. When this is complete, the agent deletes (and not purges) the dump records processed for the last 2 hours, but not for the last 1 hour. The last 1 hour is left to be again processed during the next run of the agent. This is to ensure that all JVMs have inserted their dump data.

When the agent processes a dump record without a node being stamped, it determines the peak that is based on the dump information of the distribution groups used for monitoring at the network level. The sum of each node in the distribution group and the empty ship node is used to determine the item velocity of the distribution group. For each distribution group used for network level monitoring, the peak hour is calculated. The peak hour and 5-minute windows are created or updated for the empty node that is based on the maximum peak item velocity across the distribution groups.

When you run the agent in mode 10, the agent processes suddenly hot items that is based on the increase in item velocity. The agent determines that the current hour has a 5-minute window (sum of 5-minute across servers per 5-minute window) that is greater than the peak 5-minute window currently recorded in the YFS_ITEM_NODE_VELOCITY table. It will recalculate the existing YFS_INVENTORY_ACTIVITY for this item-node that is based on the new hourly peak window. This new hourly peak is the sum of the current dump in addition to the remaining hour assuming the 5-minute peak. This is to ensure that if velocity increases, the activities are processed faster.

Attributes

Table 1. Calculate inventory velocity agent attributes
Attribute Value
Base Transaction ID CALCULATE_INVENTORY_VELOCITY
Base Process Type General

Criteria Parameters

Calculate Inventory Velocity Agent considers the following criteria parameters.
Table 2. Calculate inventory velocity agent criteria parameters
Parameter Name Description
CollectPendingJobs Optional. If you set the value to Y, the parameter collects information for presentation in the system management console.
NumberOfRecordsToBuffer You can set the number of records to be retrieved and processed by the agent. The default value is zero (0).
Mode Indicates the mode of operation (01 or 10). The default value is 01.

Events Raised

None

Statistics Tracked

NumInventoryItemsProcessed
NumItemNodeVelocityDumpProcessed
NumItemNodeVelocityDumpDeleted
NumItemNodeVelocityUpdated
NumHotItemNodeVelocity

Pending Job Count

None