Embodiment
The embodiment of the invention provides a kind of method of saving memory headroom, comprising: call the loading strategy that is used to determine treat the user of unloading physical database, obtain treating the user ID of unloading physical database; According to described user ID, obtain the described user's data for the treatment of the unloading physical database from memory database, deposit the user data that is obtained in physical database; Delete the described user data in the described memory database.Use technical scheme provided by the invention, can save the space of memory database.
Consult Fig. 1, the embodiment of the invention one provides a kind of method of saving memory headroom, and this method specifically comprises:
Step 101, when preset time arrives, call the loading strategy that is used to determine treat the user of unloading physical database, obtain treating the user ID of unloading physical database.
Wherein, be used to determine that the loading strategy for the treatment of the user of unloading physical database can be: the user ID of obtaining non-excited users, perhaps, obtain the sign that every month talk times is less than the user of predetermined value, can also be other strategy of determining to treat the user of unloading physical database, not influence realization of the present invention.
Can regularly call in the embodiment of the invention and load strategy, obtain treating the user ID of unloading physical database.
Step 102, according to described user ID, obtain the user's data for the treatment of the unloading physical database from memory database.
Step 103, user data is converted to SQL (Structured Query Language, SQL) form of field store.
Step 104, will store physical database into SQL field form storage user data.
Step 105, from memory database the deletion this user data.
Wherein, this step can just be carried out after step 102 gets access to user data from memory database, does not influence realization of the present invention.
Step 106, this storage of subscriber data of record expression still are the user storage positional information of memory database at physical database, and this moment, this user storage positional information represented that storage of subscriber data is at physical database.
Consult Fig. 2, the embodiment of the invention two provides a kind of method of saving memory headroom, before with user data unloading physical database, generates and is used for user data is carried out the control information that scheduled transaction is handled in this method, and this method specifically comprises:
Step 201, when preset time arrives, call and load strategy, obtain treating the user ID of unloading physical database.
Step 202, according to described user ID, obtain the user's data for the treatment of the unloading physical database from memory database.
Step 203, according to user data, call charging policy, obtain being used for user data is carried out the control information that scheduled transaction is handled.
Step 204, convert user data to form with the SQL field store.
Step 205, will store physical database into SQL field form storage user data and control information.
Wherein, that be used for storing subscriber information in the physical database (physical DB) is physics table (userinfo_store), and the structure of this physics table is as shown in table 1.Wherein, user profile comprises: user ID, with SQL field form storage user data, control information.Wherein, this SQL field form storage user data only is used for preserving, and can not revise, and is generally only used when physical database is loaded into memory database at user data.Be modified if be loaded into the user data of memory database, when this user data stores physical database into once more so, the SQL field that is used for the user data after the memory modify will produce again.
Field name |
Field description |
Key |
User ID |
Common |
Control information |
SQL |
Insert user data Insert into subscribervalues (); |
Table 1, physics list structure
Step 206, from memory database the deletion this user data.
Wherein, this step can just be carried out after step 202 gets access to user data from memory database, does not influence realization of the present invention.
Step 207, this user profile of record expression are stored in the user storage positional information that physical database still is a memory database, and this moment, this user storage positional information represented that storage of subscriber data is at physical database.
Consult Fig. 3, the embodiment of the invention three provides a kind of method of saving memory headroom, and this method specifically comprises:
Step 301-step 307 is identical with step 201-step 207;
Step 308, receive the request user data message, carry user ID in the message of this request user data.
Step 309, according to user ID, obtain the user storage positional information.
Step 310, according to the user storage positional information of being obtained, determine that user profile is stored in the physical database.
Step 311, according to user ID, extract with SQL field form storage user data and control information from physical database, will convert the storage format that memory database is supported to SQL field form storage user data.
Step 312, the user data after form in the above-mentioned steps changeed are loaded into memory database.
Step 313, be suction parameter with the control information, call charging policy, carry out unenforced scheduled transaction during this storage of subscriber data physical database to being loaded into user data in the memory database, for example, can carry out operations such as free of cost, the switching of account phase, Status Change to this user.
Step 314, according to user data, this user is carried out authentication.
Step 315, after authentication is passed through, to the processing of chargeing of the user data of memory database.
Wherein, step 308 can be carried out after the user activates, following two kinds of active modes can be arranged: a kind ofly be: the user is from CRM system (Customer Relation Management, CRM) side is initiated activation manipulation, be the user from the business hall, website etc. triggers crm system, make crm system activate this user, write down being designated of this User Status in the crm system this moment: activated sign; Another kind of mode is: the user calls out as calling and called, and the OCS system carries out initial activation to this user, and this mode default user is activated when calling out first.
Wherein, first step is resulting among the embodiment of the invention two and the embodiment three treats that the user of unloading physical database can be: non-excited users, perhaps talk times is less than the user of predetermined value.
Certainly, the embodiment of the invention also can be kept at user's partial data in the memory database, these certain customers' data that are stored in the memory database are carried out scheduled transaction, with another part storage of subscriber data in physical database, when this certain customers' data extract is gone out physical database, replenish and carry out storage of subscriber data unenforced scheduled transaction during physical database, perhaps, the certain customers' data that are stored in the physical database are not need to carry out scheduled transaction, this certain customers' data extract is gone out physical database, when being loaded into memory database, these certain customers' data are not made amendment.
Initial user data in the embodiment of the invention be by CRM system (CustomerRelation Management CRM) generates, and with storage of subscriber data in memory database.
One of ordinary skill in the art will appreciate that all or part of step that realizes in the foregoing description method is to instruct relevant hardware to finish by program, described program can be stored in a kind of computer-readable recording medium, for example, read-only memory, disk or CD etc.
Consult Fig. 4, the embodiment of the invention four provides a kind of data management network element, and this network element comprises: carry out loading policy unit 401, obtain user data cell 402, and user data dump unit 403 and user data delete cells 404,
Carry out to load policy unit 401, call the loading strategy that is used to determine treat the user of unloading physical database, obtain treating the user ID of unloading physical database;
Obtain user data cell 402,, obtain the user's data for the treatment of the unloading physical database from memory database according to user ID;
User data dump unit 403 deposits the user data that is obtained in physical database;
User data delete cells 404, the described user data in the deletion memory database.
Wherein, for the technical scheme that makes the embodiment of the invention four clearer, the annexation of Managed Data Network meta structure and memory database, physical database has been shown among Fig. 4, but memory database and physical database are not positioned on the data management network element, are and data management network element physical entity independently.
Obtaining between user data cell 402 and the user data dump unit 403, this network element also comprises:
First converting unit 407 converts the user data that is obtained to the SQL field store form; User data dump unit 403 will store physical database into SQL field form storage user data.
First carries out charging policy unit 405, according to the user data that is obtained, calls charging policy, obtains being used for user data is carried out the control information that scheduled transaction is handled; Control information memory cell 406 deposits described control information in physical database.
This network element also comprises:
Customer location record cell 408, behind physical database, the described storage of subscriber data of record expression is in the user storage positional information of physical database in storage of subscriber data;
Message sink unit 409 receives the message of asking user data, carries user ID in the message of request user data;
Data access unit 410 according to user ID, obtains the user storage positional information, to know this storage of subscriber data in physical database, again according to user ID, obtains user profile and the control information that comprises user data from physical database; Described user data can be with SQL field form storage user data;
Second converting unit 411 will convert the data format that memory database is supported from the user data that described physical database obtains to;
Loading unit 412 is loaded into memory database with the user data after the format conversion.
Second carries out charging policy unit 413, is suction parameter with the control information, calls charging policy, replenishes and carries out storage of subscriber data unenforced scheduled transaction during physical database;
Authenticating unit 414 is carried out authentication according to user data to this user;
User profile processing unit 415 is after the subscription authentication warp, to operations such as the user data in the memory database charge.
Consult Fig. 5, the embodiment of the invention five provides a kind of network system, and this network system comprises: data management network element, memory database and physical database.
Data management network element calls the loading strategy that is used to determine treat the user of unloading physical database, obtains treating the user ID of unloading physical database; According to this user ID, obtain the user's data for the treatment of the unloading physical database from memory database; Deposit the user data that is obtained in physical database, and this user data in the deletion memory database; The message of the request user data of user ID is carried in reception, according to user ID, obtains user data from physical database, and converts the data format that memory database is supported to, is loaded into memory database.
This data management network element also is used for according to the user data that is obtained, calling charging policy after obtaining the user's data for the treatment of the unloading physical database from memory database, obtains being used for user data is carried out the control information that scheduled transaction is handled; And in the message that is receiving the request user data, described user data is loaded into after the memory database, be suction parameter with this control information, call charging policy, replenish and carry out storage of subscriber data unenforced scheduled transaction during physical database.
As seen from the above analysis, the embodiment of the invention has following beneficial effect:
The embodiment of the invention loads strategy by calling, obtain treating the user of unloading physical database, these treat that the user of unloading physical database can be the user that non-excited users or statistics talk times are less than predetermined value, these user's data are not often used, so these user's data are taken out from memory database dump to physical database, and this user data in the deletion memory database, to save the space of memory database.
More than a kind of method, data management network element and network system of saving memory headroom provided by the present invention is described in detail, for one of ordinary skill in the art, thought according to the embodiment of the invention, part in specific embodiments and applications all can change, in sum, this description should not be construed as limitation of the present invention.