Number position information storage method, system, equipment and medium
By storing number position information in the form of key-value pairs in mobile communication networks and using distributed caching technology, the problem that traditional databases are difficult to meet large-scale number position query is solved, efficient and fast query capabilities are achieved, and user experience is improved and network stability.
Patent Information
- Application Number
- CN202411571937.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-05
- Publication Date
- 2025-02-18
AI Technical Summary
The traditional number position information storage method based on relational databases is difficult to meet the needs of large-scale number position query, resulting in network congestion and user communication experience.
The number position information is organized and stored in the form of key-value pairs, and the forward key-value pair data is generated by the user number as keys, and the reverse key-value pair data is generated by the base station cell position information as keys, and the distributed cache technology is used to transfer these data. Store in memory.
It realizes fast and efficient number position information query, meets the needs of large-scale number position query, and improves the network's processing capabilities and user's communication experience.
Smart Images

Figure CN119485277A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communication technology, and in particular to a method, system, device and medium for storing number location information. Background Art
[0002] In mobile communication networks, a large amount of data traffic is transmitted to the core network through backhaul links. With the explosive growth of mobile traffic, traditional backhaul links are unable to meet the growing demand for data transmission, resulting in frequent network congestion, which seriously affects users' communication experience and network stability.
[0003] In order to reduce the demand for access to the core network and lower the maintenance and operating costs caused by network congestion, relational databases are currently mainly used to store number location information, thereby providing data support for number location query services.
[0004] However, the method of storing the number location information associated with each user number based on a relational database in related technologies is difficult to meet the needs of large-scale number location queries, and thus it is difficult to provide timely and effective data support for business scenarios such as high-throughput emergency SMS delivery and emergency voice services. Summary of the invention
[0005] In view of the above problems, embodiments of the present application provide a method, system, device and medium for storing number location information, so as to overcome the above problems or at least partially solve the above problems.
[0006] In a first aspect of an embodiment of the present application, a method for storing number location information is provided, the method comprising: Obtaining the current location information of each number from the core network, the number location information including: the user number, the location information of the base station cell associated with the user number, and the Internet interconnection protocol IP address and domain name information of the service session control function S-CSCF network element associated with the user number; Using the user number contained in each of the number location information as a key and other information contained in each of the number location information as a value, generating first key-value pair data associated with each of the user numbers; For each base station cell location information included in each number location information, the base station cell location information is used as a key, and other information included in different number location information associated with the base station cell location information is used as a value to generate second key-value pair data associated with the base station cell location information; Based on the distributed cache technology, each of the first key-value pair data and each of the second key-value pair data are stored in the memory.
[0007] According to a second aspect of an embodiment of the present application, a number location information storage system is provided, the system comprising a signaling monitoring system and a signaling sharing platform, wherein: The signaling monitoring system is used to obtain the location information of each number at the current moment from the core network, and the number location information includes: the user number, the location information of the base station cell associated with the user number, and the Internet interconnection protocol IP address and domain name information of the service session control function S-CSCF network element associated with the user number; The signaling sharing platform is used to use the user number contained in each of the number location information as a key and other information contained in each of the number location information as a value to generate first key-value pair data associated with each of the user numbers; The signaling sharing platform is further used to generate second key-value pair data associated with the location information of the base station cell, using the location information of the base station cell as a key and other information included in different number location information associated with the location information of the base station cell as a value, for the location information of each base station cell included in the respective number location information; The signaling sharing platform is also used to store each of the first key-value pair data and each of the second key-value pair data in the memory based on the distributed cache technology.
[0008] According to a third aspect of an embodiment of the present application, an electronic device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the steps of the method for storing number location information described in the first aspect are implemented.
[0009] According to a fourth aspect of an embodiment of the present application, a computer-readable storage medium is provided, on which a computer program / instruction is stored. When the computer program / instruction is executed by a processor, the steps of the number location information storage method described in the first aspect are implemented.
[0010] The embodiment of the present application includes the following advantages: the number location information is organized and stored in the form of key-value pairs, by using the user number as the key to generate forward key-value pair data (i.e., the first key-value pair data), and using the location information of the base station cell as the key to generate reverse key-value pair data (i.e., the second key-value pair data), thereby based on the forward and reverse key-value pair data storage method, it is possible to meet the one-to-one number location information query requirements (i.e., the query requirements for accurately querying the number location information of a single user number) while taking into account the one-to-many number location information query requirements (i.e., the query requirements for batch querying the number location information of multiple user numbers), and based on the distributed cache technology, the first key-value pair data and the second key-value pair data are stored in the memory, which can further improve the data query efficiency. In this way, it is possible to meet the large-scale number location query requirements and provide timely and effective data support for business scenarios such as high-throughput emergency SMS delivery and emergency voice services. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the description of the embodiments of the present application will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0012] Figure 1 is an implementation flow chart of a method for storing number location information in an embodiment of the present application; Figure 2 It is a structural diagram of a number location information storage system in an embodiment of the present application; Figure 3 It is a schematic diagram of a number location information storage and query process in an embodiment of the present application; Figure 4 It is a schematic diagram of a hash distribution in an embodiment of the present application; Figure 5 It is a schematic diagram of a memory database for storing positive key-value pair data in an embodiment of the present application; Figure 6 It is a schematic diagram of a memory database for storing reverse key-value pair data in an embodiment of the present application; Figure 7 It is a schematic diagram of data update when a number position does not change in an embodiment of the present application; Figure 8 It is a schematic diagram of data update when a number position changes in an embodiment of the present application; Fig. 9 It is a schematic diagram of a forward key-value pair data update in an embodiment of the present application; Fig.10 It is a schematic diagram of a reverse key-value pair data update in an embodiment of the present application; Fig.11 is a schematic diagram of a data query in an embodiment of the present application; Fig.12 It is a structural diagram of a number location information storage device in an embodiment of the present application; Fig.13 It is a schematic diagram of an electronic device in an embodiment of the present application. DETAILED DESCRIPTION
[0013] To facilitate understanding of the technical solutions provided by the present application, the main technical concepts involved in the embodiments of the present application are briefly described below.
[0014] Backhaul link: In mobile communication networks, it refers to the data transmission link from the base station to the core network.
[0015] Serving-Call Session Control Function (S-CSCF) network element: The network element in the core network responsible for processing user registration and session control.
[0016] Base station cell: refers to the geographical area covered by a base station in mobile communications, usually used to describe the service area of mobile users (i.e. terminals).
[0017] Voice service based on LTE network (Voice over LTE, VoLTE): It allows users to make voice calls through 4G network.
[0018] MD5: A hash function that produces a 128-bit (16-byte) hash value, which is often used to ensure the integrity of information transmission.
[0019] Key-Value data: This data consists of a key and a value. This data structure allows the value to be quickly retrieved through the key, which is conducive to the rapid retrieval and update of data.
[0020] Distributed caching technology: A technology that distributes data cache to multiple storage nodes, which can improve data access speed and system scalability.
[0021] Application Programming Interface (API): refers to a set of rules and definitions for interaction between software systems.
[0022] In conjunction with the accompanying drawings, a number location information storage method, system, device and medium provided by the embodiments of the present application are described in detail through some embodiments and their application scenarios.
[0023] First, refer to Figure 1 FIG. 1 is a flowchart of a method for storing number location information provided by an embodiment of the present application. The method may include the following steps: Step S11: Obtain the current number location information from the core network, the number location information including: user number, location information of the base station cell associated with the user number, and Internet Protocol IP address and domain name information of the service session control function S-CSCF network element associated with the user number.
[0024] The location information of the base station cell may include a tracking area code (Tracking Area Code, TAC), a base station identifier (EnobID), a cell identity (Cell Identity, CI), and the like.
[0025] In specific implementation, a real-time data channel can be pre-established or an existing real-time data channel can be reused to obtain the user number, the location information of the base station cell associated with the user number, and the Internet Protocol (IP) address and domain name information of the S-CSCF network element associated with the user number and other number location information in real time (or periodically) from the relevant network elements in the core network.
[0026] Step S12: using the user number contained in each piece of number location information as a key, and using other information contained in each piece of number location information as a value, to generate first key-value pair data associated with each piece of user number.
[0027] In the specific implementation, for each number location information, the user number contained in the number location information is used as the Key, and the other information contained in the number location information (i.e., the location information of the base station cell, the IP address and domain name information of the S-CSCF network element stationed in the network) is used as the Value, thereby adopting the Key-Value data structure to generate positive key-value pair data (i.e., the first key-value pair data).
[0028] It can be understood that the forward key-value pair data, by using the user number as the key, can support accurate and fast query of the number location information associated with a single user number, thereby providing timely and effective data support for business scenarios such as high-throughput emergency SMS delivery and emergency voice services for designated numbers.
[0029] Step S13: For the location information of each base station cell contained in the respective number location information, the location information of the base station cell is used as the key, and other information contained in the different number location information associated with the location information of the base station cell is used as the value to generate second key-value pair data associated with the location information of the base station cell.
[0030] In specific implementation, the number location information may be grouped first according to whether the location information of the included base station cells is the same. Then, for each base station cell location information, the base station cell location information is used as the key, and other information (i.e., the user number, the IP address and domain name information of the S-CSCF network element stationed in the network) included in each number location information in the group corresponding to the base station cell location information is used as the value, thereby using the Key-Value data structure to generate reverse key-value pair data (i.e., the second key-value pair data).
[0031] It can be understood that the reverse key-value pair data can support batch and fast query of number location information associated with multiple user numbers by using the location information of the base station cell as the key, that is, it can support batch query of number location information associated with multiple terminals in the base station cell, thereby providing timely and effective data support for business scenarios such as high-throughput emergency SMS sending and emergency voice services in a specified area (such as one or more base station cells).
[0032] Step S14: storing each of the first key-value pair data and each of the second key-value pair data in a memory based on a distributed cache technology.
[0033] In specific implementation, a storage cluster including multiple storage nodes (which may be multiple virtual machines or servers) may be established in advance at the edge of the network, and then each of the first key-value pair data and each of the second key-value pair data may be sent to the multiple storage nodes respectively, so that the multiple storage nodes store the received data in their corresponding memory (such as a memory database), thereby storing the number location information in the memory based on the distributed cache technology.
[0034] It can be understood that the number location information is organized into the form of keys and values, and stored in the memory using distributed caching technology. The storage process of the number location information is optimized from multiple aspects such as data structure, data storage method and storage location, so that the system can quickly process high-concurrency query requests, thereby meeting large-scale number location query needs (such as the location information query needs of more than 10,000 downlink numbers per second).
[0035] Optionally, the method further includes: persistently storing the data stored in the memory according to a set period, for example, persistently storing the data in the memory of the storage node to a local disk every hour to prevent the data in the memory from being lost due to a node restart.
[0036] By adopting the technical solution of the embodiment of the present application, the number location information is organized and stored in the form of key-value pairs, and the user number is used as the key to generate the forward key-value pair data (i.e., the first key-value pair data), and the location information of the base station cell is used as the key to generate the reverse key-value pair data (i.e., the second key-value pair data). Based on the forward and reverse key-value pair data storage method, it is possible to meet the one-to-one number location information query demand (i.e., the query demand for accurately querying the number location information of a single user number) while taking into account the one-to-many number location information query demand (i.e., the query demand for batch querying the number location information of multiple user numbers), and based on the distributed cache technology, the first key-value pair data and the second key-value pair data are stored in the memory, which can further improve the data query efficiency. In this way, it is possible to meet the large-scale number location query demand and provide timely and effective data support for business scenarios such as high-throughput emergency SMS delivery and emergency voice services.
[0037] As a possible implementation manner, the number location information further includes registration time; and the method further includes: Step S21: for the first user number associated with the first key-value pair data stored in the memory, obtain the latest number location information associated with the first user number from the core network, and detect whether there is a location change of the first user number.
[0038] In specific implementation, the number location information including the first user number can be extracted from the currently acquired number location information according to the first user number, the extracted number location information is used as the latest number location information associated with the first user number, and whether the first user number has a location change is detected.
[0039] For example, it may be detected whether relevant signaling indicating that the first user number has a location change is received from the core network (for example, the core network may be configured to indicate the location change of the user number once every fifty minutes). Alternatively, the latest number location information associated with the first user number may be compared with the first key-value pair data associated with the first user number to determine whether there is a difference between the location information of the base station cell associated with the first user number and the IP address and domain name information of the S-CSCF network element in the two aforementioned data. If there is a difference, it means that the first user number has a location change, and if there is no difference, it means that the first user number has no location change.
[0040] Step S22: when there is no location change of the first user number, the registration time in the latest number location information is used to update the registration time in the first key-value pair data associated with the first user number in the memory.
[0041] In a specific implementation, if there is no location change of the first user number, only the registration time contained in the first key-value pair data associated with the first user number in the memory may be updated to ensure the correctness of the registration time recorded in the first key-value pair data.
[0042] Step S23: when the location of the first user number changes, the value corresponding to the first key-value pair data associated with the first user number is updated in the memory using other information in the latest number location information except the first user number.
[0043] In a specific implementation, if the location of the first user number changes, the value (Value) corresponding to the first key-value pair data associated with the first user number is updated in the memory, that is, the registration time, the location information of the base station cell, and the IP address and domain name information of the S-CSCF network element contained in the first key-value pair data are updated to ensure the correctness of the number location information recorded in the first key-value pair data.
[0044] Step S24: updating the second key-value pair data stored in the memory according to the updated first key-value pair data.
[0045] In a specific implementation, the number location information associated with the first user number recorded in the relevant second key-value pair data can be updated according to the updated first key-value pair data; or, the second key-value pair data can be regenerated for the location information of the base station cell associated with the updated first key-value pair data, and the regenerated second key-value pair data can be used to overwrite the relevant second key-value pair data stored in the memory, so as to update the second key-value pair data stored in the memory. In this way, the correctness of each number location information recorded in the second key-value pair data can be guaranteed.
[0046] In this implementation, the present application ensures the timeliness of the data stored in the memory by detecting whether there is a location change of the user number, and then updating the relevant first key-value pair data and second key-value pair data; and because the first key-value pair data uses the user number as the key, it is possible to quickly query and update the first key-value pair data associated with a specific user number; and then retrieve and update the relevant second key-value pair data based on the updated first key-value pair data, thereby achieving timely update of the number location information recorded in the memory (such as the network element information of the user number), so as to better adapt to actual communication scenarios where location information is frequently updated, and meet the requirements of high real-time and high accuracy of number location information in emergency message sending scenarios related to disaster recovery and rescue.
[0047] Optionally, the step S24 includes: Step S241: Acquire location information of a first base station cell associated with the first user number from the updated first key-value pair data; Step S242: using other information in the updated first key-value pair data except the location information of the first base station cell, updating the value corresponding to the second key-value pair data associated with the location information of the first base station cell in the memory.
[0048] In specific implementation, in order to further improve the updating efficiency, the location information of the first base station cell can be used as a key to quickly retrieve the relevant second key-value pair data. Then, other information (i.e., user number, registration time, and IP address and domain name information of the S-CSCF network element) in the updated first key-value pair data except the location information of the first base station cell is added to the value corresponding to the second key-value pair data, thereby updating the second key-value pair data stored in the memory. Optionally, the validity of the data stored in the memory can also be regularly judged according to the registration time, and invalid data can be cleared.
[0049] As a possible implementation, the method further includes: Step S31: receiving a query request through a pre-configured application programming interface API.
[0050] In specific implementation, an API can be configured to uniformly receive query requests from external devices; alternatively, different APIs can be configured for different types of query requests. For example, query requests carrying user numbers (precise queries of corresponding number location information) and query requests carrying base station cell location information (batch queries of corresponding number location information) can be received using different APIs, thereby avoiding the classification process of query requests and improving the processing efficiency of query requests.
[0051] Step S32: In the case where the query request carries a second user number, obtain the first key-value pair data associated with the second user number from the memory, generate and return a first query result based on the obtained first key-value pair data, wherein the first query result is used to send a message to the terminal associated with the second user number, and the first query result includes: the location information of the base station cell associated with the second user number and the domain name information of the S-CSCF network element.
[0052] In the specific implementation, the second user number is used as the key (Key), and the GET function is used to quickly obtain the value (Value) corresponding to the second user number from each first key-value pair data stored in the memory, and then the location information of the base station cell and the domain name information of the S-CSCF network element are extracted from the obtained value, and the extracted information is returned as the first query result to support related external devices to send messages to the second number, such as using the second number to send emergency text messages or voice messages to the corresponding terminal, and to connect emergency calls based on the S-CSCF network element attached to the second number.
[0053] Step S33: In the case where the query request carries the location information of the second base station cell, obtain the second key-value pair data associated with the location information of the second base station cell from the memory, and generate and return the second query result based on the obtained second key-value pair data, wherein the second query result is used to send messages to each terminal associated with the base station cell, and the second query result includes: multiple user numbers in the base station cell associated with the location information of the second base station cell, and domain name information of the S-CSCF network element associated with each of the multiple user numbers.
[0054] In the specific implementation, the location information of the second base station cell is used as the key (Key), and the GET function is used to quickly obtain the value (Value) corresponding to the location information of the second base station cell from each second key-value pair data stored in the memory, and then multiple user numbers and domain name information of the S-CSCF network elements associated with each of the multiple user numbers are extracted from the obtained values, and the extracted information is returned as the second query result to support related external devices to send messages to the specified area, such as using each user number in the second base station cell to send emergency text messages or voice messages to the corresponding terminal, and making emergency call connections based on the S-CSCF network elements attached to each user number.
[0055] As a possible implementation manner, after obtaining the location information of each number at the current moment from the core network, the method further includes: Step S15: For each piece of number location information, determine a target hash value corresponding to the user number in the number location information based on a preset hash function, and replace the user number in the number location information with the target hash value.
[0056] In specific implementation, a preset hash function such as MD5 can be used to calculate the target hash value corresponding to the user number, thereby converting the user number into an information form that is not easily recognizable. By replacing the user number with the target hash value in the number location information, the user number can be prevented from being leaked in the subsequent data processing and storage stages, thereby protecting the user's privacy.
[0057] After obtaining the target hash value corresponding to each user number, the above step S14 can be implemented by the following step S16: Step S16: According to the target hash value corresponding to each user number, each of the first key-value pair data and each of the second key-value pair data are stored in the memory of different storage nodes in the distributed cache cluster, wherein the different storage nodes are used to store data associated with different hash values.
[0058] In a specific implementation, different hash value intervals may be pre-configured for different storage nodes, and the different hash value intervals are used to distribute data associated with different user numbers more evenly to different storage nodes.
[0059] Specifically, for each user number, the storage node used to store the information of the user number in the relevant first key-value pair data and the second key-value pair data is determined according to the hash value interval to which the target hash value corresponding to the user number belongs. This implements the distributed cache of each of the first key-value pair data and each of the second key-value pair data, and ensures that the data associated with the same user number can be read and written by the same storage node, which is conducive to further improving the query efficiency.
[0060] In this implementation, it is considered that the hash value can ensure the uniqueness of the user number and increase its difference: even if two different user numbers look similar, their hash values will be completely different; therefore, allocating storage nodes based on the hash value and using it as a key for data retrieval can avoid confusion of similar user numbers and further improve retrieval (i.e., query) efficiency, and can avoid the situation where the same storage node processes too many similar user numbers, thereby helping to achieve load balancing, avoiding the situation where some nodes are overloaded while other nodes are idle, thereby optimizing resource usage.
[0061] As a possible implementation manner, the obtaining the location information of each number at the current moment from the core network includes: Step S41: collecting registration signaling from the S-CSCF network element in the core network in real time through the first real-time data channel.
[0062] In specific implementation, a new real-time data channel may be created, or an existing real-time data channel may be reused, to achieve real-time data communication with the S-CSCF network element in the core network.
[0063] Step S42: acquiring various target information from various registration signalings currently collected, the target information including: user number, location information of a base station cell associated with the user number, and an IP address of an S-CSCF network element associated with the user number.
[0064] In specific implementation, the collected registration signaling is parsed to extract information related to voice and SMS services (ie, the target information) to reduce the volume of data involved in subsequent data processing and storage.
[0065] Step S43: Generate each domain name query request according to each target information, and send each domain name query request to the core network through the second real-time data channel.
[0066] In the specific implementation, a new real-time data channel can be created, or an existing real-time data channel can be reused to realize real-time data communication with relevant network elements with domain name query function in the core network, wherein the relevant network element can be a network element with telephone number mapping Domain Name System (enumDNS) function, which can return the domain name information of the relevant S-CSCF network element according to the user number.
[0067] Step S44: Determine the target information and the domain name information of the S-CSCF network elements returned by the core network in response to the domain name query requests as the number location information at the current moment.
[0068] In this implementation, different real-time data channels are used to collect and query large-scale flow data, which can realize real-time collection and analysis of massive signaling data, so as to obtain the latest target information and domain name information of the S-CSCF network element (i.e., number location information) in time to store and update the number location information. Compared with the periodic data collection and post-analysis based on minutes (such as every 5 minutes or every 15 minutes) or hours in the related technology, this application can greatly improve the timeliness of the stored number location information.
[0069] For example, refer to Figure 2The structural diagram of the number location information storage system shown in the figure takes the number location information storage system executing the number location information storage method provided in the present application as an example to illustrate the implementation process of the method.
[0070] Reference Figure 3 The schematic diagram of the number location information storage and query process shown in FIG. 1 includes the following steps: Step 1: The signaling monitoring system obtains the location information of each number at the current moment.
[0071] In this step, the signaling monitoring system in the number location information storage system collects the real-time call detail record (CDR) registration signaling call single flow (which includes the registration signaling from the user received by the S-CSCF network element) in the core network through the real-time data channel, and extracts the value of the specified field from the real-time CDR registration signaling call single flow to obtain various target information, thereby reducing the resource overhead for subsequent storage and calculation; wherein the target information includes: the calling number (i.e., the user number), the IP address of the S-CSCF network element for receiving the relevant registration signaling, and the location information of the base station cell to which the calling number belongs.
[0072] At the same time, the signaling monitoring system queries the domain name information of the relevant S-CSCF network element in the VoLTE network through the A interface of another real-time data channel based on the currently acquired target information, and uses the combination of the obtained target information and domain name information as the number location information.
[0073] Then, the signaling monitoring system sends the number location information to the southbound interface of the signaling sharing platform in the number location information storage system through the socket interface in real time. The signaling sharing platform can thereby realize real-time processing of the real-time stream of the number location information, thereby ensuring the real-time processing of the data.
[0074] Step 2: The signaling sharing platform converts the user number in the number location information into a target hash value based on MD5, so that the same number can be pushed to the same storage node in the storage cluster for processing.
[0075] In specific implementation, refer to Figure 4 As shown in the schematic diagram of hash distribution, the signaling sharing platform can distribute relevant data to storage nodes based on hash values, and the storage nodes then store the received data in their own memory database (i.e., number location storage KV library). Optionally, a storage node and its backup node can be deployed on a virtual machine, and each storage node and its backup node can ensure data consistency based on a message synchronization mechanism.
[0076] Step 3: The signaling sharing platform stores the forward number location information.
[0077] In this step, the signaling sharing platform uses the user number as the key, the location information of the base station cell associated with the user number, the IP address and domain name information of the S-CSCF network element stationed in the network as the value, and uses the Key-Value data structure to generate positive key-value pair data and send it to the relevant storage node for memory storage. The positive key-value pair data is shown in Table 1 below, and the schematic diagram of the memory database for storing positive key-value pair data is shown in Figure 5 shown.
[0078] Table 1 Example of positive key-value pair data
[0079] Step 4: The signaling sharing platform stores the reverse number location information.
[0080] In this step, the signaling sharing platform uses the location information of the base station cell as the key, the user number associated with the location information of the base station cell, the IP address and domain name information of the S-CSCF network element on the network as the value, and uses the Key-Value data structure to generate reverse key-value pair data and send it to the relevant storage node for memory storage. The reverse key-value pair data is shown in Table 2 below, and the schematic diagram of the memory database for storing reverse key-value pair data is shown in Table 2 below. Figure 6 shown.
[0081] Table 2 Example of positive key-value pair data
[0082] Among them, refer to Figure 7 The schematic diagram of data update when the number position has not changed is shown. After the real-time data is associated, if it is detected that the user number associated with the real-time data has not changed in position, the registration message time (ie, registration time) in the related forward and reverse key-value pair data is updated; refer to Figure 8 The schematic diagram of data update when the number position changes is shown. When the real-time data is associated, if it is detected that the relevant user number has a position change, the signaling sharing platform first searches for the relevant positive key-value pair data with the Key as the user number based on the latest number location information of the user number, and then updates the base station cell location information, registration message time, IP address and domain name information (i.e., Value) of the S-CSCF network element in the positive key-value pair data.
[0083] Then, the signaling sharing platform takes the location information of the base station cell in the Value as the Key to search for the relevant reverse key-value pair data, and updates the user number, registration message time, IP address and domain name information of the S-CSCF network element in the Value of the reverse key-value pair data to ensure that the stored actual number location information is the latest data; wherein, the schematic diagram of the forward key-value pair data update is as follows Fig. 9 As shown, the schematic diagram of the reverse key-value pair data update is as follows Fig.10 shown.
[0084] Step 5: The signaling sharing platform receives a query request carrying the user number or the location information of the base station cell, and returns the query result.
[0085] In this step, refer to Fig.11 As shown in the schematic diagram of data query, the signaling sharing platform receives query requests through API. For each query request carrying a user number, the signaling sharing platform uses the user number as a key to perform high-concurrency queries on the forward key-value pair data in the memory of each storage node of the storage cluster, thereby enabling the query and return of the domain name information of the S-CSCF network element where the relevant number resides and the location information of the base station cell at a rate of 50,000 numbers per second; for a query request carrying the location information of the base station cell, the signaling sharing platform uses the location information of the base station cell as a key to perform high-concurrency queries on the reverse key-value pair data in the memory of each storage node of the storage cluster, and returns the queried domain name information of each user number and S-CSCF network element as a query result.
[0086] Based on the number location information storage method provided in the embodiment of the present application, an emergency SMS delivery test was conducted, and the SMS test report is shown in Table 3. After multiple tests, the downlink delivery of emergency SMS meets the delivery rate of 10,000 messages per second, the total time consumed to send to the S-CSCF network element is 1 minute and 18 seconds, and the time consumed to receive the status report is 1 minute and 51 seconds, which generally meets the delivery requirements of ultra-massive SMS.
[0087] Table 3 SMS test report
[0088] For the method embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should be aware that the embodiments of the present application are not limited by the order of the actions described, because according to the embodiments of the present application, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily required by the embodiments of the present application.
[0089] Second, Figure 2: is a structural diagram of a number location information storage system according to an embodiment of the present application, wherein the system includes a signaling monitoring system and a signaling sharing platform, wherein: The signaling monitoring system is used to obtain the location information of each number at the current moment from the core network, and the number location information includes: the user number, the location information of the base station cell associated with the user number, and the Internet interconnection protocol IP address and domain name information of the service session control function S-CSCF network element associated with the user number; The signaling sharing platform is used to use the user number contained in each of the number location information as a key and other information contained in each of the number location information as a value to generate first key-value pair data associated with each of the user numbers; The signaling sharing platform is further used to generate second key-value pair data associated with the location information of the base station cell, using the location information of the base station cell as a key and other information included in different number location information associated with the location information of the base station cell as a value, for the location information of each base station cell included in the respective number location information; The signaling sharing platform is also used to store each of the first key-value pair data and each of the second key-value pair data in the memory based on the distributed cache technology.
[0090] By adopting the technical solution of the embodiment of the present application, the number location information is organized and stored in the form of key-value pairs, and the user number is used as the key to generate the forward key-value pair data (i.e., the first key-value pair data), and the location information of the base station cell is used as the key to generate the reverse key-value pair data (i.e., the second key-value pair data). Based on the forward and reverse key-value pair data storage method, it is possible to meet the one-to-one number location information query demand (i.e., the query demand for accurately querying the number location information of a single user number) while taking into account the one-to-many number location information query demand (i.e., the query demand for batch querying the number location information of multiple user numbers), and based on the distributed cache technology, the first key-value pair data and the second key-value pair data are stored in the memory, which can further improve the data query efficiency. In this way, it is possible to meet the large-scale number location query demand and provide timely and effective data support for business scenarios such as high-throughput emergency SMS delivery and emergency voice services.
[0091] Optionally, the number location information also includes registration time; The signaling monitoring system is further configured to obtain, from the core network, the latest number location information associated with the first user number associated with the first key-value pair data stored in the memory, and detect whether there is a location change of the first user number; The signaling sharing platform is further configured to update the registration time in the first key-value pair data associated with the first user number in the memory using the registration time in the latest number location information when there is no location change of the first user number; The signaling sharing platform is further configured to update, in a memory, a value corresponding to the first key-value pair data associated with the first user number using other information in the latest number location information except the first user number when the first user number has a location change; The signaling sharing platform is further used to update the second key-value pair data stored in the memory according to the updated first key-value pair data.
[0092] Optionally, the signaling sharing platform is further used to perform the following steps: Acquire location information of a first base station cell associated with the first user number from the updated first key-value pair data; Using other information in the updated first key-value pair data except the location information of the first base station cell, the value corresponding to the second key-value pair data associated with the location information of the first base station cell is updated in the memory.
[0093] Optionally, the signaling sharing platform is further used to perform the following steps: Receive query requests through a pre-configured application programming interface API; In the case where the query request carries the second user number, obtaining first key-value pair data associated with the second user number from the memory, generating and returning a first query result according to the obtained first key-value pair data, wherein the first query result is used to send a message to the terminal associated with the second user number, and the first query result includes: location information of the base station cell associated with the second user number and domain name information of the S-CSCF network element; In the case where the query request carries the location information of the second base station cell, second key-value pair data associated with the location information of the second base station cell is obtained from the memory, and a second query result is generated and returned based on the obtained second key-value pair data, wherein the second query result is used to send a message to each terminal associated with the base station cell, and the second query result includes: multiple user numbers in the base station cell associated with the location information of the second base station cell, and domain name information of the S-CSCF network element associated with each of the multiple user numbers.
[0094] Optionally, the signaling sharing platform is further used to perform the following steps: For each of the number location information, determine a target hash value corresponding to the user number in the number location information based on a preset hash function, and replace the user number with the target hash value in the number location information; According to the target hash value corresponding to each user number, each of the first key-value pair data and each of the second key-value pair data are respectively stored in the memory of different storage nodes in the distributed cache cluster, wherein the different storage nodes are respectively used to store data associated with different hash values.
[0095] Optionally, the signaling monitoring system is further used to perform the following steps: Collecting registration signaling from the S-CSCF network element in the core network in real time through the first real-time data channel; Acquire each target information from each currently collected registration signaling, the target information including: a user number, location information of a base station cell associated with the user number, and an IP address of an S-CSCF network element associated with the user number; Generate each domain name query request according to each target information, and send each domain name query request to the core network through a second real-time data channel; The target information and the domain name information of the S-CSCF network elements returned by the core network in response to the domain name query requests are determined as the number location information at the current moment.
[0096] Optionally, the signaling sharing platform is also used to persistently store the data stored in the memory according to a set period.
[0097] Thirdly, Fig.12 : is a schematic diagram of the structure of a number location information storage device according to an embodiment of the present application, the device comprising: The information acquisition module 1201 is used to obtain the location information of each number at the current moment from the core network, where the number location information includes: the user number, the location information of the base station cell associated with the user number, and the Internet interconnection protocol IP address and domain name information of the service session control function S-CSCF network element associated with the user number; The first processing module 1202 is used to use the user number included in each of the number location information as a key and other information included in each of the number location information as a value to generate first key-value pair data associated with each of the user numbers; The second processing module 1203 is used to generate second key-value pair data associated with the location information of the base station cell, using the location information of each base station cell included in the respective number location information as a key and other information included in different number location information associated with the location information of the base station cell as a value; The data storage module 1204 is used to store each of the first key-value pair data and each of the second key-value pair data in the memory based on the distributed cache technology.
[0098] By adopting the technical solution of the embodiment of the present application, the number location information is organized and stored in the form of key-value pairs, and the user number is used as the key to generate the forward key-value pair data (i.e., the first key-value pair data), and the location information of the base station cell is used as the key to generate the reverse key-value pair data (i.e., the second key-value pair data). Based on the forward and reverse key-value pair data storage method, it is possible to meet the one-to-one number location information query demand (i.e., the query demand for accurately querying the number location information of a single user number) while taking into account the one-to-many number location information query demand (i.e., the query demand for batch querying the number location information of multiple user numbers), and based on the distributed cache technology, the first key-value pair data and the second key-value pair data are stored in the memory, which can further improve the data query efficiency. In this way, it is possible to meet the large-scale number location query demand and provide timely and effective data support for business scenarios such as high-throughput emergency SMS delivery and emergency voice services.
[0099] Optionally, the number location information further includes registration time; and the device further includes: an information detection module, configured to obtain, from a core network, the latest number location information associated with a first user number associated with the first key-value pair data stored in the memory, and detect whether there is a location change of the first user number; A first updating module, configured to update the registration time in the first key-value pair data associated with the first user number in the memory by using the registration time in the latest number location information when there is no location change of the first user number; a second updating module, configured to update, in a memory, a value corresponding to the first key-value pair data associated with the first user number, using other information except the first user number in the latest number location information when the first user number has a location change; The third updating module is used to update the second key-value pair data stored in the memory according to the updated first key-value pair data.
[0100] Optionally, the third update module includes: A first updating submodule, configured to obtain location information of a first base station cell associated with the first user number from the updated first key-value pair data; The second updating submodule is used to update the value corresponding to the second key-value pair data associated with the location information of the first base station cell in the memory using other information in the updated first key-value pair data except the location information of the first base station cell.
[0101] Optionally, the device further comprises: A request receiving module, used for receiving a query request through a pre-configured application programming interface API; A first query module is used to obtain, when the query request carries a second user number, first key-value pair data associated with the second user number from a memory, generate and return a first query result according to the obtained first key-value pair data, wherein the first query result is used to send a message to the terminal associated with the second user number, and the first query result includes: location information of a base station cell associated with the second user number and domain name information of an S-CSCF network element; The second query module is used to obtain second key-value pair data associated with the location information of the second base station cell from the memory when the query request carries the location information of the second base station cell, and generate and return a second query result based on the obtained second key-value pair data, wherein the second query result is used to send a message to each terminal associated with the base station cell, and the second query result includes: multiple user numbers in the base station cell associated with the location information of the second base station cell, and domain name information of the S-CSCF network element associated with each of the multiple user numbers.
[0102] Optionally, the device further comprises: An information conversion module, configured to, after obtaining each number location information at the current moment from the core network, determine, for each number location information, a target hash value corresponding to the user number in the number location information based on a preset hash function, and replace the user number with the target hash value in the number location information; The data storage module 1204 includes: The storage submodule is used to store each of the first key-value pair data and each of the second key-value pair data in the memory of different storage nodes in the distributed cache cluster according to the target hash value corresponding to each user number, wherein the different storage nodes are used to store data associated with different hash values.
[0103] Optionally, the information acquisition module 1201 includes: A first acquisition submodule is used to collect registration signaling from an S-CSCF network element in the core network in real time through a first real-time data channel; The second acquisition submodule is used to acquire each target information from each currently collected registration signaling, wherein the target information includes: a user number, location information of a base station cell associated with the user number, and an IP address of an S-CSCF network element associated with the user number; A third acquisition submodule, configured to generate each domain name query request according to each target information, and send each domain name query request to the core network through a second real-time data channel; The fourth acquisition submodule is used to determine the respective target information and the domain name information of the respective S-CSCF network elements returned by the core network in response to the respective domain name query requests as the respective number location information at the current moment.
[0104] Optionally, the device further comprises: The persistent storage module is used to persistently store the data stored in the memory according to a set period.
[0105] It should be noted that the device embodiment is similar to the method embodiment, so the description is relatively simple, and the relevant parts can be referred to the method embodiment.
[0106] The present application also provides an electronic device, referring to Fig.13 , Fig.13 Schematic diagram of an electronic device proposed in an embodiment of the present application. Fig.13 As shown, the electronic device 100 includes: a memory 110 and a processor 120. The memory 110 and the processor 120 are connected via a bus communication. A computer program is stored in the memory 110. The computer program can be run on the processor 120 to implement the steps in the number location information storage method disclosed in the embodiment of the present application.
[0107] The embodiment of the present application also provides a computer-readable storage medium on which a computer program / instruction is stored. When the computer program / instruction is executed by a processor, the number location information storage method disclosed in the embodiment of the present application is implemented.
[0108] The embodiment of the present application also provides a computer program product, including a computer program / instruction, which, when executed by a processor, implements the number location information storage method disclosed in the embodiment of the present application.
[0109] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.
[0110] Those skilled in the art will appreciate that the embodiments of the present application can be provided as methods, devices or computer program products. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0111] The embodiments of the present application are described with reference to the flowcharts and / or block diagrams of the methods, systems, devices, storage media, and program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing terminal device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0112] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing terminal device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0113] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal device so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable terminal device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0114] Although the preferred embodiments of the present application have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the embodiments of the present application.
[0115] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or terminal device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or terminal device. In the absence of further restrictions, the elements defined by the sentence "including one..." do not exclude the existence of other identical elements in the process, method, article or terminal device including the elements.
[0116] The above is a detailed introduction to a number location information storage method, system, device and medium provided by the present application. Specific examples are used in this article to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea; at the same time, for general technical personnel in this field, according to the idea of the present application, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.
Claims
1. A method for storing number location information, characterized in that: The method comprises: Obtaining the current location information of each number from the core network, the number location information including: the user number, the location information of the base station cell associated with the user number, and the Internet interconnection protocol IP address and domain name information of the service session control function S-CSCF network element associated with the user number; Using the user number contained in each of the number location information as a key and other information contained in each of the number location information as a value, generating first key-value pair data associated with each of the user numbers; For each base station cell location information included in each number location information, the base station cell location information is used as a key, and other information included in different number location information associated with the base station cell location information is used as a value to generate second key-value pair data associated with the base station cell location information; Based on the distributed cache technology, each of the first key-value pair data and each of the second key-value pair data are stored in the memory.
2. The method according to claim 1, characterized in that The number location information also includes registration time; the method also includes: For a first user number associated with the first key-value pair data stored in the memory, obtain the latest number location information associated with the first user number from the core network, and detect whether there is a location change of the first user number; In a case where there is no location change of the first user number, using the registration time in the latest number location information, updating the registration time in the first key-value pair data associated with the first user number in the memory; In the case where the first user number has a location change, using other information except the first user number in the latest number location information to update the value corresponding to the first key-value pair data associated with the first user number in the memory; The second key-value pair data stored in the memory is updated according to the updated first key-value pair data.
3. The method according to claim 2, characterized in that The updating of the second key-value pair data stored in the memory according to the updated first key-value pair data includes: Acquire location information of a first base station cell associated with the first user number from the updated first key-value pair data; Using other information in the updated first key-value pair data except the location information of the first base station cell, the value corresponding to the second key-value pair data associated with the location information of the first base station cell is updated in the memory.
4. The method according to claim 1, characterized in that: The method further comprises: Receive query requests through a pre-configured application programming interface API; In the case where the query request carries the second user number, obtaining first key-value pair data associated with the second user number from the memory, generating and returning a first query result according to the obtained first key-value pair data, wherein the first query result is used to send a message to the terminal associated with the second user number, and the first query result includes: location information of the base station cell associated with the second user number and domain name information of the S-CSCF network element; In the case where the query request carries the location information of the second base station cell, second key-value pair data associated with the location information of the second base station cell is obtained from the memory, and a second query result is generated and returned based on the obtained second key-value pair data, wherein the second query result is used to send a message to each terminal associated with the base station cell, and the second query result includes: multiple user numbers in the base station cell associated with the location information of the second base station cell, and domain name information of the S-CSCF network element associated with each of the multiple user numbers.
5. The method according to claim 1, characterized in that After obtaining the location information of each number at the current moment from the core network, the method further includes: For each of the number location information, determine a target hash value corresponding to the user number in the number location information based on a preset hash function, and replace the user number with the target hash value in the number location information; The storing each of the first key-value pair data and each of the second key-value pair data in the memory based on the distributed cache technology includes: According to the target hash value corresponding to each user number, each of the first key-value pair data and each of the second key-value pair data are respectively stored in the memory of different storage nodes in the distributed cache cluster, wherein the different storage nodes are respectively used to store data associated with different hash values.
6. The method according to claim 1, characterized in that The obtaining the location information of each number at the current moment from the core network includes: Collecting registration signaling from the S-CSCF network element in the core network in real time through the first real-time data channel; Acquire each target information from each currently collected registration signaling, the target information including: a user number, location information of a base station cell associated with the user number, and an IP address of an S-CSCF network element associated with the user number; Generate each domain name query request according to each target information, and send each domain name query request to the core network through a second real-time data channel; The target information and the domain name information of the S-CSCF network elements returned by the core network in response to the domain name query requests are determined as the number location information at the current moment.
7. The method according to any one of claims 1 to 6, characterized in that: The method further comprises: The data stored in the memory is persistently stored according to the set period.
8. A number location information storage system, characterized in that: The system includes a signaling monitoring system and a signaling sharing platform, wherein: The signaling monitoring system is used to obtain the location information of each number at the current moment from the core network, and the number location information includes: the user number, the location information of the base station cell associated with the user number, and the Internet interconnection protocol IP address and domain name information of the service session control function S-CSCF network element associated with the user number; The signaling sharing platform is used to use the user number contained in each of the number location information as a key and other information contained in each of the number location information as a value to generate first key-value pair data associated with each of the user numbers; The signaling sharing platform is further used to generate second key-value pair data associated with the location information of the base station cell, using the location information of the base station cell as a key and other information included in different number location information associated with the location information of the base station cell as a value, for the location information of each base station cell included in the respective number location information; The signaling sharing platform is also used to store each of the first key-value pair data and each of the second key-value pair data in the memory based on the distributed cache technology.
9. An electronic device comprising a memory, a processor and a computer program stored in the memory, characterized in that: The processor executes the computer program to implement the number location information storage method according to any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program / instruction stored thereon, characterized in that: When the computer program / instruction is executed by a processor, the number location information storage method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Multi-dimensional data association analysis system and method
CN114491061A
Signaling stream data processing method, location information service method and electronic equipment
CN114666753A
Data storage method, device and equipment
CN116775701A
Hierarchical caching method and device, data query method and device, equipment, medium and program product
CN117149832A
A method and system for securing computer software using a distributed HASH table and a blockchain
WO2017145009A1