Spending Limit Policy Session Communication
An external 3G/4G PCEF initiates a policy session using the Diameter Sy Interface.
- Your external PCEF(s) using the Gy interface.
- Your external PCRF(s) using the Sy interface.
Sy Message Flow
- Spending-Limit-Request (SLR) — The SLR has the device ID that is used by MATRIXX Engine to identify the subscriber and the device and return the current policy counters.
Policy counters are associated per device. Note: If there is no policy session, policy counters are not evaluated. Policy changes are evaluated within a single policy session. A device can have multiple policy sessions, but each policy session is independent.The following types of SLRs are used:
- Initial — Opens an Sy session. When the Charging Server receives an SLR-Initial, a
new policy session is created and an MtxPolicyChangeEvent EDR with
eventType=start
(POLICY_SESSION_START = 28) is generated.Note: If no policy counter is selected, an Sy session is not created and an Sy SLA message is sent with an error message. - Intermediate — Updates an existing Sy session. When the Charging Server receives SLR-Intermediate, an MtxPolicyChangeEvent EDR with
eventType=change
(POLICY_CHANGE = 29) is generated only if there is a change to the current policy. Updated sessions do not initiate a session deletion. If no policy counter is selected, an Sy SLA message is sent with an error message.
- Initial — Opens an Sy session. When the Charging Server receives an SLR-Initial, a
new policy session is created and an MtxPolicyChangeEvent EDR with
- Spending-Limit-Answer (SLA) — Has a list of policy counter name/status pairs for both initial and update SLRs.
- Spending-Status-Notification-Request (SNR) — An update that has a list of policy counters name/status pairs indicating which policy counters have
changed. The PCRF determines whether a policy counter change generates a change of policy. When there is policy change caused by usage, a recurring process, or some other
database object change, an SNR is sent. If there is a change to the current policy, an MtxPolicyChangeEvent EDR with
eventType=change
(POLICY_CHANGE = 29) is generated. If a pending policy becomes active, no SNR is sent and an MtxPolicyChangeEvent EDR witheventType=change
(POLICY_CHANGE = 29) is generated. For details about the information included in the MtxPolicyChangeEvent EDR , see the discussion about policy events.Note: When an offer expires or is canceled, the associated policy counter is no longer available. You can configure the policy counter with a Status If Not Present value that is returned in an SNR when the policy counter is no longer available. The Status If Not Present value must be one of the configured policy counters. For example, if the counter has possible values0
or1
, Status If Not Present must be one of those values. It cannot be2
.MATRIXX Policy Application ensures that any uninstalled policy counters are not included in the SNR if they were included in the Pending-Policy-Counter-Information AVP of the last Policy-Counter-Status-Report AVP and the last status sent was the same value as the Status If Not Present value. The uninstalled policy counter with Status If Not Present is only sent once after it becomes unavailable and the policy counter is not referenced again. For more information about SNR AVPs, see the discussion about Spending-Status-Notification Command Request.
- Spending-Status-Notification-Answer (SNA) — Has a confirmation that the SNR was received.
- Session-Termination-Request (STR) — When a session terminate command is received, the
Session-Id
is used to identify and terminate the session. - Session-Termination-Answer (STA) — After the session is terminated, an STA is returned with the
Session-Id
and result code.
For more information about support for the Diameter Interfaces, see MATRIXX Diameter Integration.
A policy session is deleted if an Sy SNA or Gx RAA is not received after the Sy SNR or Gx RAR has been retried the maximum number of times.
Re-evaluating Sy Sessions
When re-evaluating an Sy policy session, if no policy counter is selected, the session becomes invalid and is not re-evaluated again. An Sy SNR message with SN-Request-Type=1 is sent. The PCRF sends an Sy SNA message and an STR message to notify the Charging Server to remove the session.
The session is deleted after the Charging Server receives an STR. If the Charging Server does not receive an SNA on time, multiple SNRs are sent based on the policy configuration and the session is deleted after maximum number of retries. To configure the number of attempts, answer the following create_config.info question: Global:Session:Policy:Notify:How many attempts?. The default is 1.
To configure the delay between attempts, answer the following create_config.info question: Global:Session:Policy:Notify:How long (in seconds) to wait after each attempt?. The default is 30 seconds.
If the Charging Server receives an SNA but does not receive an STR after the configured delay, the session is deleted. To configure the delay before deleting the session, answer the following create_config.py question: Global:Session:Policy:Notify:How long (in seconds) to wait to delete a policy session after the session abort request is sent?. The default is 900 seconds.