CN105975614B - Cluster configuration device, and method and device for updating data - Google Patents

Cluster configuration device, and method and device for updating data Download PDF

Info

Publication number
CN105975614B
CN105975614B CN201610332585.6A CN201610332585A CN105975614B CN 105975614 B CN105975614 B CN 105975614B CN 201610332585 A CN201610332585 A CN 201610332585A CN 105975614 B CN105975614 B CN 105975614B
Authority
CN
China
Prior art keywords
cluster
intelligent service
sdu
service
intelligent
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201610332585.6A
Other languages
Chinese (zh)
Other versions
CN105975614A (en
Inventor
王美玲
李明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201610332585.6A priority Critical patent/CN105975614B/en
Publication of CN105975614A publication Critical patent/CN105975614A/en
Application granted granted Critical
Publication of CN105975614B publication Critical patent/CN105975614B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/28Databases characterised by their database models, e.g. relational or object models
    • G06F16/284Relational databases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/21Design, administration or maintenance of databases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2458Special types of queries, e.g. statistical queries, fuzzy queries or distributed queries
    • G06F16/2471Distributed queries
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/0813Configuration setting characterised by the conditions triggering a change of settings
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/0823Configuration setting characterised by the purposes of a change of settings, e.g. optimising configuration for enhancing reliability
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/0823Configuration setting characterised by the purposes of a change of settings, e.g. optimising configuration for enhancing reliability
    • H04L41/0836Configuration setting characterised by the purposes of a change of settings, e.g. optimising configuration for enhancing reliability to enhance reliability, e.g. reduce downtime
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/2866Architectures; Arrangements
    • H04L67/30Profiles

Abstract

The embodiment of the invention discloses a cluster configuration device, a method and a device for updating data, relating to the technical field of communication and used for reducing the cost of cluster configuration, wherein the cluster configuration device is applied to an intelligent network functional entity, the intelligent network functional entity comprises N Service Data Units (SDU), N is a positive integer, and the cluster configuration device comprises a configuration unit; the configuration unit is configured to configure a cluster corresponding to each intelligent service in a plurality of intelligent services, where a cluster corresponding to an intelligent service includes a cluster manner of the cluster corresponding to the intelligent service and SDUs in the cluster corresponding to the intelligent service, where one cluster includes at least one SDU, the SDUs are in one-to-one correspondence with the database, and each SDU in the N SDUs belongs to one or more clusters. The apparatus may be for configuring a cluster.

Description

Cluster configuration device, and method and device for updating data
Technical Field
The present invention relates to the field of communications technologies, and in particular, to a cluster configuration apparatus, a method for updating data, and an apparatus for updating data.
Background
At present, the Next Generation Intelligent Network (NGIN) service can realize 2 types of cluster scenes by dividing the Oracle database, one is a high-availability cluster in which data in a plurality of databases are stored redundantly; the other is a load balancing cluster in which data in a plurality of databases are complementarily stored.
When the cluster scene of 2 modes is realized, the cluster of the database can be realized by directly using Oraclecusterware HA and Oracle LoadBalance provided by an Oracle company. However, Oracllecutesterware HA and Oracle LoadBalance must be purchased, increasing costs. Moreover, when using oraclenterware ha or Oracle LoadBalance, the same Oracle database can only be located in one cluster, which may result in insufficient resource utilization of the Oracle database.
Disclosure of Invention
The embodiment of the invention provides a cluster configuration device, a data updating method and a data updating device, which are used for reducing the cost of cluster configuration.
In order to achieve the above purpose, the embodiment of the invention adopts the following technical scheme:
in a first aspect, an apparatus for cluster configuration is provided, where the apparatus is applied to an intelligent network functional entity, where the intelligent network functional entity includes N SDUs, where N is a positive integer, and the apparatus includes: a configuration unit; the configuration unit is configured to configure a cluster corresponding to each intelligent service in a plurality of intelligent services, where a cluster corresponding to an intelligent service includes a cluster manner of the cluster corresponding to the intelligent service and SDUs in the cluster corresponding to the intelligent service, where one cluster includes at least one SDU, the SDUs are in one-to-one correspondence with the database, and each SDU in the N SDUs belongs to one or more clusters.
The SEE is used for operating the intelligent service and simultaneously responsible for analyzing the call message, and the SDU is a component of the NGIN and is used for processing requests related to data storage, data query, data modification and data deletion of the intelligent service and storing data, query data, modification data and deletion data in a database corresponding to the SDU. An Oracle database is a relational database that provides data storage and data management services to customers.
The device provided by the embodiment of the invention realizes the cluster configuration of the database by carrying out the cluster configuration on the SDU according to the corresponding relation between the SDU and the database, and the way does not need to use Oracle cluster hardware HA and Oracle LoadBance, thereby saving Oracle software and reducing the cost of the cluster configuration. Meanwhile, the SDU in the embodiment of the invention can belong to a plurality of clusters, namely the Oracle database corresponding to the SDU can belong to a plurality of clusters.
With reference to the first aspect, in a first possible implementation manner, the configuration unit is specifically configured to: determining a reliability requirement for each of the plurality of intelligent services, the reliability requirements including a high reliability requirement and no high reliability requirement; when the reliability requirement of an intelligent service is high, determining that the cluster mode of a cluster corresponding to the intelligent service is high availability, determining that the cluster corresponding to the intelligent service comprises P SDUs, wherein P is a value obtained by upwards rounding the ratio of the number of pilot calls per second of the intelligent service to the highest number of calls capable of being carried per second of a database, and is a positive integer; when the reliability requirement of an intelligent service is no high reliability requirement, determining that the cluster mode of a cluster corresponding to the intelligent service is load balance, and determining Q SDUs, wherein Q is a value obtained by rounding up the ratio of the number of pilot calls per second of the intelligent service to the highest number of calls which can be carried per second of a database; according to the method, the number of distributed users of each SDU in Q SDUs is determined according to the number of users of the intelligent service, the total number of the distributed users of the Q SDUs is the number of users of the intelligent service, whether the number of call attempts per second of a database corresponding to each SDU in Q SDU meets a preset condition is judged, if yes, the Q SDU is determined to be the SDU forming a cluster corresponding to the intelligent service, if not, Q is set to be Q +1, the number of users is continuously distributed to each SDU in Q SDU according to the number of users of the intelligent service until the number of call attempts per second of the database corresponding to each SDU in Q SDU meets the preset condition, the number of call attempts per second of one database is calculated according to the number of call attempts distributed to the SDU corresponding to the database, and the number of call attempts per second of one database meets the preset condition is smaller than the maximum number of calls which the database can bear per second, q is a positive integer.
With reference to the first aspect, in a second possible implementation manner, the apparatus further includes: an obtaining unit, configured to obtain configuration information, where the configuration information is configuration information of a cluster corresponding to each of the plurality of intelligent services; the configuration unit is specifically configured to configure a cluster corresponding to each intelligent service in the plurality of intelligent services according to the configuration information.
With reference to the first aspect, the first possible implementation manner of the first aspect, or the second possible implementation manner, in a third possible implementation manner, the configuration unit is further configured to: when a cluster corresponding to an intelligent service is a load balancing cluster, configuring a preset number segment for a preset SDU in the load balancing cluster, wherein a database corresponding to the preset SDU is used for storing the data of the intelligent service of a user using the preset number segment.
In a second aspect, a method for updating data is provided, where the method is applied to an intelligent network function entity, where the intelligent network function entity includes N SDUs and M ses, the N SDUs form multiple clusters, a cluster includes at least one SDU, the SDUs correspond to a database one-to-one, each SDU in the N SDUs belongs to one or more clusters, and N, M is a positive integer, and the method includes: the SEE receives a service request of an intelligent service sent by a user; the SEE determines a cluster corresponding to the intelligent service according to the service identifier of the intelligent service carried in the service request, wherein the cluster corresponding to the intelligent service comprises a cluster mode of the cluster corresponding to the intelligent service and SDU (service data Unit) in the cluster corresponding to the intelligent service; and the SEE updates data related to the intelligent service in a database corresponding to the SDU in the cluster corresponding to the intelligent service according to the cluster mode of the cluster corresponding to the intelligent service.
The SEE is used for operating the intelligent service and simultaneously responsible for analyzing the call message, and the SDU is a component of the NGIN and is used for processing requests related to data storage, data query, data modification and data deletion of the intelligent service and storing data, query data, modification data and deletion data in a database corresponding to the SDU. An Oracle database is a relational database that provides data storage and data management services to customers.
In the method provided by the embodiment of the invention, the cluster configuration is carried out on the SDU due to the corresponding relation between the SDU and the database, so that the cluster configuration of the database is realized, and Oracle cluster hardware HA and Oracle LoadBance are not needed, so that Oracle software can be saved. Meanwhile, the SDU in the embodiment of the invention can belong to a plurality of clusters, namely the Oracle database corresponding to the SDU can belong to a plurality of clusters.
With reference to the second aspect, in a first possible implementation manner, the updating, by the SEE, data related to the intelligent service in a database corresponding to an SDU in a cluster corresponding to the intelligent service according to a clustering manner of the cluster corresponding to the intelligent service includes: when the cluster corresponding to the intelligent service is a load balancing cluster, the SEE updates data related to the intelligent service in a database corresponding to a first target SDU in the cluster corresponding to the intelligent service, wherein the database corresponding to the first target SDU is a database used for storing the data of the intelligent service of the user in the cluster corresponding to the intelligent service; and when the cluster corresponding to the intelligent service is a high-availability cluster, the SEE updates data related to the intelligent service in a database corresponding to all SDUs in the cluster corresponding to the intelligent service.
With reference to the first possible implementation manner of the second aspect, in a second possible implementation manner, when the cluster is a load balancing cluster, a preset SDU in the cluster corresponds to a preset number segment, and the database corresponding to the preset SDU is used for storing data of the intelligent service for a user using the preset number segment.
With reference to the second possible implementation manner of the second aspect, in a third possible implementation manner, when a cluster corresponding to the intelligent service is a load balancing cluster, the update, by the SEE, of data related to the intelligent service in a database corresponding to a first target SDU in the cluster corresponding to the intelligent service includes: when the cluster corresponding to the intelligent service is a load balancing cluster, the SEE determines a preset number segment to which the number corresponding to the user belongs; the SEE determines a preset SDU corresponding to a preset number segment to which a number corresponding to the user belongs as a first target SDU; the SEE sends a write request to the first target SDU; and the first target SDU receives the writing request and updates data related to the intelligent service in a database corresponding to the first target SDU.
With reference to the first possible implementation manner of the second aspect, in a fourth possible implementation manner, when a cluster corresponding to the intelligent service is a high availability cluster, the updating, by the SEE, data related to the intelligent service in a database corresponding to all SDUs in the cluster corresponding to the intelligent service includes: the SEE sends a multi-write request to a second target SDU in a cluster corresponding to the intelligent service, wherein the second target SDU is any one SDU in the cluster corresponding to the intelligent service; and the second target SDU receives a multi-write request sent by the SEE, and updates data related to the intelligent service to a database corresponding to all SDUs in a cluster corresponding to the intelligent service according to the multi-write request.
With reference to the second aspect and any one of the first possible implementation manner to the third possible implementation manner of the second aspect, in a fourth possible implementation manner, the method further includes: when the cluster corresponding to the intelligent service is a load balancing cluster, the SEE inquires service data and user data of the intelligent service of the user in a database corresponding to the first target SDU, and judges whether the user initiating the intelligent service is legal or not according to the service data and the user data; when the cluster corresponding to the intelligent service is a high-availability cluster, the SEE queries the service data and the user data of the intelligent service of the user in a database corresponding to any SDU in the cluster corresponding to the intelligent service, and judges whether the user initiating the intelligent service is legal or not according to the service data and the user data.
In a third aspect, an apparatus for updating data is provided, where the apparatus includes N SDUs and M SEE, where the N SDUs form a plurality of clusters, each cluster includes at least one SDU, the SDUs are in one-to-one correspondence with a database, each SDU in the N SDUs belongs to one or more clusters, and N, M is a positive integer; the SEE is used for receiving a service request of an intelligent service sent by a user; the SEE is further configured to determine a cluster corresponding to the intelligent service according to the service identifier of the intelligent service carried in the service request, where the cluster corresponding to the intelligent service includes a cluster mode of the cluster corresponding to the intelligent service and an SDU in the cluster corresponding to the intelligent service; and the SEE is further configured to update data related to the intelligent service in a database corresponding to the SDU in the cluster corresponding to the intelligent service according to a cluster mode of the cluster corresponding to the intelligent service.
For the description of SDU, SEE se and Oracle database, SEE the above method section, the advantageous effects of the apparatus can be seen in the method section, as the apparatus is used to perform the above method.
With reference to the third aspect, in a first possible implementation manner, the SEE is specifically configured to: when the cluster corresponding to the intelligent service is a load balancing cluster, updating data related to the intelligent service in a database corresponding to a first target SDU in the cluster corresponding to the intelligent service, wherein the database corresponding to the first target SDU is a database used for storing the data of the intelligent service of the user in the cluster corresponding to the intelligent service; and when the cluster corresponding to the intelligent service is a high-availability cluster, updating data related to the intelligent service in a database corresponding to all SDUs in the cluster corresponding to the intelligent service.
With reference to the first possible implementation manner of the third aspect, in a second possible implementation manner, when the cluster is a load balancing cluster, a preset SDU in the cluster corresponds to a preset number segment, and a database corresponding to the preset SDU is used to store data of the intelligent service of a user using the preset number segment.
With reference to the second possible implementation manner of the third aspect, in a third possible implementation manner, the SEE is specifically configured to: when the cluster corresponding to the intelligent service is a load balancing cluster, determining a preset number segment to which the number corresponding to the user belongs; determining a preset SDU corresponding to a preset number segment to which the number corresponding to the user belongs as a first target SDU; sending a write request to the first target SDU; and the first target SDU is used for receiving the writing request and updating data related to the intelligent service in a database corresponding to the first target SDU.
With reference to the first possible implementation manner of the third aspect, in a fourth possible implementation manner, the SEE is specifically configured to: when the cluster corresponding to the intelligent service is a high-availability cluster, sending a multi-write request to a second target SDU in the cluster corresponding to the intelligent service, wherein the second target SDU is any one SDU in the cluster corresponding to the intelligent service; and the second target SDU is used for receiving a multi-write request sent by the SEE and updating data related to the intelligent service to a database corresponding to all SDUs in a cluster corresponding to the intelligent service according to the multi-write request.
With reference to the third aspect and any one of the first possible implementation manner to the third possible implementation manner of the third aspect, in a fourth possible implementation manner, the SEE is further configured to: when the cluster corresponding to the intelligent service is a load balancing cluster, inquiring service data and user data of the intelligent service of the user in a database corresponding to the first target SDU, and judging whether the user initiating the intelligent service is legal or not according to the service data and the user data; and when the cluster corresponding to the intelligent service is a high-availability cluster, inquiring the service data and the user data of the intelligent service of the user in a database corresponding to any SDU in the cluster corresponding to the intelligent service, and judging whether the user initiating the intelligent service is legal or not according to the service data and the user data.
In a fourth aspect, an apparatus for updating data is provided, which includes a memory and a processor, where the memory is used to store a code, so that the processor performs an action corresponding to the code, the processor runs N SDUs and M SEE, where the N SDUs form a plurality of clusters, one cluster includes at least one SDU, the SDUs correspond to a database one-to-one, and each SDU in the N SDUs belongs to one or more clusters, and N, M is a positive integer; the apparatus is configured to perform any one of the methods provided by the second aspect.
For the description of SDU, SEE se and Oracle database, SEE the above method section, the advantageous effects of the apparatus can be seen in the method section, as the apparatus is used to perform the above method.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a schematic diagram of a service request processing flow in the prior art;
fig. 2 is a schematic diagram of an architecture of an intelligent network functional entity according to an embodiment of the present invention;
fig. 3 is a schematic composition diagram of a cluster configuration apparatus according to an embodiment of the present invention;
fig. 4 is a schematic diagram of SDUs in two clusters according to an embodiment of the present invention;
FIG. 5 is a flowchart of a method for updating data according to an embodiment of the present invention;
fig. 6 is a schematic diagram illustrating updating data in a database corresponding to an SDU according to an embodiment of the present invention;
fig. 7 is a schematic diagram of another embodiment of updating data in a database corresponding to an SDU according to the present invention;
FIG. 8 is a flowchart of another method for updating data according to an embodiment of the present invention;
FIG. 9 is a block diagram of an apparatus for updating data according to an embodiment of the present invention;
fig. 10 is a schematic diagram illustrating a composition of another apparatus for updating data according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The mobile intelligent network is a network which introduces an intelligent network functional entity in a mobile network and realizes the control of mobile intelligent calls. As shown in fig. 1, if the user a opens the intelligent service, in a scenario where the user a calls the user B, when receiving a service request sent by the user a, the base station sends the service request to the intelligent network functional entity through the switch, the intelligent network functional entity determines an intelligent service subscribed by the user according to the service request and processes the intelligent service, and sends a processed message to the switch, and the switch establishes a call connection with the user B (the call request may reach the switch before the processing functional entity after passing through a plurality of switches, the switch shown in fig. 1 is the switch before the processing functional entity, the remaining switches are not shown, and the number in the figure represents the processing sequence of the call request).
As shown in fig. 2, the intelligent network functional entity includes M (M is a positive integer) Service Execution Environments (SEE) and N (N is a positive integer) Service Data units (Service Data Unit, SDU for short), where the SEE is used to execute the intelligent Service and is responsible for parsing the call message, and the SDU is used to process requests for Data storage, Data query, Data modification, and Data deletion related to the intelligent Service, and store Data, query Data, modify Data, and delete Data in a database corresponding to the SDU. The SDU is a component of the NGIN, and corresponds to the databases one by one, and the SDU and the corresponding database may or may not be installed together. The example of an SDU and its corresponding database being installed together is described herein. Fig. 2 illustrates an example in which M is 3, N is 4, and the SDUs and their corresponding databases are installed on one physical board. The database in the embodiment of the invention can be an Oracle database.
The Oracle database is a relational database, and provides data storage and data management services for clients, and the database Language of the Oracle database is Structured Query Language (SQL). The SDU and the Oracle database can be both installed on the physical single board, the software of the Oracle database can be installed after the operating system is installed on the physical single board, the data can be stored after the software of the Oracle database is installed, an external program interacts with the Oracle database through an Oracle instance, accesses and operates the data in the Oracle database, the Oracle instance is an identifier used for being in contact with the operating system, namely the Oracle instance is used for interacting between the Oracle database and the operating system.
An embodiment of the present invention provides a cluster configuration device 30, which is applied to an intelligent network functional entity, where the intelligent network functional entity includes N SDUs, and as shown in fig. 3, the device 30 includes: a configuration unit 301;
the configuration unit 301 is configured to configure a cluster corresponding to each intelligent service in a plurality of intelligent services, where a cluster corresponding to an intelligent service includes a cluster manner of the cluster corresponding to the intelligent service and SDUs in the clusters corresponding to the intelligent service, where one cluster includes at least one SDU, the SDUs are in one-to-one correspondence with the database, and each SDU in the N SDUs belongs to one or more clusters.
Specifically, the apparatus 30 may be disposed in an SEE of an intelligent network function entity in a form of hardware or software, and specifically, the Configuration unit 301 may be a part of a Configuration Center (CC) in the SEE.
The cluster mode of the cluster may be high availability or load balancing, and the cluster may be a high availability cluster or load balancing cluster. In the embodiment of the present invention, one SDU may belong to multiple clusters, for example, as shown in fig. 4, in the embodiment of the present invention, cluster 1 and cluster 2 may contain the same SDU (i.e., SDU3 in the figure).
Optionally, the configuration unit 301 is specifically configured to: determining a reliability requirement for each of the plurality of intelligent services, the reliability requirements including a high reliability requirement and no high reliability requirement;
when the reliability requirement of an intelligent service is high, determining that the cluster mode of a cluster corresponding to the intelligent service is high availability, determining that the cluster corresponding to the intelligent service comprises P SDUs, wherein P is a value obtained by upwards rounding the ratio of the number of pilot calls per second of the intelligent service to the highest number of calls capable of being carried per second of a database, and is a positive integer;
when the reliability requirement of an intelligent service is no high reliability requirement, determining that the cluster mode of a cluster corresponding to the intelligent service is load balance, and determining Q SDUs, wherein Q is a value obtained by rounding up the ratio of the number of pilot calls per second of the intelligent service to the highest number of calls which can be carried per second of a database; according to the method, the number of distributed users of each SDU in Q SDUs is determined according to the number of users of the intelligent service, the total number of the distributed users of the Q SDUs is the number of users of the intelligent service, whether the number of call attempts per second of a database corresponding to each SDU in Q SDU meets a preset condition is judged, if yes, the Q SDU is determined to be the SDU forming a cluster corresponding to the intelligent service, if not, Q is set to be Q +1, the number of users is continuously distributed to each SDU in Q SDU according to the number of users of the intelligent service until the number of call attempts per second of the database corresponding to each SDU in Q SDU meets the preset condition, the number of call attempts per second of one database is calculated according to the number of call attempts distributed to the SDU corresponding to the database, and the number of call attempts per second of one database meets the preset condition is smaller than the maximum number of calls which the database can bear per second, q is a positive integer.
Specifically, the intelligent network functional entity may store the correspondence between different intelligent services and the reliability requirement, or may configure a preset condition for the configuration unit 301 to determine the reliability requirement of the intelligent service, for example, determine the reliability requirement of the intelligent service according to the service priority of the user group subscribing to different intelligent services, where the intelligent service corresponding to the user group having a service priority greater than a certain value has a high reliability requirement, and the intelligent service corresponding to the user group having a service priority lower than a certain value has no high reliability requirement.
When the number of SDUs in the cluster is determined, it is assumed that the Call attempt time per Second (Call attemptper Second, CAPS for short) of the intelligent service is Y, and the highest Call time that the database can carry per Second is X. The value of Y can be calculated according to the number of users (assumed to be 1000) supported by the smart service, specifically, Y is the number of users (1000) × traffic per user/average call duration, and the unit of traffic is ERL (erlang). The value of X may be calculated according to the number of times that the smart Service needs to read and write in the process of processing a call, and specifically, if the number of things Per call (Transactions Per Service Request, TPSR for short) of the database is m, the number of times of reading Per call is a, the number of times of writing is b, and the resource consumed by one write is n times of reading, X is m/(a + b n). The telephone traffic and the average call duration of each user can be obtained by statistics and calculation according to the historical service data of 1000 users.
When the clustering mode of the cluster corresponding to one intelligent service is high availability, the number of SDUs in the cluster corresponding to the intelligent service is greater than the value rounded up for Y/X, for example, when Y/X is 3.1, the number of SDUs in the cluster corresponding to the intelligent service is greater than 4, and when Y/X is 4.5, the number of SDUs in the cluster corresponding to the intelligent service is greater than 5.
When the cluster mode of the cluster corresponding to an intelligent service is load balancing, the calculation method of the call test times per second of the database corresponding to the SDU is as follows: the number of users (the number of users assigned to the SDU) per user traffic/average call duration. The telephone traffic and the average call duration of each user used in the calculation of each database can be obtained by statistics and calculation according to the historical service data of the user distributed for the SDU corresponding to the database.
One intelligent service corresponds to one cluster, but a plurality of intelligent services can be operated in one cluster. When one high-availability cluster corresponds to a plurality of intelligent services, the number of SDUs in the cluster is larger than a value obtained by rounding up the ratio of the sum of the number of call attempts per second of all the intelligent services in the plurality of intelligent services to the highest number of call times which can be borne by a database per second; when one load balancing cluster corresponds to a plurality of intelligent services, the number of SDUs in the cluster is greater than or equal to the sum of the number of SDUs in the cluster calculated according to each intelligent service in the plurality of intelligent services.
Optionally, as shown in fig. 3, the apparatus 30 further includes: an obtaining unit 302, configured to obtain configuration information, where the configuration information is configuration information of a cluster corresponding to each of the plurality of intelligent services; the configuration unit 301 is specifically configured to configure a cluster corresponding to each intelligent service in the plurality of intelligent services according to the configuration information.
The configuration information can be input by a user and acquired by the acquisition unit.
Specifically, after configuring the cluster corresponding to each intelligent service in the intelligent services, the configuration unit 301 may establish a corresponding relationship between the service identifier of each intelligent service and the cluster corresponding to the intelligent service, so as to process the data of the intelligent service according to the corresponding relationship.
For example, based on the intelligent network function entity shown in fig. 2, if the intelligent network function entity only includes SDU1, SDU2, SDU3 and SDU4, and the intelligent service and the service identifier are in one-to-one correspondence, the intelligent service 1 corresponds to the cluster 1, and the service identifier of the intelligent service 1 is a1The intelligent service 2 corresponds to the cluster 2, and the service identifier of the intelligent service 2 is A2The intelligent service 3 corresponds to the cluster 3, and the service identifier of the intelligent service 3 is A3 Cluster 1 is a high availability cluster and includes SDU1 and SDU2, cluster 2 is a load balancing cluster and includes SDU3 and SDU4, and cluster 3 is a high availability cluster and includes SDU2 and SDU 3. See table 1 for details.
TABLE 1
Intelligent services Service identification Cluster Cluster type SDU included by cluster
Intelligent service 1 A1 Cluster 1 High availability cluster SDU1 and SDU2
Intelligent service 2 A2 Cluster 2 Load balancing cluster SDU3 and SDU4
Intelligent service 3 A3 Cluster 3 High availability cluster SDU2 and SDU3
When the cluster is a high-availability cluster, data in the cluster is stored redundantly, reliability is high, and when the cluster is a load balancing cluster, the data in the cluster is stored complementarily, resource utilization rate is high, and performance is high. For example, based on the example described in table 1, if the intelligent service 1 uses a high-availability cluster, the service data of the intelligent service 1 in SDU1 and SDU2 is stored redundantly, and if the intelligent service 2 uses a load balancing cluster, the service data of the intelligent service 2 in SDU3 and SDU4 are stored complementarily.
Optionally, the configuration unit is further configured to: when a cluster corresponding to an intelligent service is a load balancing cluster, configuring a preset number segment for a preset SDU in the load balancing cluster, wherein a database corresponding to the preset SDU is used for storing the data of the intelligent service of a user using the preset number segment.
It should be noted that the number segment may be a number segment of a telephone number used by a user, or may also be a number segment of a preset ID number, where the preset ID number may be a number set for different enterprises, or may also be a number of different group devices, and this is not specifically limited in this embodiment of the present invention.
Illustratively, based on the example described in table 1, if the number segments used by the user group of smart service 2 are 130, 134, 139 and 180, the data of the users using the number segments 130 and 134 is stored in SDU3, and the data of the users using the number segments 139 and 180 is stored in SDU 4. See table 2 for details.
TABLE 2
Figure BDA0000993591420000121
The device provided by the embodiment of the invention realizes the cluster configuration of the database by carrying out the cluster configuration on the SDU according to the corresponding relation between the SDU and the database, and the way does not need to use Oracle cluster hardware HA and Oracle LoadBance, thereby saving Oracle software and reducing the cost of the cluster configuration. Meanwhile, the SDU in the embodiment of the invention can belong to a plurality of clusters, namely the Oracle database corresponding to the SDU can belong to a plurality of clusters. In addition, in the embodiment of the present invention, if the SDU and its corresponding Oracle database are installed on one physical board, since the database may belong to a plurality of clusters, the number of boards may also be saved in the embodiment of the present invention, compared with the prior art.
Based on the intelligent network function entity shown in fig. 2, an embodiment of the present invention provides a method for updating data, which, as shown in fig. 5, includes:
501. the SEE receives a service request of the intelligent service sent by a user.
The method provided by the embodiment of the invention can be applied to the mobile intelligent network, and particularly can be applied to an intelligent network functional entity. The intelligent network function entity comprises N SDUs and M SEEs, wherein the N SDUs form a plurality of clusters, one cluster comprises at least one SDU, the SDUs correspond to the database one by one, each SDU in the N SDUs belongs to one or more clusters, N, M is a positive integer, and the intelligent network function entity can be seen in figure 2.
The service request of the intelligent service sent by the user includes a number corresponding to the user, a service identifier of the intelligent service, position information of the user, a number dialed by the user and other information.
The SEE may be any SEE in the intelligent network functional entity, and since the intelligent network functional entity includes a plurality of SEEs, the switch may allocate the received service requests of the plurality of intelligent services and send the service requests to the corresponding SEE before the SEE receives the service request of the intelligent service sent by the user.
502. And the SEE determines a cluster corresponding to the intelligent service according to the service identifier of the intelligent service carried in the service request, wherein the cluster corresponding to the intelligent service comprises a cluster mode of the cluster corresponding to the intelligent service and SDU (service data Unit) in the cluster corresponding to the intelligent service.
Specifically, the SEE may query the cluster corresponding to the intelligent service when receiving the service request of the intelligent service according to the stored correspondence table (e.g., table 1 above) between the service identifier and the cluster.
The intelligent services correspond to the service identifiers one to one, one intelligent service corresponds to one cluster, but a plurality of intelligent services can be operated in one cluster, the cluster mode of the cluster is high availability or load balancing, and the cluster can be a high availability cluster or load balancing cluster.
When the cluster is a high-availability cluster, data in the cluster is stored redundantly, reliability is high, and when the cluster is a load balancing cluster, the data in the cluster is stored complementarily, resource utilization rate is high, and performance is high. For example, based on the example described in table 1, if the intelligent service 1 uses a high-availability cluster, the service data of the intelligent service 1 in SDU1 and SDU2 is stored redundantly, and if the intelligent service 2 uses a load balancing cluster, the service data of the intelligent service 2 in SDU3 and SDU4 are stored complementarily.
Specifically, an example of the correspondence between the intelligent service and the cluster can be seen in table 1.
503. And the SEE updates data related to the intelligent service in a database corresponding to the SDU in the cluster corresponding to the intelligent service according to the cluster mode of the cluster corresponding to the intelligent service.
Wherein updating the data associated with the intelligent service comprises adding, deleting or modifying the data associated with the intelligent service.
Optionally, when the cluster manners of the clusters are different, the specific implementation manners of step 503 are also different, where the first manner refers to the specific implementation of step 503 when the cluster corresponding to the intelligent service is a load balancing cluster, and the second manner refers to the specific implementation of step 503 when the cluster corresponding to the intelligent service is a high availability cluster, where the first manner and the second manner respectively include:
in a first mode, the SEE updates data related to the intelligent service in a database corresponding to a first target SDU in a cluster corresponding to the intelligent service, where the database corresponding to the first target SDU is a database used for storing data of the intelligent service of the user in the cluster corresponding to the intelligent service.
And secondly, updating data related to the intelligent service in a database corresponding to all SDUs in the cluster corresponding to the intelligent service by the SEE.
In the first mode, a first target SDU in a cluster corresponding to an intelligent service is used to store data of the intelligent service of the user.
Optionally, when the cluster is a load balancing cluster, the preset SDU in the cluster corresponds to the preset number segment, and the database corresponding to the preset SDU is used for storing the data of the intelligent service for the user using the preset number segment.
See table 2 for an example of this alternative method. It should be noted that the number segment may be a number segment of a telephone number used by a user, or may also be a number segment of a preset ID number, where the preset ID number may be a number set for different enterprises, or may also be a number set for different user groups, and this is not specifically limited in the embodiment of the present invention.
When the type of the cluster is a load balancing cluster, the SEE accesses the SDU by using the access rule of the intelligent service and the number segment, for example, when the cluster corresponding to the intelligent service 2 is a load balancing cluster, the data of the intelligent service 2 in the SDU3 and SDU4 are stored in the number segment mode, and the data are not redundant (the backup of the service data of the intelligent service 2 is not described here).
Optionally, the first method includes, in specific implementation: when the cluster corresponding to the intelligent service is a load balancing cluster, the SEE determines a preset number segment to which the number corresponding to the user belongs; the SEE determines a preset SDU corresponding to a preset number segment to which a number corresponding to the user belongs as a first target SDU; the SEE sends a write request to the first target SDU; and the first target SDU receives the writing request and updates data related to the intelligent service in a database corresponding to the first target SDU.
Illustratively, based on the example described in table 2, as shown in fig. 6, when the SEE determines that the cluster corresponding to the smart service 2 is a load balancing cluster and the number used by the user is a number at the beginning of 134, the SEE determines that the number used by the user belongs to the preset 134 segment by querying table 2, the SEE determines SDU3 storing data of the smart service in the 134 segment as the first target SDU, and sends a write request to SDU3, and SDU3 receives the write request and updates the data in database 3 corresponding to SDU 3.
Specifically, after receiving a service request of an intelligent service sent by a user, an SEE may first determine a cluster corresponding to the intelligent service according to a service identifier included in the service request, and if the cluster is a load balancing cluster, the SEE may determine a first target SDU according to a number corresponding to the user included in the service request.
The second mode comprises the following specific implementation: the SEE sends a multi-write request to a second target SDU in a cluster corresponding to the intelligent service, wherein the second target SDU is any one SDU in the cluster corresponding to the intelligent service; and the second target SDU receives a multi-write request sent by the SEE, and updates data related to the intelligent service to a database corresponding to all SDUs in a cluster corresponding to the intelligent service according to the multi-write request.
Illustratively, based on the example described in table 1, as shown in fig. 7, when the SEE determines that the cluster corresponding to the intelligent service 1 is a high availability cluster, the SEE sends a multi-write request to a second target SDU (assumed as SDU1), and the second target SDU receives the multi-write request sent by the SEE and updates data related to the intelligent service into a database corresponding to all SDUs in the cluster corresponding to the intelligent service according to the multi-write request.
Optionally, the receiving, by the second target SDU, the multi-write request sent by the SEE, and writing the data related to the intelligent service into the database corresponding to all SDUs in the cluster corresponding to the intelligent service according to the multi-write request includes: and receiving the multi-write request sent by the SEE by a second target SDU, sending a pre-submission command to a database corresponding to all SDUs by the second target SDU, pre-executing the database corresponding to each SDU in all SDUs, returning pre-execution success information to the second target SDU after the pre-execution is successful, sending a submission command to the database corresponding to all SDUs by the second target SDU if the pre-execution success information sent by the database corresponding to all SDUs is received by the second target SDU, and updating data related to the intelligent service by the database corresponding to each SDU in all SDUs according to the submission command. The aim of pre-executing the database is to check whether the multi-write request is legal.
It should be noted that, when the cluster type of the cluster corresponding to the intelligent service is a high-availability cluster, the high consistency of the service data of the intelligent service in the cluster needs to be ensured, optionally, the SEE may adopt a timestamp mechanism and an effective identifier to ensure the operation effectiveness, adopt a virtual transaction to ensure the data consistency in the operation process, and adopt an automatic comparison mechanism to ensure the consistency of the operation result.
When a timestamp mechanism, namely a database writes data or modifies the data, recording the latest updated system time of the data; when the valid identifier mechanism, namely the database needs to delete data, the operation of deleting the data is not executed, but the valid identifier is used for recording that the data is invalid.
The virtual transaction mechanism is that all the submitted commands form a virtual transaction; and when all databases successfully write the data related to the intelligent service according to the submission command and return an identifier representing successful operation to the second target SDU, the virtual transaction is recorded successfully, otherwise, the virtual transaction fails to be executed. And when the virtual transaction fails to be executed, the second target SDU rolls back the data on the database corresponding to each SDU one by one.
The automatic comparison mechanism is as follows: in the idle period of the intelligent network functional entity, the SEE sends a comparison command to the SDU, the SDU acquires the update time of the data on each database, and once the update time of the data on a certain database is inconsistent with the update time of the data on other databases, the data with the earlier timestamp is considered to be outdated, the data on the latest timestamp on the data base is taken as a synchronization basis, and the data on other databases are updated; and when the time that the data is marked with the valid identification exceeds the preset time, clearing the data.
Optionally, the method further includes:
when the cluster corresponding to the intelligent service is a load balancing cluster, the SEE inquires service data and user data of the intelligent service of the user in a database corresponding to the first target SDU, and judges whether the user initiating the intelligent service is legal or not according to the service data and the user data;
when the cluster corresponding to the intelligent service is a high-availability cluster, the SEE queries the service data and the user data of the intelligent service of the user in a database corresponding to any SDU in the cluster corresponding to the intelligent service, and judges whether the user initiating the intelligent service is legal or not according to the service data and the user data.
When the SEE receives a service request of an intelligent service, the SEE queries a cluster corresponding to the intelligent service, when the cluster type of the cluster is determined to be a high-availability cluster, the SEE sends a query request for querying service data and user data of a user to any SDU in the cluster, and the SDU queries the user data and the service data of the user in a database in the SDU according to a number corresponding to the user carried in the query request and feeds back the user data and the service data to the SEE. When the cluster type of the cluster is determined to be a load balancing cluster, the SEE determines a number segment to which a number corresponding to a user belongs, sends a query request for querying service data and user data of the user to the SDU according to the SDU corresponding to the number segment to which the number corresponding to the user belongs, queries the user data and the service data of the user according to the number of the user carried in the query request, and feeds the query request back to the SEE. For example, when the intelligent service is intelligent service 2, the SEE determines that the cluster is cluster 2, the cluster type corresponding to the cluster is a load balancing cluster, the cluster 2 includes SDU3 and SDU4, where the number segments corresponding to SDU3 are 130 and 134, and the number segments corresponding to SDU4 are 139 and 180, and if the SEE determines that the number segment to which the number corresponding to the user belongs is 134, the SEE sends a query request to SDU 3.
In the embodiment of the present invention, when a certain intelligent service needs to be extended (or adjusted), an SDU may be added (or adjusted) in the correspondence table between the intelligent service and the cluster. For example, if the intelligent service 2 needs capacity expansion, the configuration unit 301 may add SDU5 and SDU6 in the cluster 2, and then configure the added number segment. Specifically, the correspondence between the number segment and the added SDU can be seen in table 3.
TABLE 3
Figure BDA0000993591420000181
In the embodiment of the present invention, the configuration unit 301 may be used to simply and conveniently expand or adjust the cluster.
In the method provided by the embodiment of the invention, the cluster configuration is carried out on the SDU due to the corresponding relation between the SDU and the database, so that the cluster configuration of the database is realized, and Oracle cluster hardware HA and Oracle LoadBance are not needed, so that Oracle software can be saved. Meanwhile, the SDU in the embodiment of the invention can belong to a plurality of clusters, namely the Oracle database corresponding to the SDU can belong to a plurality of clusters.
The embodiment of the invention also provides a method for updating and inquiring data, and the method is exemplarily explained by taking a call scene as an example.
In this scenario, a user a calls a user B, when the user a has just initiated a call, a call request sent by the user a reaches an SEE running an intelligent service signed by the user a after passing through a base station and an exchange, and the SEE needs to query permission data of the user a in a database (for example, whether to allow the user B to be dialed, whether a call duration of the user B to be dialed is free in a package) so as to execute subsequent service logic according to the permission of the user a, where it is assumed that the user a signs an intelligent service 1, as shown in fig. 8, the method includes:
801. the switch receives a call request sent by a user A, and determines that an intelligent service signed by the user A is an intelligent service 1 according to the call request.
The call request comprises the telephone number of the user A, and the exchanger determines the intelligent service signed by the user A according to the telephone number of the user A.
802. The exchange assigns the call request to the SEE running intelligent service 1.
In this embodiment, an SEE for running the intelligent service 1 is taken as SEE1 for example
803. The SEE1 receives the call request sent by the switch, and analyzes the call request to obtain the telephone number of the user a and the service identifier of the intelligent service 1 signed by the user a.
804. The SEE1 determines the cluster corresponding to the intelligent service 1 according to the service identifier query CC of the intelligent service 1.
In this embodiment, based on the example described in table 1, the cluster corresponding to the intelligent service 1 is the cluster 1.
805. SEE1 sends a query request to the second target SDU in cluster 1.
The second target SDU is any one SDU in the cluster.
806. And the second target SDU receives the query request and forwards the query request to a database corresponding to the second target SDU.
807. And the database corresponding to the second target SDU receives the query request from the second target SDU, queries data according to the query request and returns a query result to the second target SDU.
808. And the second target SDU receives the query result returned by the database corresponding to the second target SDU, and reports the query result to SEE 1.
And after receiving the query result reported by the second target SDU, the SEE1 executes the subsequent service flow according to the query result.
After the user a finishes calling the user B, the SEE1 needs to update the service data of the intelligent service 1, where the updated data includes the call duration, the charge generated by the call, and so on, in this case, the method further includes steps 809 and 810.
809. The SEE1 sends a write request to the second target SDU according to the duration of the current call and the cost incurred by the current call.
810. The second target SDU receives the write request and writes the current call duration and the charge incurred by the current call in all databases corresponding to all SDUs in the cluster 1 according to the write request.
According to the method provided by the embodiment of the invention, the SDU is subjected to cluster configuration due to the corresponding relation between the SDU and the database, so that the cluster configuration of the database is realized, and Oracle cluster hardware HA and Oracle LoadBance are not required to be used in the mode, so that Oracle software can be saved. Meanwhile, the SDU in the embodiment of the invention can belong to a plurality of clusters, namely the Oracle database corresponding to the SDU can belong to a plurality of clusters.
An embodiment of the present invention further provides a device 90 for updating data, as shown in fig. 9, where the device 90 includes N SDUs and M ses, where the N SDUs form a plurality of clusters, each cluster includes at least one SDU, the SDUs correspond to a database one by one, each SDU in the N SDUs belongs to one or more clusters, and N, M is a positive integer; wherein the content of the first and second substances,
the SEE is used for receiving a service request of an intelligent service sent by a user;
the SEE is further configured to determine a cluster corresponding to the intelligent service according to the service identifier of the intelligent service carried in the service request, where the cluster corresponding to the intelligent service includes a cluster mode of the cluster corresponding to the intelligent service and an SDU in the cluster corresponding to the intelligent service;
and the SEE is further configured to update data related to the intelligent service in a database corresponding to the SDU in the cluster corresponding to the intelligent service according to a cluster mode of the cluster corresponding to the intelligent service.
Optionally, the SEE is specifically configured to:
when the cluster corresponding to the intelligent service is a load balancing cluster, updating data related to the intelligent service in a database corresponding to a first target SDU in the cluster corresponding to the intelligent service, wherein the database corresponding to the first target SDU is a database used for storing the data of the intelligent service of the user in the cluster corresponding to the intelligent service;
and when the cluster corresponding to the intelligent service is a high-availability cluster, updating data related to the intelligent service in a database corresponding to all SDUs in the cluster corresponding to the intelligent service.
Optionally, when the cluster is a load balancing cluster, the preset SDU in the cluster corresponds to the preset number segment, and the database corresponding to the preset SDU is used for storing the data of the intelligent service for the user using the preset number segment.
Optionally, the SEE is specifically configured to:
when the cluster corresponding to the intelligent service is a load balancing cluster, determining a preset number segment to which the number corresponding to the user belongs;
determining a preset SDU corresponding to a preset number segment to which the number corresponding to the user belongs as a first target SDU;
sending a write request to the first target SDU;
and the first target SDU is used for receiving the writing request and updating data related to the intelligent service in a database corresponding to the first target SDU.
Optionally, the SEE is specifically configured to:
when the cluster corresponding to the intelligent service is a high-availability cluster, sending a multi-write request to a second target SDU in the cluster corresponding to the intelligent service, wherein the second target SDU is any one SDU in the cluster corresponding to the intelligent service;
and the second target SDU is used for receiving a multi-write request sent by the SEE and updating data related to the intelligent service to a database corresponding to all SDUs in a cluster corresponding to the intelligent service according to the multi-write request.
Optionally, the SEE is further configured to:
when the cluster corresponding to the intelligent service is a load balancing cluster, inquiring service data and user data of the intelligent service of the user in a database corresponding to the first target SDU, and judging whether the user initiating the intelligent service is legal or not according to the service data and the user data;
and when the cluster corresponding to the intelligent service is a high-availability cluster, inquiring the service data and the user data of the intelligent service of the user in a database corresponding to any SDU in the cluster corresponding to the intelligent service, and judging whether the user initiating the intelligent service is legal or not according to the service data and the user data.
Since the device is used for executing the method, the beneficial effects of the device can be seen in the beneficial effects of the method part, and are not described herein again.
The embodiment of the present invention further provides an apparatus 100 for updating data, including a memory 1001 and a processor 1002, where the memory 1001 is used for storing a code, so that the processor 1002 executes an action corresponding to the code, the processor 1002 runs N SDUs and M SEE, where the N SDUs form a plurality of clusters, one cluster includes at least one SDU, the SDUs are in one-to-one correspondence with a database, each SDU in the N SDUs belongs to one or more clusters, and N, M is a positive integer; the apparatus 100 is configured to perform the above-described method.
As shown in fig. 10, the apparatus 100 includes a software layer including N SDUs and M SEE, and a hardware layer including a memory 1001 and a processor 1002.
Since the device is used for carrying out the above-described method, the advantageous effects of the device can be seen in the method section.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working process of the above-described apparatus may refer to the corresponding process in the foregoing method embodiment, and is not described herein again.
The integrated unit implemented in the form of a software functional unit may be stored in a computer readable storage medium. The software functional unit is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute some steps of the methods according to the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (17)

1. A cluster configuration apparatus, applied to an intelligent network functional entity, where the intelligent network functional entity includes N service data units SDU, where N is a positive integer, and the apparatus includes: a configuration unit;
the configuration unit is configured to configure a cluster corresponding to each intelligent service in a plurality of intelligent services, where a cluster corresponding to an intelligent service includes a cluster manner of the cluster corresponding to the intelligent service and SDUs in the clusters corresponding to the intelligent service, where one cluster includes at least one SDU, the SDUs are in one-to-one correspondence with the database, and each SDU in the N SDUs belongs to one or more clusters;
the configuration unit is specifically configured to: determining the reliability requirement of each intelligent service in the plurality of intelligent services, wherein the reliability requirement comprises a high reliability requirement and no high reliability requirement, and when the reliability requirement of one intelligent service is the high reliability requirement, determining that the clustering mode of the cluster corresponding to the intelligent service is high availability; and when the reliability requirement of one intelligent service is no high reliability requirement, determining the cluster mode of the cluster corresponding to the intelligent service as load balancing.
2. The apparatus according to claim 1, wherein the configuration unit is specifically configured to:
when the cluster mode of the cluster corresponding to the intelligent service is high availability, determining that the cluster corresponding to the intelligent service comprises P SDUs, wherein P is a value obtained by upwards rounding the ratio of the number of call attempts per second of the intelligent service to the highest number of call times capable of being carried per second of a database, and is a positive integer;
when the cluster mode of the cluster corresponding to the intelligent service is load balancing, determining Q SDUs, wherein Q is a value obtained by rounding up the ratio of the number of pilot calls per second of the intelligent service to the highest number of calls which can be carried per second of a database; according to the method, the number of distributed users of each SDU in Q SDUs is determined according to the number of users of the intelligent service, the total number of the distributed users of the Q SDUs is the number of users of the intelligent service, whether the number of call attempts per second of a database corresponding to each SDU in Q SDU meets a preset condition is judged, if yes, the Q SDU is determined to be the SDU forming a cluster corresponding to the intelligent service, if not, Q is set to be Q +1, the number of users is continuously distributed to each SDU in Q SDU according to the number of users of the intelligent service until the number of call attempts per second of the database corresponding to each SDU in Q SDU meets the preset condition, the number of call attempts per second of one database is calculated according to the number of call attempts distributed to the SDU corresponding to the database, and the number of call attempts per second of one database meets the preset condition is smaller than the maximum number of calls which the database can bear per second, q is a positive integer.
3. The apparatus of claim 1, further comprising:
an obtaining unit, configured to obtain configuration information, where the configuration information is configuration information of a cluster corresponding to each of the plurality of intelligent services;
the configuration unit is specifically configured to configure a cluster corresponding to each intelligent service in the plurality of intelligent services according to the configuration information.
4. The apparatus according to any of claims 1-3, wherein the configuration unit is further configured to:
when a cluster corresponding to an intelligent service is a load balancing cluster, configuring a preset number segment for a preset SDU in the load balancing cluster, wherein a database corresponding to the preset SDU is used for storing the data of the intelligent service of a user using the preset number segment.
5. A method for updating data, applied to an intelligent network functional entity, where the intelligent network functional entity includes N service data units SDUs and M service operation environments SEE, where the N SDUs form a plurality of clusters, a cluster includes at least one SDU, the SDUs correspond to a database one-to-one, and each SDU in the N SDUs belongs to one or more clusters, and N, M is a positive integer, the method includes:
the SEE receives a service request of an intelligent service sent by a user;
the SEE determines a cluster corresponding to the intelligent service according to the service identifier of the intelligent service carried in the service request, wherein the cluster corresponding to the intelligent service comprises a cluster mode of the cluster corresponding to the intelligent service and SDU (service data Unit) in the cluster corresponding to the intelligent service;
and the SEE updates data related to the intelligent service in a database corresponding to the SDU in the cluster corresponding to the intelligent service according to the cluster mode of the cluster corresponding to the intelligent service.
6. The method according to claim 5, wherein the SEE updates the data related to the intelligent service in the database corresponding to the SDU in the cluster corresponding to the intelligent service according to the clustering manner of the cluster corresponding to the intelligent service, and comprises:
when the cluster corresponding to the intelligent service is a load balancing cluster, the SEE updates data related to the intelligent service in a database corresponding to a first target SDU in the cluster corresponding to the intelligent service, wherein the database corresponding to the first target SDU is a database used for storing the data of the intelligent service of the user in the cluster corresponding to the intelligent service;
and when the cluster corresponding to the intelligent service is a high-availability cluster, the SEE updates data related to the intelligent service in a database corresponding to all SDUs in the cluster corresponding to the intelligent service.
7. The method according to claim 6, wherein when the cluster is a load balancing cluster, the predetermined SDU in the cluster corresponds to a predetermined number segment, and the database corresponding to the predetermined SDU is used for storing the data of the smart service of the user using the predetermined number segment.
8. The method of claim 7, wherein when the cluster corresponding to the intelligent service is a load balancing cluster, the SEE updates data related to the intelligent service in a database corresponding to a first target SDU in the cluster corresponding to the intelligent service, and the method comprises:
when the cluster corresponding to the intelligent service is a load balancing cluster, the SEE determines a preset number segment to which the number corresponding to the user belongs;
the SEE determines a preset SDU corresponding to a preset number segment to which a number corresponding to the user belongs as a first target SDU;
the SEE sends a write request to the first target SDU;
and the first target SDU receives the writing request and updates data related to the intelligent service in a database corresponding to the first target SDU.
9. The method according to claim 6, wherein when the cluster corresponding to the intelligent service is a high availability cluster, the SEE updates data related to the intelligent service in a database corresponding to all SDUs in the cluster corresponding to the intelligent service, and comprises:
the SEE sends a multi-write request to a second target SDU in a cluster corresponding to the intelligent service, wherein the second target SDU is any one SDU in the cluster corresponding to the intelligent service;
and the second target SDU receives a multi-write request sent by the SEE, and updates data related to the intelligent service to a database corresponding to all SDUs in a cluster corresponding to the intelligent service according to the multi-write request.
10. The method according to any one of claims 6-8, further comprising:
when the cluster corresponding to the intelligent service is a load balancing cluster, the SEE inquires service data and user data of the intelligent service of the user in a database corresponding to the first target SDU, and judges whether the user initiating the intelligent service is legal or not according to the service data and the user data;
when the cluster corresponding to the intelligent service is a high-availability cluster, the SEE queries the service data and the user data of the intelligent service of the user in a database corresponding to any SDU in the cluster corresponding to the intelligent service, and judges whether the user initiating the intelligent service is legal or not according to the service data and the user data.
11. An apparatus for updating data, the apparatus comprising N service data units SDUs and M service operation environments SEE, the N SDUs forming a plurality of clusters, a cluster comprising at least one SDU, the SDUs corresponding to a database one-to-one, each of the N SDUs belonging to one or more clusters, N, M being positive integers; wherein the content of the first and second substances,
the SEE is used for receiving a service request of the intelligent service sent by a user;
the SEE is further configured to determine a cluster corresponding to the intelligent service according to the service identifier of the intelligent service carried in the service request, where the cluster corresponding to the intelligent service includes a cluster mode of the cluster corresponding to the intelligent service and an SDU in the cluster corresponding to the intelligent service;
and the SEE is further configured to update data related to the intelligent service in a database corresponding to the SDU in the cluster corresponding to the intelligent service according to a cluster mode of the cluster corresponding to the intelligent service.
12. The apparatus of claim 11, wherein the SEE is specifically configured to:
when the cluster corresponding to the intelligent service is a load balancing cluster, updating data related to the intelligent service in a database corresponding to a first target SDU in the cluster corresponding to the intelligent service, wherein the database corresponding to the first target SDU is a database used for storing the data of the intelligent service of the user in the cluster corresponding to the intelligent service;
and when the cluster corresponding to the intelligent service is a high-availability cluster, updating data related to the intelligent service in a database corresponding to all SDUs in the cluster corresponding to the intelligent service.
13. The apparatus of claim 12, wherein when the cluster is a load balancing cluster, a preset SDU in the cluster corresponds to a preset number segment, and the database corresponding to the preset SDU is used for storing data of the smart service of a user using the preset number segment.
14. The apparatus of claim 13, wherein the SEE is specifically configured to:
when the cluster corresponding to the intelligent service is a load balancing cluster, determining a preset number segment to which the number corresponding to the user belongs;
determining a preset SDU corresponding to a preset number segment to which the number corresponding to the user belongs as a first target SDU;
sending a write request to the first target SDU;
and the first target SDU is used for receiving the writing request and updating data related to the intelligent service in a database corresponding to the first target SDU.
15. The apparatus of claim 12, wherein the SEE is specifically configured to:
when the cluster corresponding to the intelligent service is a high-availability cluster, sending a multi-write request to a second target SDU in the cluster corresponding to the intelligent service, wherein the second target SDU is any one SDU in the cluster corresponding to the intelligent service;
and the second target SDU is used for receiving a multi-write request sent by the SEE and updating data related to the intelligent service to a database corresponding to all SDUs in a cluster corresponding to the intelligent service according to the multi-write request.
16. The apparatus of any of claims 12-14, wherein the SEE is further configured to:
when the cluster corresponding to the intelligent service is a load balancing cluster, inquiring service data and user data of the intelligent service of the user in a database corresponding to the first target SDU, and judging whether the user initiating the intelligent service is legal or not according to the service data and the user data;
and when the cluster corresponding to the intelligent service is a high-availability cluster, inquiring the service data and the user data of the intelligent service of the user in a database corresponding to any SDU in the cluster corresponding to the intelligent service, and judging whether the user initiating the intelligent service is legal or not according to the service data and the user data.
17. An apparatus for updating data, comprising a memory and a processor, wherein the memory is configured to store a code, so that the processor can perform an action corresponding to the code, the processor runs N service data units, SDUs, and M service execution environments, SEE, the N SDUs form a plurality of clusters, one cluster comprises at least one SDU, the SDUs are in one-to-one correspondence with a database, each SDU of the N SDUs belongs to one or more clusters, and N, M is a positive integer;
the apparatus is for performing the method of any one of claims 5 to 10.
CN201610332585.6A 2016-05-18 2016-05-18 Cluster configuration device, and method and device for updating data Active CN105975614B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610332585.6A CN105975614B (en) 2016-05-18 2016-05-18 Cluster configuration device, and method and device for updating data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610332585.6A CN105975614B (en) 2016-05-18 2016-05-18 Cluster configuration device, and method and device for updating data

Publications (2)

Publication Number Publication Date
CN105975614A CN105975614A (en) 2016-09-28
CN105975614B true CN105975614B (en) 2020-01-21

Family

ID=56955279

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610332585.6A Active CN105975614B (en) 2016-05-18 2016-05-18 Cluster configuration device, and method and device for updating data

Country Status (1)

Country Link
CN (1) CN105975614B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106803790B (en) * 2016-12-06 2019-09-17 浙江大华技术股份有限公司 A kind of upgrade control method and device of group system
CN107465714B (en) * 2017-01-23 2021-01-01 北京思特奇信息技术股份有限公司 Dynamic configuration data updating system and method based on application cluster
CN108512877B (en) * 2017-02-28 2022-03-18 腾讯科技(北京)有限公司 Method and device for sharing data in server cluster
CN107172169A (en) * 2017-05-27 2017-09-15 广东欧珀移动通信有限公司 Method of data synchronization, device, server and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101645022A (en) * 2009-08-28 2010-02-10 曙光信息产业(北京)有限公司 Work scheduling management system and method for a plurality of colonies
US9031994B1 (en) * 2012-12-27 2015-05-12 Emc Corporation Database partitioning for data processing system
CN105095248A (en) * 2014-05-04 2015-11-25 中国移动通信集团公司 Database cluster system, restoring method for same and management node of same
CN105430048A (en) * 2015-10-29 2016-03-23 努比亚技术有限公司 Message delivery system and message delivery method based on multiple clusters

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101645022A (en) * 2009-08-28 2010-02-10 曙光信息产业(北京)有限公司 Work scheduling management system and method for a plurality of colonies
US9031994B1 (en) * 2012-12-27 2015-05-12 Emc Corporation Database partitioning for data processing system
CN105095248A (en) * 2014-05-04 2015-11-25 中国移动通信集团公司 Database cluster system, restoring method for same and management node of same
CN105430048A (en) * 2015-10-29 2016-03-23 努比亚技术有限公司 Message delivery system and message delivery method based on multiple clusters

Also Published As

Publication number Publication date
CN105975614A (en) 2016-09-28

Similar Documents

Publication Publication Date Title
CN105975614B (en) Cluster configuration device, and method and device for updating data
EP3343426B1 (en) Database access control method and apparatus
CN107430528B (en) Opportunistic resource migration to optimize resource placement
CN107733957B (en) Distributed service configuration system and version number distribution method
CN102495857A (en) Load balancing method for distributed database
WO2020019743A1 (en) Traffic control method and device
CN103036926A (en) Business push system and method
CN101071434B (en) User distributing method, device and system for distributed database system
CN112612686A (en) Performance test method and device, electronic equipment and storage medium
CN111722918A (en) Service identification code generation method and device, storage medium and electronic equipment
US20230367749A1 (en) Data migration method and apparatus, device, medium, and computer product
CN110727738B (en) Global routing system based on data fragmentation, electronic equipment and storage medium
CN108471385B (en) Flow control method and device for distributed system
CN112751761A (en) Transaction routing switching method, intermediate system and service processing system
CN112650812A (en) Data fragment storage method and device, computer equipment and storage medium
EP3056988A1 (en) Method, apparatus and system for home management device virtualization
CN103258389B (en) The method of self-aided terminal upload file, system and self-aided terminal
CN113014608A (en) Flow distribution control method and device, electronic equipment and storage medium
CN108377473B (en) File content distribution method and device in D2D wireless cache network
CN114422331A (en) Disaster tolerance switching method, device and system
CN1997060A (en) Method and system for index acquisition
EP2348676B1 (en) Method for accessing magnanimity data of intelligent network service database and system and device thereof
CN111580959B (en) Data writing method, data writing device, server and storage medium
CN108459926B (en) Data remote backup method and device and computer readable medium
CN112636959B (en) Network slice privacy number service guarantee system and method for distinguishing service types

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant