The Subscriber Data Lookup feature is a pre-credit check feature used to query subscriber-specific information from a relational database and store it in session state, for use by Sentinel features and mappers.
Description
Feature script name |
SubscriberDataLookup |
---|---|
Applicable contexts |
All services |
SAS Support |
No |
Prerequisite Features |
One of SS7 Subscriber Determination Feature, SIP Subscriber Determination Feature or Diameter Subscriber Determination Feature |
Session state inputs and outputs
Inputs
Name | Type | Format | Description | Behaviour if null/invalid |
---|---|---|---|---|
SentinelSelectionKey |
com.opencloud.sentinel.common.SentinelSelectionKey |
selection key (for example, |
For selecting configuration data |
Report featureCannotStart, featureHasFinished |
Subscriber |
String |
SIP, Diameter, or SS7 Subscriber number format — see the respective Subscriber Determination features |
The subscriber for this session whose data is to be retrieved from the subscriber database |
Report featureCannotStart, featureHasFinished |
Error scenarios
Scenario | Handling |
---|---|
Missing lookup type configuration |
Report featureCannotStart |
Sessionstate Subscriber is null |
Report featureCannotStart |
Exception while loading subscriber data from data source |
Report featureCannotStart |
No subscriber data found or empty record |
Report featureFailedToExecute |
Feature responses
Response | Reason |
---|---|
featureCannotStart |
invalid configuration |
featureFailedToExecute |
invalid subscriber |
featureHasFinished |
feature has finished |
Configuration
Subscriber record field configuration:
The feature is configurable to allow additional fields to be added to the subscriber record and associate the additional or existing fields with with new or existing session state fields. These field definitions are configured in the ${SELECTIONKEY}SubscriberDataLookupFieldDefinitionProfileTable
as follows:
Field | Type | Description |
---|---|---|
ColIdx |
String |
Indicates the column index of this field in a subscriber data record. Should match the profile name. |
InsertParamIdx |
int |
Indicates the column index of this field in a subscriber data record. Should match the profile name. |
ResFieldname |
String |
Name of the field when read into a result record |
SessionStateFieldname |
String |
Name of the session state field this field should be loaded into |
Type |
String |
The type of the field, both in session state and in the data source. Supported types: String, Boolean, Integer, String[], Date[], Date |
UpdateParamIdx |
int |
Indicates the column index of this field in a subscriber data record. Should match the profile name. |
The table of fields used for the mapping are scoped to the Sentinel selection key. The selection key may be configured at the following levels:
-
Platform operator
-
Network operator
-
Session type
-
The field definitions are configurable by Sentinel selection key. For example, different network operators will have different subscriber record fields. If a relational database is shared by multiple operators these different sets of subscribers will need to be provisioned in separate tables.
The Subscriber Data Lookup feature may retrieve the subscriber record from:
-
MySQL via JDBC
-
TimesTen via JDBC
-
Oracle via JDBC
-
Cassandra database (experimental).
-
JSLEE profiles (testing purposes)
Data source configuration
The choice of data source type is configured in the SubscriberDataLookupConfigProfileTable:
Field | Type | Description |
---|---|---|
LookupType |
String |
One of dbQuery, profile, profileIms, or Cassandra |
Lookup type | Description |
---|---|
dbQuery |
Uses the dbquery-0 ra entity to perform the subscriber data query. This option is used for all the different RDBMS types such as MySQL, Oracle, and TimesTen. The type of database used and the associated settings are configured in the {{dbquery-0}}resource adaptor entity configuration. See DBQuery Resource Adaptor for further configuration information. |
profile |
Uses the ${PLATFORMOPERATOR}_SubscriberDataRecordProfileTable for the lookup. Only suitable for small sets of subscribers for testing and development purposes. |
profileIms |
Uses the ${PLATFORMOPERATOR}SubscriberDataImsPublicUserIdentityProfileTable and ${PLATFORMOPERATOR}SubscriberDataRecordProfileTable for the query. |
Cassandra |
Experimental. |
SQL statement configuration
For flexibility and ease of integration, the Subscriber Data Lookup Feature is agnostic regarding external SQL data schemas. The SQL queries for a particular network operator are stored in a configuration profile scoped by Sentinel selection key to support the correct mapping.
SubscriberDataLookupSqlConfigProfileTable:
Field | Type | Description |
---|---|---|
LoadSQL |
String |
The SQL query for loading subscriber data from the data source. For example: SELECT * FROM OpenCloud_Subscribers WHERE MSISDN = ? |
ListSQL |
String |
The SQL query for listing Subscriber Data record ids (msisdns). For example: SELECT MSISDN FROM OpenCloud_Subscribers ORDER BY MSISDN |
InsertSQL |
String |
The SQL query for inserting a new Subscriber Data record. For example: INSERT INTO OpenCloud_Subscribers (MSISDN,IMSI,FirstCall,subscriberlanguage,Account,SubscriptionType,ValidityStart, ValidityEnd,HomeZoneEnabled,HomeZoneList,ocsId,FriendsAndFamilyEnabled,FriendsAndFamilyList, ClosedUserGroupEnabled,ClosedUserGroupList,ClosedUserGroupPreferred,CUGIncomingAccessAllowed, CUGOutgoingAccessAllowed,CfBusy,CfNoReply,PromotionList,PromotionValidityStartDates, PromotionValidityEndDates) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) |
UpdateSQL |
String |
The SQL query for updating a Subscriber Data record. For example: UPDATE OpenCloud_Subscribers SET IMSI = ?,FirstCall = ?,subscriberlanguage = ?,Account = ?,SubscriptionType = ?, ValidityStart = ?,ValidityEnd = ?,HomeZoneEnabled = ?,HomeZoneList = ?,ocsId = ?, FriendsAndFamilyEnabled = ?,FriendsAndFamilyList = ?,ClosedUserGroupEnabled = ?, ClosedUserGroupList = ?,ClosedUserGroupPreferred = ?,CUGIncomingAccessAllowed = ?, CUGOutgoingAccessAllowed = ?,CfBusy = ?,CfNoReply = ?,PromotionList = ?, PromotionValidityStartDates = ?,PromotionValidityEndDates = ? WHERE MSISDN = ? |
DeleteSQL |
String |
The SQL query for deleting a Subscriber Data record. For example: DELETE FROM OpenCloud_Subscribers WHERE MSISDN = ? |
loadByImsPublicUserIdentitySQL |
String |
SQL statement for loading a subscriber data record by a subscriber’s IMS public user identity; for example: SELECT subs.* FROM @platform.operator.name@_Subscribers subs INNER JOIN @platform.operator.name@_SubscriberImsPublicUserIdentity sipids ON subs.MSISDN = sipids.SubscriberId WHERE sipids.ImsPublicUserId = ? |
listImsPublicUserIdentitiesSQL |
String |
SQL statement for listing a subscriber’s IMS public user identities based on their subscriber ID |
insertImsPublicUserIdentitySQL |
String |
SQL statement for inserting a new IMS public user identity for a subscriber |
deleteImsPublicUserIdentitySQL |
String |
SQL statement for deleting a single IMS public user identity for a subscriber |
deleteAllImsPublicUserIdentitiesForSubscriberSQL |
String |
SQL statement for deleting all of a subscriber’s IMS public user identities |
useImsPublicUserIdentities |
boolean |
Use IMS Public User Identity SQL statements? |
DatabaseRequestTimeout |
int |
The timeout period for any SQL query. Must be greater than 0 |
AsynchronousQuery |
boolean |
Uses DBQuery RA events to return result sets if true otherwise blocks the staging thread waiting for DatabaseRequestTimeout period using futures. |
Subscriber data schema
The subscriber data schema contains the following mandatory fields (i.e. a field definition for these MUST be present as part of the Subscriber Record Field configuration) for all service types:
Parameter name | Parameter type | Description |
---|---|---|
MSISDN |
String |
Identifies the subscriber record |
Language |
String |
Language code set during first call handling |
Account |
String |
Account code required by the OCS |
The default Sentinel SS7 Service configuration will include the following fields in addition to the mandatory fields:
Parameter name | Parameter type | Description |
---|---|---|
IMSI |
String |
Required by some service features |
OCSId |
String |
Id of the OCS for this subscriber |
SubscriptionType |
String |
identifes the subscription type of the subscriber |
ValidityStart |
String |
Time and timezone of subscription validity. See Subscriber Validity Feature |
ValidityEnd |
String |
Time and timezone of subscription validity. See Subscriber Validity Feature |
HomeZoneEnabled |
Boolean |
True when HomeZone feature is activated for this subscriber. See Home Zone Feature |
HomeZoneList |
String[] |
List of zones for this subscriber. See Home Zone Feature |
FriendsAndFamilyEnabled |
Boolean |
true when HomeZone feature is activated for this subscriber. See Friends and Family Feature |
FriendsAndFamilyList |
String[] |
List of zones for this subscriber. See Friends and Family Feature |
ClosedUserGroupEnabled |
Boolean |
true when HomeZone feature is activated for this subscriber. See Closed User Group Feature |
ClosedUserGroupList |
String[] |
List of zones for this subscriber. See Closed User Group Feature |
ClosedUserGroupPreferred |
Integer |
List of zones for this subscriber. See Closed User Group Feature |
CUGIncomingAccessAllowed |
Boolean |
|
CUGOutgoingAccessAllowed |
Boolean |
|
CfBusy |
String |
Forwarding number on busy. See Default Call Forwarding Feature |
CfNoReply |
String |
Forwarding number on no reply. See Default Call Forwarding Feature |
PromotionList |
String array |
Used by the |
PromotionValidityStartDates |
String[] |
Used by the |
PromotionValidityEndDates |
String[] |
Used by the |
The default Sentinel Diameter Service configuration will include the following fields in addition to the mandatory fields:
Parameter name | Parameter type | Description |
---|---|---|
CURRENTLY NONE |
In the case where a subscriber is a user of both SS7 and Diameter services, the record will contain fields from both; but the Subscriber Data Lookup feature will only load data from fields associated with the selection key.
Example:
MSISDN |
34600000001 |
---|---|
Language |
English |
Account |
6325 |
IMSI |
346000000021234 |
OCSId |
1 |
SubscriptionType |
No |
ValidityStart |
1299193200664 |
ValidityEnd |
3161070000000 |
HomeZoneEnabled |
false |
HomeZoneList |
[WgtnCBD] |
FriendsAndFamilyEnabled |
false |
FriendsAndFamilyList |
[34600000001] |
ClosedUserGroupEnabled |
false |
ClosedUserGroupList |
[CUG1Profile] |
ClosedUserGroupPreferred |
1 |
CfBusy |
34600000002 |
CfNoReply |
34600000003 |
PromotionList |
[FreeOffpeakVoice] |
PromotionValidityStartDates |
[1299193200664] |
PromotionValidityEndDates |
[3161070000000] |
IMS |
Public User Identities |
Parameter Name | Parameter type | Description |
---|---|---|
ImsPublicUserId |
String |
an IMS public user identity |
SubscriberId |
String |
subscriber ID used as key to the subscriber data table |
Configuration profile naming
Configuration Profile Table Name | Description | Profile Naming |
---|---|---|
${PLATFORMOPERATOR}_SubscriberDataRecordProfileTable |
Per subscriber data records — use only for very small subscriber sets |
MSISDN |
${PLATFORMOPERATOR}_SubscriberDataImsPublicUserIdentityProfileTable |
IMS public user identity to subscriber ID table — use only for very small subscriber sets |
IMS Public User Identity, for example sip:user34600000002@opencloud.com |
SubscriberDataLookupConfigProfileTableName |
Field configuration and session state mapping |
SentinelSelectionKey (for example, |
SubscriberDataLookupSqlConfigProfileTableName |
SQL statement configuration |
SentinelSelectionKey (for example, |
${SELECTIONKEY}_SubscriberDataLookupFieldDefinitionProfileTable |
Table for mapping sql columns to session state; note that the SELECTIONKEY part has ‘^’ as separator character in this case for the table name! |
Any name unique to the table |
Database schemas
Database schemas for TimesTen and Oracle are available in the Sentinel release package.
Provisioning interfaces
The SubscriberDataLookup feature subscriber records and configuration may be provisioned using the Sentinel Subscriber Data REST API or web interface for the records and feature configuration.