Turnstile Meters

By default, meters are incremented by a measured usage quantity or a charge quantity. Turnstile meters, unlike the default meters, are updated by an amount of 1.0 each time a charge or a usage session occurs, regardless of the measured quantity. Turnstile meters are defined to count a usage or charge occurrence and do not have a quantity unit.

For example, say a subscriber's wallet contains a usage meter and that subscriber downloads a video that takes 5 minutes to complete the download operation. If the usage meter has the turnstile property set, the meter is incremented by an amount of 1 for the occurrence of the download operation. If the meter does not have the turnstile property set, it is incremented by an amount of 5 to match the duration of the download operation. As another example, say a currency balance is tracked by a charge meter and $5 is subtracted from that balance. If the charge meter has the turnstile property set, it is incremented by an amount of 1 for the occurrence of the $5 charge. If the meter does not have the turnstile property set, it is incremented by an amount of 5 to match the charge amount.

Note: If a turnstile meter is measuring a charge quantity and a session starts by charging an asset quantity and then transitions to charging a currency quantity, or the reverse, the meter will not be incremented for the second charge because it was already incremented once for the initial charge.

To avoid incorrectly incrementing charge meters, they are only incremented during the initial charge operation for each service context within the session. This is to handle cases where a session includes interim messages and multiple charge operations occur within the session.

A composite meter can be a usage meter with the turnstile meter property or a charge meter with the turnstile meter property and must be incremented by 1.0 or not at all.

Note: If a composite meter is a usage meter or a turnstile meter and has aggregation groupings defined with offer fields or rate tags and multiple groupings match when charges are applied in parallel, the component for one grouping is incremented by the full amount and the other components are not incremented. To avoid this situation, use offer fields and rate tags in usage meters or turnstile meters only when multiple groupings always match when multiple charges are applied in parallel.