CN109446196A - Major key generates processing and determines that method, major key generates and application server - Google Patents

Major key generates processing and determines that method, major key generates and application server Download PDF

Info

Publication number
CN109446196A
CN109446196A CN201811122131.1A CN201811122131A CN109446196A CN 109446196 A CN109446196 A CN 109446196A CN 201811122131 A CN201811122131 A CN 201811122131A CN 109446196 A CN109446196 A CN 109446196A
Authority
CN
China
Prior art keywords
major key
data
application
generation
key
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.)
Pending
Application number
CN201811122131.1A
Other languages
Chinese (zh)
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.)
Nubia Technology Co Ltd
Original Assignee
Nubia Technology 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 Nubia Technology Co Ltd filed Critical Nubia Technology Co Ltd
Priority to CN201811122131.1A priority Critical patent/CN109446196A/en
Publication of CN109446196A publication Critical patent/CN109446196A/en
Pending legal-status Critical Current

Links

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

Processing is generated the invention discloses a kind of major key and determines that method, major key generates and application server, by acquiring daily record data;Major key is generated according to collected daily record data;The major key of generation is put into corresponding buffer queue.Application service can generate in server in major key in the data for receiving write-in and read major key, using the major key read as the major key of data.In this way, realizing the generation of major key and being associated with write-in data.Simultaneously, due to generating program using special major key, the program generates major key by log information, independent of complicated calculation method, it is possible thereby to reduce the power consumption of server, by the power consumption of each application server be used in it is prior functionally, to promote user in the operating experience of application side.

Description

Major key generates processing and determines that method, major key generates and application server
Technical field
The present invention relates to fields of communication technology, generate processing more specifically to a kind of major key and determine method, major key Generation and application server.
Background technique
When user concurrent amount is high, the data volume that each application service is written also can be very big.At this time each data pair The formation speed for the major key answered just has large effect for system performance.In relevant each scheme, in order to guarantee major key Randomness, the generation of major key is typically all to be based on various algorithms, requires certain consumption by calculating generation major key each time When, when concurrency is high, the generation of major key will be slower and slower, and can consume more server energy consumptions, goes forward side by side And user is influenced in the operating experience of application side.Therefore, it is necessary to realize a set of new scheme, to solve these problems.
Summary of the invention
The technical problem to be solved in the present invention is that: in relevant generation major key scheme, when concurrency is high, major key Generation will be slower and slower, and more server energy consumptions can be consumed, and influence user in turn in the operation of application side The problem of experience.For the technical problem, the present invention provides a kind of major key generation processing and determining method, major key generation and application Server.
In order to solve the above technical problems, the present invention provides a kind of major key generation processing method, the major key generates processing side Method includes:
Acquire daily record data;
Major key is generated according to the collected daily record data;
The major key of generation is put into corresponding buffer queue, so that application service is read from the buffer queue Major key;The major key is unique in the corresponding buffer queue.
Optionally, the described major key of generation is put into corresponding buffer queue includes:
The major key of generation is put into corresponding application cache queue;The application cache queue uniquely corresponds to one Application service.
Optionally, it is described the major key of generation is put into corresponding buffer queue before, further includes:
The major key of generation is put into preset data table.
Optionally, the major key of generation is put into preset data table before, further includes:
Determine that the major key generated is not present in the preset data table.
Optionally, the described major key of generation is put into preset data table includes:
The major key of generation is put into corresponding default application data sheet;The default application data sheet uniquely corresponds to One application service.
Optionally, described to include: according to the collected daily record data generation major key
According to pre-set major key length, reads the collected daily record data at random to generate and meet the master The major key of key length.
Optionally, in application service after reading major key in the buffer queue, further includes:
The major key that the application service is read is removed from the buffer queue.
Further, the present invention also provides a kind of major keys to determine method, and the major key generates processing method and includes:
In the data for receiving write-in, is generated in service in major key and read major key;
Using the major key read as the major key of the data.
Further, the present invention also provides a kind of major keys to generate server, and it includes first that the major key, which generates server, Processor, first memory and the first communication bus;
First communication bus is for realizing the connection communication between first processor and first memory;
The first processor is for executing one or more first program stored in first memory, on realizing State the step of major key generates processing method.
Further, the present invention also provides a kind of application server, the application server includes second processor, Two memories and the second communication bus;
Second communication bus is for realizing the connection communication between second processor and second memory;
The second processor is for executing one or more second program stored in second memory, on realizing State the step of major key determines method.
Further, the present invention also provides a kind of computer readable storage medium, the computer readable storage mediums It is stored with one or more program, one or more of programs can be executed by one or more processor, to realize The step of above-mentioned major key generation processing method or above-mentioned major key determine method.
Beneficial effect
Major key provided by the invention generates processing and determines that method, major key generates and application server, for presently relevant Generation major key scheme in, when concurrency is high, the generation of major key will be slower and slower, and can consume more clothes It is engaged in device power consumption, and influences user in turn the operating experience of application side the technical issues of, pass through acquisition daily record data;According to acquisition The daily record data arrived generates major key;The major key of generation is put into corresponding buffer queue to (major key is in corresponding buffer queue It should be unique).In this way, application service in the data for receiving write-in, can generate in server in major key and read major key, it will Major key of the major key read as data.In this way, realizing the generation of major key and being associated with write-in data.Meanwhile Due to generating program using special major key, which generates major key by log information, independent of complicated calculating side Method, it is possible thereby to reduce the power consumption of server, by the power consumption of each application server be used in it is prior functionally, to be promoted Operating experience of the user in application side.In addition, application service can directly read major key in buffer queue in the present invention, because The major key of this data that cracking can be written, further improves user in the operating experience of application side.
Detailed description of the invention
Present invention will be further explained below with reference to the attached drawings and examples, in attached drawing:
The hardware structural diagram of Fig. 1 optional terminal of each embodiment to realize the present invention;
A kind of optional communications network system architecture diagram of Fig. 2 each embodiment to realize the present invention;
The structural schematic diagram of Fig. 3 each embodiment one optional server to realize the present invention;
Fig. 4 is the basic procedure schematic diagram that a kind of major key that first embodiment of the invention provides generates processing method;
Fig. 5 is a kind of schematic diagram for application cache queue that first embodiment of the invention provides;
Fig. 6 is a kind of schematic diagram for application data sheet that first embodiment of the invention provides;
Fig. 7 is that a kind of major key that first embodiment of the invention provides removes schematic diagram;
Fig. 8 is the basic procedure schematic diagram that a kind of major key that first embodiment of the invention provides determines method;
Fig. 9 is the structural schematic diagram that a kind of major key that third embodiment of the invention provides generates server;
Figure 10 is a kind of structural schematic diagram for application server that third embodiment of the invention provides.
Specific embodiment
It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, it is not intended to limit the present invention.
In subsequent description, it is only using the suffix for indicating such as " module ", " component " or " unit " of element Be conducive to explanation of the invention, itself there is no a specific meaning.Therefore, " module ", " component " or " unit " can mix Ground uses.
Terminal can be implemented in a variety of manners.For example, terminal described in the present invention may include such as with bending Mobile phone, tablet computer, laptop, palm PC, personal digital assistant (the Personal Digital of function Assistant, PDA), portable media player (Portable Media Player, PMP), navigation device, wearable set The fixed terminals such as the mobile terminals such as standby, Intelligent bracelet, pedometer, and number TV, desktop computer.
It will be illustrated by taking mobile terminal as an example in subsequent descriptions, it will be appreciated by those skilled in the art that in addition to special Except element for moving purpose, the construction of embodiment according to the present invention can also apply to the terminal of fixed type.
Referring to Fig. 1, a kind of hardware structural diagram of its mobile terminal of each embodiment to realize the present invention, the shifting Dynamic terminal 100 may include: RF (Radio Frequency, radio frequency) unit 101, WiFi module 102, audio output unit 103, A/V (audio/video) input unit 104, sensor 105, display unit 106, user input unit 107, interface unit 108, the components such as memory 109, processor 110 and power supply 111.It will be understood by those skilled in the art that shown in Fig. 1 Mobile terminal structure does not constitute the restriction to mobile terminal, and mobile terminal may include components more more or fewer than diagram, Perhaps certain components or different component layouts are combined.
It is specifically introduced below with reference to all parts of the Fig. 1 to mobile terminal:
Radio frequency unit 101 can be used for receiving and sending messages or communication process in, signal sends and receivees, specifically, by base station Downlink information receive after, to processor 110 handle;In addition, the data of uplink are sent to base station.In general, radio frequency unit 101 Including but not limited to antenna, at least one amplifier, transceiver, coupler, low-noise amplifier, duplexer etc..In addition, penetrating Frequency unit 101 can also be communicated with network and other equipment by wireless communication.Any communication can be used in above-mentioned wireless communication Standard or agreement, including but not limited to GSM (Global System of Mobile communication, global system for mobile telecommunications System), GPRS (General Packet Radio Service, general packet radio service), CDMA2000 (Code Division Multiple Access 2000, CDMA 2000), WCDMA (Wideband Code Division Multiple Access, wideband code division multiple access), TD-SCDMA (Time Division-Synchronous Code Division Multiple Access, TD SDMA), FDD-LTE (Frequency Division Duplexing-Long Term Evolution, frequency division duplex long term evolution) and TDD-LTE (Time Division Duplexing-Long Term Evolution, time division duplex long term evolution) etc..
WiFi belongs to short range wireless transmission technology, and mobile terminal can help user to receive and dispatch by WiFi module 102Electricity Sub- mail, browsing webpage and access streaming video etc., it provides wireless broadband internet for user and accesses.Although Fig. 1 shows Go out WiFi module 102, but it is understood that, and it is not belonging to must be configured into for mobile terminal, it completely can be according to need It to omit within the scope of not changing the essence of the invention.
Audio output unit 103 can be in call signal reception pattern, call mode, record mould in mobile terminal 100 When under the isotypes such as formula, speech recognition mode, broadcast reception mode, by radio frequency unit 101 or WiFi module 102 it is received or The audio data stored in memory 109 is converted into audio signal and exports to be sound.Moreover, audio output unit 103 Audio output relevant to the specific function that mobile terminal 100 executes can also be provided (for example, call signal receives sound, disappears Breath receives sound etc.).Audio output unit 103 may include loudspeaker, buzzer etc..
A/V input unit 104 is for receiving audio or video signal.A/V input unit 104 may include graphics processor (Graphics Processing Unit, GPU) 1041 and microphone 1042, graphics processor 1041 is in video acquisition mode Or the image data of the static images or video obtained in image capture mode by image capture apparatus (such as camera) carries out Reason.Treated, and picture frame may be displayed on display unit 106.Through graphics processor 1041, treated that picture frame can be deposited Storage carries out in memory 109 (or other computer readable storage mediums) or via radio frequency unit 101 or WiFi module 102 It sends.Microphone 1042 can be in telephone calling model, logging mode, speech recognition mode etc. operational mode via Mike Wind 1042 receives sound (audio data), and can be audio data by such acoustic processing.Treated audio (language Sound) data can be converted in the case where telephone calling model to be sent to mobile communication base station via radio frequency unit 101 Format output.Microphone 1042 can be implemented various types of noises elimination (or inhibition) algorithms and received with eliminating (or inhibition) With the noise or interference generated during transmission audio signal.
Mobile terminal 100 further includes at least one sensor 105, such as optical sensor, motion sensor and other biographies Sensor.Specifically, optical sensor includes ambient light sensor and proximity sensor, wherein ambient light sensor can be according to environment The light and shade of light adjusts the brightness of display panel 1061, and proximity sensor can close when mobile terminal 100 is moved in one's ear Display panel 1061 and/or backlight.As a kind of motion sensor, accelerometer sensor can detect in all directions (general For three axis) size of acceleration, it can detect that size and the direction of gravity when static, can be used to identify the application of mobile phone posture (such as horizontal/vertical screen switching, dependent game, magnetometer pose calibrating), Vibration identification correlation function (such as pedometer, percussion) etc.; The fingerprint sensor that can also configure as mobile phone, pressure sensor, iris sensor, molecule sensor, gyroscope, barometer, The other sensors such as hygrometer, thermometer, infrared sensor, details are not described herein.
Display unit 106 is for showing information input by user or being supplied to the information of user.Display unit 106 can wrap Display panel 1061 is included, liquid crystal display (Liquid Crystal Display, LCD), Organic Light Emitting Diode can be used Forms such as (Organic Light-Emitting Diode, OLED) configure display panel 1061.
User input unit 107 can be used for receiving the number or character information of input, and generate the use with mobile terminal Family setting and the related key signals input of function control.Specifically, user input unit 107 may include touch panel 1071 with And other input equipments 1072.Touch panel 1071, also referred to as touch screen collect the touch operation of user on it or nearby (for example user uses any suitable objects or attachment such as finger, stylus on touch panel 1071 or in touch panel 1071 Neighbouring operation), and corresponding attachment device is driven according to preset formula.Touch panel 1071 may include touch detection Two parts of device and touch controller.Wherein, the touch orientation of touch detecting apparatus detection user, and detect touch operation band The signal come, transmits a signal to touch controller;Touch controller receives touch information from touch detecting apparatus, and by it It is converted into contact coordinate, then gives processor 110, and order that processor 110 is sent can be received and executed.In addition, can To realize touch panel 1071 using multiple types such as resistance-type, condenser type, infrared ray and surface acoustic waves.In addition to touch panel 1071, user input unit 107 can also include other input equipments 1072.Specifically, other input equipments 1072 can wrap It includes but is not limited in physical keyboard, function key (such as volume control button, switch key etc.), trace ball, mouse, operating stick etc. It is one or more, specifically herein without limitation.
Further, touch panel 1071 can cover display panel 1061, when touch panel 1071 detect on it or After neighbouring touch operation, processor 110 is sent to determine the type of touch event, is followed by subsequent processing device 110 according to touch thing The type of part provides corresponding visual output on display panel 1061.Although in Fig. 1, touch panel 1071 and display panel 1061 be the function that outputs and inputs of realizing mobile terminal as two independent components, but in certain embodiments, it can The function that outputs and inputs of mobile terminal is realized so that touch panel 1071 and display panel 1061 is integrated, is not done herein specifically It limits.
Interface unit 108 be used as at least one external device (ED) connect with mobile terminal 100 can by interface.For example, External device (ED) may include wired or wireless headphone port, external power supply (or battery charger) port, wired or nothing Line data port, memory card port, the port for connecting the device with identification module, audio input/output (I/O) end Mouth, video i/o port, ear port etc..Interface unit 108 can be used for receiving the input from external device (ED) (for example, number It is believed that breath, electric power etc.) and the input received is transferred to one or more elements in mobile terminal 100 or can be with For transmitting data between mobile terminal 100 and external device (ED).
Memory 109 can be used for storing software program and various data.Memory 109 can mainly include storing program area The storage data area and, wherein storing program area can (such as the sound of application program needed for storage program area, at least one function Sound playing function, image player function etc.) etc.;Storage data area can store according to mobile phone use created data (such as Audio data, phone directory etc.) etc..In addition, memory 109 may include high-speed random access memory, it can also include non-easy The property lost memory, a for example, at least disk memory, flush memory device or other volatile solid-state parts.
Processor 110 is the control centre of mobile terminal, utilizes each of various interfaces and the entire mobile terminal of connection A part by running or execute the software program and/or module that are stored in memory 109, and calls and is stored in storage Data in device 109 execute the various functions and processing data of mobile terminal, to carry out integral monitoring to mobile terminal.Place Managing device 110 may include one or more processing units;Preferably, processor 110 can integrate application processor and modulatedemodulate is mediated Manage device, wherein the main processing operation system of application processor, user interface and application program etc., modem processor is main Processing wireless communication.It is understood that above-mentioned modem processor can not also be integrated into processor 110.
Mobile terminal 100 can also include the power supply 111 (such as battery) powered to all parts, it is preferred that power supply 111 Can be logically contiguous by power-supply management system and processor 110, to realize management charging by power-supply management system, put The functions such as electricity and power managed.
Although Fig. 1 is not shown, mobile terminal 100 can also be including bluetooth module etc., and details are not described herein.
Referring to Fig. 2, Fig. 2 is a kind of communications network system architecture diagram provided in an embodiment of the present invention, the communication network system System is the LTE system of universal mobile communications technology, which includes UE (User Equipment, the use of successively communication connection Family equipment) (the land Evolved UMTS Terrestrial Radio Access Network, evolved UMTS 201, E-UTRAN Ground wireless access network) 202, EPC (Evolved Packet Core, evolved packet-based core networks) 203 and operator IP operation 204。
Specifically, UE201 can be above-mentioned terminal 100, and details are not described herein again.
E-UTRAN202 includes eNodeB2021 and other eNodeB2022 etc..Wherein, eNodeB2021 can be by returning Journey (backhaul) (such as X2 interface) is connect with other eNodeB2022, and eNodeB2021 is connected to EPC203, ENodeB2021 can provide the access of UE201 to EPC203.
EPC203 may include MME (Mobility Management Entity, mobility management entity) 2031, HSS (Home Subscriber Server, home subscriber server) 2032, other MME2033, SGW (Serving Gate Way, Gateway) 2034, PGW (PDN Gate Way, grouped data network gateway) 2035 and PCRF (Policy and Charging Rules Function, policy and rate functional entity) 2036 etc..Wherein, MME2031 be processing UE201 and The control node of signaling, provides carrying and connection management between EPC203.HSS2032 is all to manage for providing some registers Such as the function of home location register (not shown) etc, and preserves some related service features, data rates etc. and use The dedicated information in family.All customer data can be sent by SGW2034, and PGW2035 can provide the IP of UE 201 Address distribution and other functions, PCRF2036 are strategy and the charging control strategic decision-making of business data flow and IP bearing resource Point, it selects and provides available strategy and charging control decision with charge execution function unit (not shown) for strategy.
IP operation 204 may include internet, Intranet, IMS (IP Multimedia Subsystem, IP multimedia System) or other IP operations etc..
Although above-mentioned be described by taking LTE system as an example, those skilled in the art should know the present invention is not only Suitable for LTE system, be readily applicable to other wireless communication systems, such as GSM, CDMA2000, WCDMA, TD-SCDMA with And the following new network system etc., herein without limitation.
As shown in figure 3, the structural schematic diagram of each embodiment one optional server to realize the present invention, the server It includes at least: input and output (IO) bus 31, processor 32, memory 33, memory 34 and communication device 35.Wherein,
Input and output (IO) bus 31 respectively with itself belonging to server other components (processor 32, memory 33, Memory 34 and communication device 35) connection, and transmission lines are provided for other components.
Processor 32 usually controls the overall operation of the server belonging to itself.For example, processor 32 execute calculate and really The operation such as recognize.Wherein, processor 32 can be central processing unit (CPU).
Communication device 35, generally includes one or more components, allows server and wireless communication system belonging to itself Radio communication between system or network.
The software code that 33 storage processor of memory is readable, processor is executable, it includes be used for control processor 32 Execute the instruction (i.e. software execution function) of functions described herein.
Based on above-mentioned mobile terminal hardware configuration, communications network system and server architecture, propose that the method for the present invention is each Embodiment.
First embodiment
Present embodiments provide a kind of major key generation processing method.Shown in Figure 4, Fig. 4 is provided in this embodiment one Kind major key generates the basic procedure schematic diagram of processing method, is applied on server, comprising:
S401: acquisition daily record data;
In the present embodiment, service can be generated by a major key, realize that a major key generates program in the service, it should Program is independent of complicated calculation method, it is possible thereby to reduce the power consumption of server, the power consumption of each application server is used In prior function.
It, can be with since the log generated of log center is magnanimity, in the present embodiment in addition, in practical applications The source data of major key is generated using daily record data, to guarantee there is the data source of magnanimity to generate major key.
In the present embodiment, the daily record data of acquisition can be the daily record data from book server, be also possible to from Daily record data is acquired in special log server.
S402: major key is generated according to collected daily record data;
In the present embodiment, major key can be generated with random acquisition one daily record data.In addition, in the present embodiment, It when generating major key, can be according to pre-set major key length, read collected daily record data at random to generate and meet The major key of major key length.Such as the data in collected log center are ABC123456, presetting major key length is 3, and major key is raw It reads daily record data ABC123456 at random at program, major key is generated according to the daily record data, the unique major key being randomly derived is just It may be ABC, A13,235 etc..
It should be noted that in the present embodiment it is fixed that each application service can be generated according to the demand of each application service The major key of length processed.Such as some application service needs the major key of 64 bit lengths, then generating in service in major key, will be arranged The application service need major key be 64 bit lengths, and then again for the application service generate major key when, just according to collected day Will data automatically generate the major key of 64 bit lengths.
S403: the major key of generation is put into corresponding buffer queue, so that application service is from corresponding buffer queue Read major key.
It should be noted that being put to guarantee the uniqueness of major key that application server is read in the application service Entering should be in the corresponding buffer queue uniquely to the major key in corresponding buffer queue.For example, having been deposited in buffer queue A In a major key A13, if regenerating a major key A13 after then, major key A13 cannot be placed into buffer queue A In.
It should also be noted that, in the present embodiment, it is aforementioned to be put into the major key of generation in corresponding buffer queue specifically It may is that and the major key of generation is put into corresponding application cache queue.Here it should be understood that application cache queue is unique A corresponding application service.I.e. in the present embodiment, different buffer queues can be distributed for different applications.Such as Fig. 5 institute Show, application services different at this time reads major key, such as application service ABC just in correspondence in corresponding application cache queue Application cache queue ABC_SET in read data.But it is to be understood that a caching can also only be arranged in the present embodiment Queue, and all application services is made all to read major key in the buffer queue.It should be noted that slow for different application The major key in queue is deposited, application service is different since variant application cache queue is corresponding, in the present embodiment A kind of embodiments possible in, major key in variant application cache queue may exist identical major key.It should be understood that It is that in another embodiments possible of the present embodiment, the major key that can be set in variant application cache queue cannot be deposited In identical major key.
In addition, in the present embodiment, special tables of data can be preset to be managed to the major key generated, from And guarantee the uniqueness for the major key being put into corresponding buffer queue.Specifically, can be put into pair by the major key generated Before in the buffer queue answered, first the major key of generation is put into preset data table.Meanwhile it being put by the major key of generation Before in preset data table, first determine that the major key generated is not present in preset data table.I.e., it is possible to which it is not that major key field, which is arranged, Repeatable index.In this way, before the major key of generation is put into preset data table, i.e., it can be to already present in preset data table Major key is judged, is confirmed whether the identical major key field of the major key for being present in the generation.If no, by the major key of the generation It is put into preset data table, and the major key of the generation is put into corresponding buffer queue.But if so, then show the generation Major key was also generated before, not uniquely.Therefore, in order to ensure that being put into the major key in buffer queue in the buffer queue only One, the major key of the generation can not be put into preset data table in the present embodiment, while also not putting the major key of the generation Enter in corresponding buffer queue.
It should be noted that for the ease of management, the aforementioned major key of generation is put into preset data table specifically be may is that The major key of generation is put into corresponding default application data sheet.Here it should be understood that default application data sheet is uniquely right Answer an application service.I.e. in the present embodiment, different tables of data can be pre-configured with for different applications.Such as Fig. 6 institute To show, application services different at this time is the management for the major key for being corresponding with different application data sheets to have been generated, such as Application service ABC is just managed by corresponding application data sheet ABC_ID, the major key recorded in tables of data ABC_ID It is the major key that application service ABC was generated that as major key, which generates service,.But it is to be understood that can also only be set in the present embodiment A tables of data is set, and all application services is made all to carry out the management of major key by the tables of data.
It in the present embodiment, can be in application service to prevent the case where application service reads identical major key After reading major key in corresponding buffer queue, major key generates the major key for servicing and reading the application service from buffer queue Remove, thus guarantee the major key will not be read again to.Generating service with major key is that different application services is provided with difference Application cache queue in case where, for example, see shown in Fig. 5, it is assumed that application service ABC is in corresponding application cache queue Major key ABC is had read in ABC_SET, then major key generate service will be by major key ABC from corresponding application cache queue ABC_ It is weeded out in SET, such as shown in Fig. 7.Correspondingly, in the case where major key generates service and is provided only with a buffer queue, this When after any one application service has read a major key, the major key all can by major key generate service from buffer queue remove.
It should be noted that can dynamically be cleared up preset data table in the present embodiment, to save major key generation The storage resource of service.Specifically, can be cleared up in the following manner:
Mode one: can access corresponding application service when the capacity of preset data table has been more than preset capacity threshold value, Obtain which application service major key currently in use has.And then by preset data table in addition to application service currently makes In major key and corresponding buffer queue there are major key outside remaining major key erasing of information fall.
It should be noted that generating service for major key is that different application services is provided with different application data sheets Situation can distribute corresponding preset capacity threshold value for each application data sheet respectively.What each application data sheet distributed respectively Preset capacity threshold value can be discussed further and be can also be different.It has been more than at this time the application data sheet in the capacity of some application data sheet When corresponding preset capacity threshold value, it can obtain which the corresponding application service of application data sheet major key currently in use has A bit.And then by the application data sheet in addition to corresponding application service major key currently in use and corresponding caching team In column there are major key outside remaining major key erasing of information fall.For example, the corresponding application service of tables of data ABC_ID is ABC, Corresponding application cache queue is ABC_SET, and when the capacity of tables of data ABC_ID has been more than preset capacity threshold value, major key is generated Service can access application service ABC, determine which application service ABC major key used at present has, while can obtain using slow Deposit which major key present in queue ABC_SET has, and then used at present by application service ABC is removed in tables of data ABC_ID Remaining major key data dump outside major key present in major key and application cache queue ABC_SET falls.
Mode two: can be set application service after removing expired application data automatically, and the data for feeding back removing are corresponding Major key which has.And then major key generates service according to the feedback of application service, will apply clothes in corresponding tables of data automatically The corresponding data dump of major key for being engaged in disposing falls.
For example, application service is the corresponding tables of data ABC_ID of ABC.Application service be ABC feedback remove one it is expired Data, the major key of the stale data are ABC, then major key generates service in tables of data ABC_ID, correspondence removes major key ABC Fall.
In the present embodiment, also corresponding to provide a kind of major key applied to application service side and determine method, referring to Fig. 8 institute Show, comprising:
S801: it in the data for receiving write-in, is generated in service in major key and reads major key;
It should be noted that needing to distribute a major key for the data when data are written in application service for subsequent tune Used time can find the data.
In the present embodiment, application service can generate in service when needing to distribute major key for a certain data from major key A major key is read as the major key of the data of the write-in.What needs to be explained here is that if it is different that major key, which generates service, Application service is provided with different application cache queues, then application service can only read master in corresponding application cache queue Key.
S802: using the major key read as the major key of the data of the write-in.
In the present embodiment, in order to guarantee the uniqueness of major key, application service can also carry out after reading major key The detector of major key determines that major key is unique.
It should be noted that each step that above-mentioned major key generates processing method can be in special master in the present embodiment Key generates to be realized in server, and above-mentioned major key determines each step of method, this can be by each special application server To be implemented separately.Certainly, in the present embodiment, above-mentioned major key generates each step of processing method and above-mentioned major key determines method What each step was also possible to realize in the same server.
It should be understood that above-mentioned major key generates each step of processing method and/or above-mentioned major key determines each of method A step can independently be realized by server as shown in Figure 3.Specifically, can be realized by being stored in memory 33 The one or more programs for stating each step execute the program by processor 32, to realize that above-mentioned major key generates processing method Each step and/or major key determine each step of method.Further, it should be noted that application server (or in server Application service) and terminal between information exchange, can be realized by communications network system as shown in Figure 2, and terminal Basic structure may refer to structure shown in FIG. 1.
Major key provided in this embodiment generates processing method and major key determines method, by acquiring daily record data;According to adopting The daily record data collected generates major key;The major key of generation is put into corresponding buffer queue to (major key is in corresponding buffer queue In should be unique).In this way, application service in the data for receiving write-in, can generate in server in major key and read major key, Using the major key read as the major key of data.In this way, realizing the generation of major key and being associated with write-in data.Together When, due to generating program using special major key, which generates major key by log information, independent of complicated calculating Method, it is possible thereby to reduce the power consumption of server, by the power consumption of each application server be used in it is prior functionally, to mention User is risen in the operating experience of application side.In addition, application service can directly read major key in buffer queue in the present invention, Therefore the major key for the data that cracking can be written, further improves user in the operating experience of application side.
Second embodiment
The present embodiment on the basis of example 1, realizes that a unique major key generates service, realizes one in the service Unique major key generates program, and the program is independent of complicated calculation method, it is possible thereby to the power consumption of server is reduced, it will be each The power consumption of application server be used in it is prior functionally.
The log generated of log center is magnanimity, and log server, such as kafka etc. is written in daily record data.It is main Key, which generates program, to be responsible for acquiring the daily record data in log center, and according to the major key length set, random to read log number Unique major key is generated accordingly.Such as the data in log center are ABC123456, major key length is 3, and it is random that major key generates program Daily record data is read, major key is generated according to daily record data, the unique major key being randomly derived may be ABC, A13,235 etc..It is logical This random mode for reading log and generating major key is crossed, can not have to rely on complicated calculation method, and guarantee the number for having magnanimity The reading data for generating unique major key according to source, and taking generate the mode of major key, and the speed for generating major key can be very fast.
It is generated in major key and realizes the tables of data for specially storing unique major key in server, master is set in the tables of data Key field is not reproducible index.The tables of data will be written after generating in major key, by the limitation of tables of data unique index, when with When the major key that machine generates duplicates, which just be will fail, to guarantee that major key generates program major key generated and is all It is unique unduplicated.
Major key generates service can generate its major key for formulating length according to the demand of each application service, such as some is answered The major key of 64 bit lengths is needed with service, then the major key that application service needs will be arranged in the major key service is 64 Length, and corresponding tables of data is written into the major key.Such as the title of application service is ABC, then the title of the tables of data Just it is named as ABC_ID.
Major key generates service when tables of data is written in major key, which can be also written to the queue of buffer service simultaneously, Such as ABC is exactly ABC_SET using corresponding queued name.In order to further increase the speed that each application service obtains major key Degree provides major key not by way of interface for application service, but buffer service is directly opened to each application service. I.e. each application service directly reads its buffer service queue in major key server to obtain major key, and every reading is primary main Key, the major key will be popped up from corresponding queue automatically, to guarantee that the major key that each application service is got will not repeat.
In conclusion the program is generated required for each application service only by the mass data in conjunction with log center One major key reduces the power consumption of each application server, and improve without the complicated generating algorithm for relying on all kinds of unique major keys When user concurrent amount is high, the speed of data write-in which thereby enhances the response speed of application service, guarantees that application will not be because of major key Caton occurs slowly for formation speed, so as to bring preferably application experience for user.
3rd embodiment
A kind of major key generation server is present embodiments provided, it is shown in Figure 9 comprising first processor 901, first Memory 902 and the first communication bus 903.Wherein:
First communication bus 903 is for realizing the connection communication between first processor 901 and first memory 902.
First processor 901 is for executing the first program of one or more stored in first memory 902, on realizing State each step that major key performed by server in first embodiment and/or second embodiment generates processing method.
A kind of application server is present embodiments provided, it is shown in Figure 10 comprising second processor 1001, second are deposited Reservoir 1002 and the second communication bus 1003.Wherein:
Second communication bus 1003 is for realizing the connection communication between second processor 1001 and second memory 1002.
Second processor 1001 is for executing the second program of one or more stored in second memory 1002, to realize Major key performed by application server determines each step of method in above-mentioned first embodiment and/or second embodiment.
The present embodiment provides a kind of computer readable storage mediums, such as floppy disk, CD, hard disk, flash memory, USB flash disk, CF card, SD Card, mmc card etc. are stored with one or more program for realizing above-mentioned each step in the computer readable storage medium, This one or more program can be executed by one or more processor, to realize above-mentioned first embodiment and/or second in fact Apply each step that major key described in example generates processing method.Details are not described herein.
It should be noted that, in this document, the terms "include", "comprise" or its any other variant are intended to non-row His property includes, so that the process, method, article or the device that include a series of elements not only include those elements, and And further include other elements that are not explicitly listed, or further include for this process, method, article or device institute it is intrinsic Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including being somebody's turn to do There is also other identical elements in the process, method of element, article or device.
The serial number of the above embodiments of the invention is only for description, does not represent the advantages or disadvantages of the embodiments.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side Method can be realized by means of software and necessary general hardware platform, naturally it is also possible to by hardware, but in many cases The former is more preferably embodiment.Based on this understanding, technical solution of the present invention substantially in other words does the prior art The part contributed out can be embodied in the form of software products, the computer software product be stored in one it is computer-readable In storage medium (such as ROM/RAM, magnetic disk, CD), including some instructions are used so that a terminal (can be mobile phone, calculate Machine, server, air conditioner or network equipment etc.) execute method described in each embodiment of the present invention.
The embodiment of the present invention is described with above attached drawing, but the invention is not limited to above-mentioned specific Embodiment, the above mentioned embodiment is only schematical, rather than restrictive, those skilled in the art Under the inspiration of the present invention, without breaking away from the scope protected by the purposes and claims of the present invention, it can also make very much Form, all of these belong to the protection of the present invention.

Claims (10)

1. a kind of major key generates processing method, which is characterized in that the major key generates processing method and includes:
Acquire daily record data;
Major key is generated according to the collected daily record data;
The major key of generation is put into corresponding buffer queue, so that master is read in application service from the buffer queue Key;The major key is unique in the corresponding buffer queue.
2. major key as described in claim 1 generates processing method, which is characterized in that described to be put into the major key of generation pair Include: in the buffer queue answered
The major key of generation is put into corresponding application cache queue;The application cache queue uniquely corresponds to an application Service.
3. major key as described in claim 1 generates processing method, which is characterized in that be put into the major key of generation described Before in corresponding buffer queue, further includes:
The major key of generation is put into preset data table.
4. major key as claimed in claim 3 generates processing method, which is characterized in that the major key of generation is put into it is default Before in tables of data, further includes:
Determine that the major key generated is not present in the preset data table.
5. major key as claimed in claim 3 generates processing method, which is characterized in that it is described the major key of generation is put into it is pre- If including: in tables of data
The major key of generation is put into corresponding default application data sheet;The default application data sheet uniquely corresponds to one Application service.
6. major key as described in any one in claim 1-5 generates processing method, which is characterized in that described according to collected institute Stating daily record data generation major key includes:
According to pre-set major key length, reading the collected daily record data at random, to meet the major key long to generate The major key of degree.
7. major key as described in any one in claim 1-5 generates processing method, which is characterized in that delay in application service from described It deposits after reading major key in queue, further includes:
The major key that the application service is read is removed from the buffer queue.
8. a kind of major key determines method, which is characterized in that the major key generates processing method and includes:
In the data for receiving write-in, is generated in service in major key and read major key;
Using the major key read as the major key of the data.
9. a kind of major key generates server, which is characterized in that it includes first processor, the first storage that the major key, which generates server, Device and the first communication bus;
First communication bus is for realizing the connection communication between first processor and first memory;
The first processor is for executing one or more first program stored in first memory, to realize such as right It is required that major key described in any one of 1 to 7 generates the step of processing method.
10. a kind of application server, which is characterized in that the application server includes second processor, second memory and Two communication bus;
Second communication bus is for realizing the connection communication between second processor and second memory;
The second processor is for executing one or more second program stored in second memory, to realize such as right It is required that the step of major key described in 8 determines method.
CN201811122131.1A 2018-09-26 2018-09-26 Major key generates processing and determines that method, major key generates and application server Pending CN109446196A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811122131.1A CN109446196A (en) 2018-09-26 2018-09-26 Major key generates processing and determines that method, major key generates and application server

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811122131.1A CN109446196A (en) 2018-09-26 2018-09-26 Major key generates processing and determines that method, major key generates and application server

Publications (1)

Publication Number Publication Date
CN109446196A true CN109446196A (en) 2019-03-08

Family

ID=65544530

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811122131.1A Pending CN109446196A (en) 2018-09-26 2018-09-26 Major key generates processing and determines that method, major key generates and application server

Country Status (1)

Country Link
CN (1) CN109446196A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110597829A (en) * 2019-11-12 2019-12-20 深圳竹云科技有限公司 Method, device and equipment for generating primary key

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101742002A (en) * 2008-11-05 2010-06-16 北大方正集团有限公司 Method, device and system for managing service information
CN104252536A (en) * 2014-09-16 2014-12-31 福建新大陆软件工程有限公司 Hbase-based internet log data inquiring method and device
CN104750870A (en) * 2015-04-20 2015-07-01 河海大学 Log storage system based on HBase and implementation method
CN104765789A (en) * 2015-03-24 2015-07-08 深圳祥云信息科技有限公司 Creation method and device for primary key of database
CN105138592A (en) * 2015-07-31 2015-12-09 武汉虹信技术服务有限责任公司 Distributed framework-based log data storing and retrieving method
CN106599104A (en) * 2016-11-29 2017-04-26 北京锐安科技有限公司 Mass data association method based on redis cluster
CN106776710A (en) * 2016-11-18 2017-05-31 广东技术师范学院 A kind of picture and text construction of knowledge base method based on vertical search engine
CN107025242A (en) * 2016-02-02 2017-08-08 南京中兴新软件有限责任公司 The clone method and device of data between database
CN108363791A (en) * 2018-02-13 2018-08-03 沈阳东软医疗系统有限公司 A kind of method of data synchronization and device of database

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101742002A (en) * 2008-11-05 2010-06-16 北大方正集团有限公司 Method, device and system for managing service information
CN104252536A (en) * 2014-09-16 2014-12-31 福建新大陆软件工程有限公司 Hbase-based internet log data inquiring method and device
CN104765789A (en) * 2015-03-24 2015-07-08 深圳祥云信息科技有限公司 Creation method and device for primary key of database
CN104750870A (en) * 2015-04-20 2015-07-01 河海大学 Log storage system based on HBase and implementation method
CN105138592A (en) * 2015-07-31 2015-12-09 武汉虹信技术服务有限责任公司 Distributed framework-based log data storing and retrieving method
CN107025242A (en) * 2016-02-02 2017-08-08 南京中兴新软件有限责任公司 The clone method and device of data between database
CN106776710A (en) * 2016-11-18 2017-05-31 广东技术师范学院 A kind of picture and text construction of knowledge base method based on vertical search engine
CN106599104A (en) * 2016-11-29 2017-04-26 北京锐安科技有限公司 Mass data association method based on redis cluster
CN108363791A (en) * 2018-02-13 2018-08-03 沈阳东软医疗系统有限公司 A kind of method of data synchronization and device of database

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110597829A (en) * 2019-11-12 2019-12-20 深圳竹云科技有限公司 Method, device and equipment for generating primary key
CN110597829B (en) * 2019-11-12 2020-03-27 深圳竹云科技有限公司 Method, device and equipment for generating primary key

Similar Documents

Publication Publication Date Title
CN107688607A (en) The method and mobile terminal of a kind of database access, computer-readable recording medium
CN104618217B (en) Share method, terminal, server and the system of resource
CN108536481A (en) A kind of application program launching method, mobile terminal and computer storage media
CN109739602A (en) A kind of mobile terminal wallpaper setting method and device, mobile terminal and storage medium
CN108536364A (en) A kind of image pickup method, terminal and computer readable storage medium
CN108537021A (en) Unlocked by fingerprint method, terminal and computer readable storage medium based on double-sided screen
CN110180181A (en) Screenshot method, device and the computer readable storage medium of Wonderful time video
CN109144441A (en) A kind of screen adjustment method, terminal and computer readable storage medium
CN110069167A (en) Touch point sweep-out method, mobile terminal and computer readable storage medium
CN109992180A (en) A kind of display control method and mobile terminal, computer readable storage medium
CN108829302A (en) A kind of interaction regulation method, equipment and computer readable storage medium
CN110347306A (en) A kind of multi-screen display method, terminal and computer readable storage medium
CN110278481A (en) Picture-in-picture implementing method, terminal and computer readable storage medium
CN107231469B (en) Terminal application management method, terminal and computer readable storage medium
CN108966162A (en) Data communications method, communication processing equipment, terminal and readable storage medium storing program for executing
CN108879239A (en) The shielding construction of mobile terminal and its connector
CN108958932A (en) A kind of control method of background application, terminal and computer readable storage medium
CN108306856A (en) A kind of interface merging method, client, server and computer readable storage medium
CN107770449A (en) continuous shooting method, electronic equipment and storage medium
CN109981892A (en) A kind of screen display method, mobile terminal and computer readable storage medium
CN109446196A (en) Major key generates processing and determines that method, major key generates and application server
CN109062964A (en) A kind of data-erasure method, terminal and computer readable storage medium
CN108897451A (en) The recognition methods of major-minor display screen, mobile terminal and computer readable storage medium
CN109151201A (en) A kind of Anti-addiction method, mobile terminal and computer storage medium
CN107797825A (en) A kind of data transmission method for uplink, terminal and computer-readable recording medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20190308

RJ01 Rejection of invention patent application after publication