CN108259563A - Data cache method, device, server and storage medium - Google Patents

Data cache method, device, server and storage medium Download PDF

Info

Publication number
CN108259563A
CN108259563A CN201711319134.XA CN201711319134A CN108259563A CN 108259563 A CN108259563 A CN 108259563A CN 201711319134 A CN201711319134 A CN 201711319134A CN 108259563 A CN108259563 A CN 108259563A
Authority
CN
China
Prior art keywords
service identification
picture
cache
business datum
caching
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.)
Granted
Application number
CN201711319134.XA
Other languages
Chinese (zh)
Other versions
CN108259563B (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.)
Ping An Puhui Enterprise Management Co Ltd
Original Assignee
Ping An Puhui Enterprise Management 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 Ping An Puhui Enterprise Management Co Ltd filed Critical Ping An Puhui Enterprise Management Co Ltd
Priority to CN201711319134.XA priority Critical patent/CN108259563B/en
Publication of CN108259563A publication Critical patent/CN108259563A/en
Application granted granted Critical
Publication of CN108259563B publication Critical patent/CN108259563B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/565Conversion or adaptation of application format or content
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/58Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/182Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a pixel
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/42Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation
    • H04N19/423Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation characterised by memory arrangements

Landscapes

  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Multimedia (AREA)
  • Databases & Information Systems (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Library & Information Science (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The present invention relates to a kind of data cache method, device, server and storage medium, the method includes:The business datum cache request received is parsed, business datum and service identification in business datum cache request are extracted by parsing;The character digit obtained according to pre-set image parameter digit and service data statistics determines caching picture pixels size;Business datum is encoded to obtain pixel-parameters array;Pixel-parameters are read from pixel-parameters array according to pre-set image parameter digit in order;According to the pixel-parameters generation read and the caching matched caching picture of picture pixels size, service identification is added in caching picture;Inquiry spatial cache corresponding with service identification, the caching picture added with service identification is stored to the spatial cache inquired.By being depicted as and cache picture by data cached coding, image cache will be cached in spatial cache, the leakage of business datum is avoided, improve the cached security of business datum.

Description

Data cache method, device, server and storage medium
Technical field
The present invention relates to technical field of data processing, are situated between more particularly to data cache method, device, server and storage Matter.
Background technology
With the development of Internet technology, more and more data are all transmitted or are cached by internet.With interconnection , there are numerous various businesses based on data in the growth of data volume in net, and the industry wide that these business are related to compares Extensively.In business processing, some business datums are also to transmit or cache by internet.
However, in business procession, need to cache business datum.During traditional data buffer storage, no Business datum can be encrypted, directly plaintext business datum is stored in spatial cache, the business datum in spatial cache Safety it is relatively low.
Invention content
Based on this, it is necessary to for the business datum in spatial cache safety it is low the problem of, a kind of data are provided Caching method, device, server and storage medium.
A kind of data cache method, the method includes:
The business datum cache request received is parsed, the industry in business datum cache request is extracted by parsing Data of being engaged in and service identification;
The character digit obtained according to pre-set image parameter digit and service data statistics determines caching picture pixels size;
The business datum is encoded to obtain pixel-parameters array;
Pixel-parameters are read from the pixel-parameters array according to the pre-set image parameter digit in order;
According to the pixel-parameters generation read and the caching matched caching picture of picture pixels size, by the industry Business mark is added in caching picture;
Corresponding with the service identification spatial cache of inquiry, by the caching picture added with service identification store to The spatial cache inquired.
A kind of data buffer storage device, which is characterized in that described device includes:
Business datum acquisition module for being parsed to the business datum cache request received, is extracted by parsing Business datum and service identification in business datum cache request;
Dimension of picture determining module, for the character digit obtained according to pre-set image parameter digit and service data statistics Determine caching picture pixels size;
Array of pixels determining module, for being encoded to obtain pixel-parameters array to the business datum;
Pixel-parameters read module, for according to the pre-set image parameter digit in order from the pixel-parameters array Middle reading pixel-parameters;
Image generating module is cached, for according to the pixel-parameters generation read and the caching picture pixels size The service identification is added in caching picture by the caching picture matched;
Picture storage module is cached, for inquiring spatial cache corresponding with the service identification, business mark will be added with The caching picture known is stored to the spatial cache inquired.
A kind of server, the server include memory, processor and are stored on the memory and can be described The computer program run on processor, the processor are realized when performing the computer program in any embodiment of the present invention The step of data cache method of offer.
A kind of computer readable storage medium, is stored thereon with computer program, which is characterized in that the computer program The step of data cache method provided in any embodiment of the present invention is provided when being executed by processor.
Above-mentioned data cache method, device, server and storage medium encode the business datum got, lead to Cross coding and obtain pixel-parameters array, pixel-parameters in array of pixels draw caching picture, will caching picture correspond to Service identification is stored in spatial cache.By being depicted as and caching picture by data cached coding, caching image cache is existed Spatial cache avoids the leakage of business datum, improves the cached security of business datum.
Description of the drawings
Fig. 1 is the applied environment figure of data cache method in one embodiment;
Fig. 2 is the flow diagram of data cache method in one embodiment;
Fig. 3 is flow diagram the step of caching picture pixels size is determined in one embodiment;
The flow diagram of the step of Fig. 4 is in one embodiment to terminal return cache picture;
Fig. 5 is the flow diagram for the step of recycling notice is forced in generation in one embodiment;
Fig. 6 is the structure diagram of data buffer storage device in one embodiment;
Fig. 7 is the structure diagram of dimension of picture determining module in one embodiment;
Fig. 8 is the structure diagram of data buffer storage device in another embodiment;
Fig. 9 is the structure diagram of the server in data buffering system in one embodiment.
Specific embodiment
In order to make the purpose , technical scheme and advantage of the present invention be clearer, with reference to the accompanying drawings and embodiments, it is right The present invention is further elaborated.It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, and It is not used in the restriction present invention.
Fig. 1 is the applied environment figure of data cache method in one embodiment.With reference to Fig. 1, the data cache method application In data buffering system.Data buffering system includes terminal 110 and server 120, and wherein terminal 110 passes through network and server 120 connections.Terminal 110 can be fixed terminal or mobile terminal, and fixed terminal can be specifically printer, scanner and monitoring At least one of device, mobile terminal can be specifically that tablet computer, smart mobile phone, personal digital assistant and number are magazine It is at least one.
As shown in Fig. 2, in one embodiment, providing a kind of data cache method, the present embodiment is applied in this way Server 120 in Fig. 1 comes for example, this method specifically includes the following contents:
S202 parses the business datum cache request received, and business datum cache request is extracted by parsing In business datum and service identification.
Specifically, it shows the business page in terminal 110, periodically obtains business datum and service identification, the industry that will be got Business data and service identification are sent to server 120.
In one embodiment, terminal 110 periodically obtains business datum and service identification in the business page of display, Business datum cache request is generated according to the business datum and service identification got, business datum cache request is sent to clothes Business device 120.Server 120 parses the business datum cache request received, and extracting business datum by parsing caches Business datum and service identification in request.
S204, the character digit obtained according to pre-set image parameter digit and service data statistics determine caching picture pixels Size.
Specifically, server 120 is after business datum is got, the character digit of service data statistics, by what is counted on Character digit divided by pre-set image parameter digit obtain caching picture pixels size.
In one embodiment, caching picture pixels size includes caching picture pixels width and caching picture pixels are high Degree, caching picture pixels height are preset value.Server 120 is by the character digit of service data statistics divided by pre-set image parameter Digit obtains caching picture pixels width.
For example, set pre-set image parameter as RGBA forms, RGBA is that represent Red (red), Green (green Color), Blue (blue) and Alpha (transparency or opacity), then pre-set image parameter digit is 4.It is high to cache picture pixels It spends to be preset as 1 pixel, business datum is " 12345678 ", and the character digit of the business datum of statistics is 8, will be with 8 divided by 4 It is caching picture pixels width to obtain 2,2.
S206 encodes business datum to obtain pixel-parameters array.
Specifically, server 120 encodes character each in business datum, is converted each character by encoding For respective pixel parameter, pixel-parameters array is obtained according to the corresponding pixel-parameters of each character.
For example, business datum " 12345678 " is encoded, by encoding to each word in business datum Token encodes, and " 51 " are obtained to " 1 " coding, and " 102 " are obtained to " 2 " coding, obtains " 153 " to " 3 " coding, " 4 " are encoded " 204 " are obtained, " 55 " are obtained to " 5 " coding, " 106 " are obtained to " 6 " coding, " 157 " are obtained to " 7 " coding, " 8 " are encoded To " 208 ", then the value of the pixel-parameters encoded between 0-255, obtained pixel-parameters array for 51,102,153, 204,55,106,157,208 }.
S208 reads pixel-parameters from pixel-parameters array in order according to pre-set image parameter digit.
Specifically, server 120 reads respective counts from pixel-parameters array in order according to pre-set image parameter digit The pixel-parameters of amount.
For example, RGBA format-pattern parameters digit be 4, according in pixel-parameters array array sequence by preceding to Afterwards, 4 pixel-parameters are read.Pixel-parameters array is { 51,102,153,204,55,106,157,208 }, read 51,102, 153,204 }, with the RGBA pixel-parameters of { 51,102,153,204 } that read as first pixel, according to what is read { 51,102,153,204 } first pixel is built, then reads { 55,106,157,208 }, with { 55,106,157,208 } conduct The RGBA pixel-parameters of second pixel build second pixel, according to first according to { 55,106,157,208 } read A pixel and second pixel obtain caching picture.
S210, according to the pixel-parameters generation read and the caching matched caching picture of picture pixels size, by business Mark is added in caching picture.
Specifically, server 120 reads the pixel-parameters with pre-set image parameter digit equal amount every time, according to each The pixel-parameters of reading build a pixel, are formed according to the pixel of structure and schemed with caching the matched caching of picture pixels size Piece, and be added to service identification as picture identification in caching picture.
S212 inquires spatial cache corresponding with the service identification, and the caching picture added with service identification is stored To the spatial cache inquired.
Specifically, server 120 is inquired spatial cache corresponding with service identification, will be cached after generation caches picture Picture is corresponding with service identification to be stored to the spatial cache inquired.
In one embodiment, service identification is added in caching picture by server 120, and inquiry is corresponding with service identification Spatial cache, the caching image cache of service identification will be added to the spatial cache inquired.
In the present embodiment, the business datum got is encoded, pixel-parameters array is obtained by coding, according to picture Pixel-parameters in prime number group draw caching picture, and caching picture is corresponded to and is stored in spatial cache with service identification.Pass through Data cached coding is depicted as and cache picture, image cache will be cached in spatial cache, avoid the leakage of business datum, Improve the cached security of business datum.
As shown in figure 3, in one embodiment, S204 specifically includes the step of determining caching picture pixels size, the step Suddenly the following contents is specifically included:
S302 obtains cipher mode corresponding with service identification.
Specifically, the corresponding cipher mode of each service identification is stored in server 120.Server 120 adds storage Cipher mode corresponding with service identification is inquired in close mode, obtains the cipher mode inquired.
S304 is encrypted business datum according to the cipher mode got to obtain business datum ciphertext.
Specifically, server 120 is after the corresponding cipher mode of service identification is got, using the cipher mode got Business datum is encrypted, obtains business datum ciphertext.
S306, the character digit of service data statistics ciphertext.
Specifically, server 120 is to by encrypting obtained business datum ciphertext, the character bit of service data statistics ciphertext Number.
S308 determines caching picture pixels size according to the character digit and pre-set image parameter digit that count on.
Specifically, server 120 is by the character digit counted on divided by pre-set image parameter digit, if obtained quotient is whole Number, then round numbers is the caching picture pixels width cached in picture pixels size;If obtained quotient has remainder, rounding adds 1 Obtain caching picture pixels width;Picture pixels width and preset picture pixels height according to being calculated determine caching figure Piece Pixel Dimensions.
For example, if business datum ciphertext is " 12345678 ", pre-set image parameter digit is 4, then server The character digit of the 120 business datum ciphertexts counted on is 8, then obtains 2 with 8 divided by 4, then caches slow in picture pixels size It is 2 to deposit picture pixels width;If business datum ciphertext is " 123456789 ", pre-set image parameter digit is 4, then services The character digit for the business datum ciphertext that device 120 counts on is 9, then obtains more than 21 with 9 divided by 4, then cache picture pixels size In caching picture pixels width be 2 plus 1 be 3.
In the present embodiment, according to the corresponding cipher mode of service identification, business datum is encrypted to obtain business datum Ciphertext determines caching picture pixels size, so that business datum ciphertext is converted to according to the character digit of business datum ciphertext Match with caching picture pixels size, by the safety that business datum is improved to business datum encryption.
In one embodiment, S212 specifically includes the following contents:Inquiry whether there is and business mark in spatial cache Know corresponding caching picture;If in the presence of the caching picture that Delete query arrives is corresponding with service identification by the caching picture of generation Storage.
Specifically, server 120 is inquired in spatial cache with the presence or absence of caching picture corresponding with service identification, slow It deposits and caching picture corresponding with service identification is inquired in space, then delete the caching picture inquired from spatial cache, It stores the caching picture of generation is corresponding with service identification to spatial cache;If not inquired in spatial cache and service identification Corresponding caching picture is then stored the caching picture of generation is directly corresponding with service identification to spatial cache.
As shown in figure 4, in one embodiment, the step of specifically further including to terminal return cache picture after S212, The step specifically includes the following contents:
S402 receives the data cached acquisition request that terminal is sent.
Specifically, the data cached acquisition instruction that terminal 110 triggers in the business page is detected, is obtained according to data cached Instruction fetch obtains service identification in the business page, is asked according to data cached obtain of service identification generation, by data cached acquisition Request is sent to server 120.Server 120 receives the data cached acquisition request that terminal 110 is sent.
S404, according to the data cached service identification obtained in request query caching picture from spatial cache.
Specifically, server 120 to data cached obtain to after data cached acquisition request is received, asking to solve Analysis by parsing service identification in the data cached acquisition request of extraction, is looked into according to the service identification extracted from spatial cache Ask caching picture.
The caching picture inquired is back to terminal by S406.
Specifically, server 120, will be in spatial cache by parsing the data cached terminal iidentification obtained in request of extraction In the caching picture that inquires be sent to the corresponding terminal 110 of the terminal iidentification extracted.
In the present embodiment, after the data cached acquisition request of terminal transmission is received, asked according to data cached obtain Middle service identification accurate query caching picture in spatial cache, is back to terminal by the caching picture inquired, improves and look into Ask the accuracy of caching picture.
In one embodiment, the following contents is specifically included after S212:Receive the service ending notice that terminal is sent;It carries Take the service identification in service ending notice;Caching picture corresponding with the service identification extracted is deleted from spatial cache.
Specifically, terminal 110 is in the service ending in detecting the business page, obtains service identification, according to getting Service identification generation service ending notice, by service ending notice be sent to server 120.Server 120 is receiving industry Be engaged in end notification after, to service ending notice parse, by parsing extract service identification, in spatial cache inquiry with The corresponding caching picture of business extracted deletes the caching picture inquired.
In the present embodiment, after the service ending notice of terminal transmission is received, by spatial cache and service ending The corresponding caching picture of service identification is deleted in notice, the relevant caching picture of institute's winding-up is avoided to occupy caching for a long time empty Between situation, improve spatial cache buffer efficiency.
As shown in figure 5, in one embodiment, data cache method specifically further includes the step that recycling notice is forced in generation Suddenly, which specifically includes the following contents:
S502 periodically obtains each spatial cache and identifies corresponding space occupancy rate.
Specifically, server 120 identifies multiple spatial caches the space occupancy rate progress of corresponding spatial cache Monitoring, the space occupancy rate of regular each spatial cache, the space occupancy rate got are right respectively with each spatial cache mark Each spatial cache got every time is identified corresponding space occupancy rate and stored by the space occupancy rate answered.
S504, it is more than number to count each spatial cache and identify corresponding space occupancy rate more than default occupancy.
Specifically, server 120 each spatial cache of storage is identified corresponding space occupancy rate and default occupancy into Row compares, and it is more than number to obtain each spatial cache by comparing and identify corresponding space occupancy rate more than default occupancy.
S506 determines that it is more than the spatial cache mark corresponding to number to be more than preset times.
Specifically, server 120 by each spatial cache mark it is corresponding compare more than number with preset times, pass through ratio It is more than the spatial cache mark that number is more than preset times compared with screening, it is empty to be identified as determining caching with the spatial cache filtered out Between identify.
S508 identifies corresponding spatial cache to determining spatial cache and carries out pressure recycling.
Specifically, the inquiry of server 120 and the determining corresponding spatial cache of spatial cache mark, will be in spatial cache Caching picture is deleted, and empties spatial cache, after server 120 empties spatial cache, is corresponded to according to the spatial cache emptied Each spatial cache mark generation clear space notice, with force recycling spatial cache.
In one embodiment, the record of server 120 forces the spatial cache mark of the spatial cache of recycling, recovery time With recycling capacity, cache garbage collection daily record is generated according to the spatial cache of record mark, recovery time and recycling capacity.Terminal 110 Can daily record be recycled with query caching.
In the present embodiment, periodically obtain each spatial cache and identify corresponding space occupancy rate, identified according to each spatial cache Space occupancy rate determine the higher spatial cache of long term space occupancy, for the higher spatial cache of long term space occupancy It is emptied, spatial cache is avoided to be occupied for a long time, pressure recycling is carried out to spatial cache, so as to improve the slow of spatial cache Deposit efficiency.
In one embodiment, data buffer storage device can also be applied in terminal 110, and application is equipped in terminal 110 Program, terminal 110 obtains the application identities being clicked corresponding to icon when the icon for detecting level of application is clicked, right The corresponding network view of application identities is initialized, when network view is initialized, to the corresponding network of application identities Data encryption function and data decryption function are injected in view, is obtained by the corresponding application program of application identities from server 120 Business datum is taken, the data encryption function of injection is called from the corresponding network view of application identities, is added using the data of calling Close function treat it is data cached be encrypted to obtain data cached ciphertext, caching picture is generated according to data cached ciphertext, to slow Picture is deposited to be cached.
In one embodiment, terminal 110 detects the data cached acquisition instruction triggered in the page of application program, carries The service identification in data cached acquisition instruction is taken, is inquired from the corresponding local cache space of application identities according to service identification Picture is cached, caching picture is parsed to obtain pixel-parameters array, pixel-parameters array is parsed to obtain caching number According to ciphertext, call injection the data cached ciphertext of data deciphering function pair be decrypted to obtain it is data cached.
In one embodiment, the caching picture of generation is being stored in local cache space by terminal 110, if detecting this When the spatial content of ground spatial cache has been expired or residual capacity is less than the data volume of caching picture, caching picture is sent to should With corresponding server 120 is identified, server 120 is made to store spatial cache corresponding to application identities by picture is cached.Wherein, Server 120 caches the caching picture that multiple terminals 110 are sent, in multiple 110 equal accessible services devices 120 of terminal Spatial cache.
As shown in fig. 6, in one embodiment, providing a kind of data buffer storage device 600, which specifically includes in following Hold:Business datum acquisition module 602, dimension of picture determining module 604, array of pixels determining module 606, pixel-parameters read mould Block 608, caching image generating module 610 and caching picture storage module 612.
Business datum acquisition module 602 for being parsed to the business datum cache request received, is carried by parsing Take the business datum and service identification in business datum cache request.
Dimension of picture determining module 604, for the character obtained according to pre-set image parameter digit and service data statistics Digit determines caching picture pixels size.
Array of pixels determining module 606, for being encoded to obtain pixel-parameters array to business datum.
Pixel-parameters read module 608, for being read from pixel-parameters array in order according to pre-set image parameter digit Take pixel-parameters.
Image generating module 610 is cached, for according to the pixel-parameters generation read and caching picture pixels size Service identification is added in caching picture by the caching picture matched.
Picture storage module 612 is cached, for inquiring spatial cache corresponding with service identification, service identification will be added with Caching picture store to the spatial cache inquired.
In the present embodiment, the business datum got is encoded, pixel-parameters array is obtained by coding, according to picture Pixel-parameters in prime number group draw caching picture, and caching picture is corresponded to and is stored in spatial cache with service identification.Pass through Data cached coding is depicted as and cache picture, image cache will be cached in spatial cache, avoid the leakage of business datum, Improve the cached security of business datum.
As shown in fig. 7, in one embodiment, dimension of picture determining module 604 specifically includes the following contents:Cipher mode Acquisition module 604a, business datum encrypting module 604b, character digit statistical module 604c and Pixel Dimensions determining module 604d.
Cipher mode acquisition module 604a, for obtaining cipher mode corresponding with service identification.
Business datum encrypting module 604b, for business datum to be encrypted to obtain industry according to the cipher mode got Business data ciphertext.
Character digit statistical module 604c, for the character digit of service data statistics ciphertext.
Pixel Dimensions determining module 604d, for determining to delay according to the character digit and pre-set image parameter digit that count on Deposit picture pixels size.
In the present embodiment, according to the corresponding cipher mode of service identification, business datum is encrypted to obtain business datum Ciphertext determines caching picture pixels size, so that business datum ciphertext is converted to according to the character digit of business datum ciphertext Match with caching picture pixels size, by the safety that business datum is improved to business datum encryption.
In one embodiment, caching picture storage module 612 is additionally operable in spatial cache inquiry and whether there is and industry Business identifies corresponding caching picture;After caching picture corresponding with service identification is inquired, then Delete query arrives caching figure Piece, by the storage corresponding with service identification of the caching picture of generation.
In one embodiment, data buffer storage device 600 further includes:Caching picture returns to module and is additionally operable to receive terminal hair The data cached acquisition request sent;According to the data cached service identification obtained in request query caching figure from spatial cache Piece;The caching picture inquired is back to terminal.
In the present embodiment, after the data cached acquisition request of terminal transmission is received, asked according to data cached obtain Middle service identification accurate query caching picture in spatial cache, is back to terminal by the caching picture inquired, improves and look into Ask the accuracy of caching picture.
In one embodiment, data buffer storage device 600 further includes:Caching picture deletion module sends for receiving terminal Service ending notice;Extract the service identification in service ending notice;The business mark deleted and extracted from spatial cache Know corresponding caching picture.
In the present embodiment, after the service ending notice of terminal transmission is received, by spatial cache and service ending The corresponding caching picture of service identification is deleted in notice, the relevant caching picture of institute's winding-up is avoided to occupy caching for a long time empty Between situation, improve spatial cache buffer efficiency.
As shown in figure 8, in one embodiment, data buffer storage device 600 specifically further includes the following contents:Occupancy obtains Recycling module 720 is forced in module 614, number statistical module 616, space identification determining module 618 and space.
Occupancy acquisition module 614 identifies corresponding space occupancy rate for periodically obtaining each spatial cache.
Number statistical module 616, it is more than the super of default occupancy to count each spatial cache and identify corresponding space occupancy rate Cross number.
Space identification determining module 618 determines that it is more than the spatial cache mark corresponding to number to be more than preset times.
Recycling module 720 is forced in space, is forced back for identifying corresponding spatial cache to determining spatial cache It receives.
In the present embodiment, periodically obtain each spatial cache and identify corresponding space occupancy rate, identified according to each spatial cache Space occupancy rate determine the higher spatial cache of long term space occupancy, for the higher spatial cache of long term space occupancy It is emptied, spatial cache is avoided to be occupied for a long time, pressure recycling is carried out to spatial cache, so as to improve the slow of spatial cache Deposit efficiency.
In one embodiment, provide a kind of computer equipment, the computer equipment can be server or Mobile terminal.When the computer equipment is server, internal structure chart can be as shown in Figure 9.The computer equipment includes Processor, memory and the network interface connected by system bus.Wherein, the processor of the computer equipment is based on providing Calculation and control ability.The memory of the computer equipment includes non-volatile memory medium, built-in storage.The non-volatile memories Media storage has operating system and computer program.The built-in storage is operating system and calculating in non-volatile memory medium The operation of machine program provides environment.The network interface of the computer equipment is used to communicate by network connection with external terminal. To realize a kind of data cache method when the computer program is executed by processor.It will be understood by those skilled in the art that in Fig. 9 The structure shown only with the block diagram of the relevant part-structure of application scheme, does not form and application scheme is applied The restriction of computer equipment thereon, specific computer equipment can be included than components more or fewer shown in figure, It either combines certain components or is arranged with different components.
The embodiment of the present invention proposes a kind of server, which includes a series of computers being cached on memory Program when the computer program is executed by processor, can realize the data cache method that various embodiments of the present invention propose. In some embodiments, the specific operation realized based on the computer program each section.
In one embodiment, server includes memory, processor and is stored on the memory and can be described The computer program run on processor, the processor realize following steps when performing the computer program:To receiving Business datum cache request parsed, pass through parsing extract business datum cache request in business datum and business mark Know;The character digit obtained according to pre-set image parameter digit and service data statistics determines caching picture pixels size;To industry Business data are encoded to obtain pixel-parameters array;It is read from pixel-parameters array in order according to pre-set image parameter digit Pixel-parameters;According to the pixel-parameters generation read and the caching matched caching picture of picture pixels size, by service identification Added in caching picture;Inquiry spatial cache corresponding with service identification, the caching picture added with service identification is stored To the spatial cache inquired.
In one embodiment, the character digit obtained according to pre-set image parameter digit and service data statistics determines to delay Picture pixels size is deposited, including:Obtain cipher mode corresponding with service identification;According to the cipher mode got to business number According to being encrypted to obtain business datum ciphertext;The character digit of service data statistics ciphertext;According to the character digit that counts on and Pre-set image parameter digit determines caching picture pixels size.
In one embodiment, spatial cache corresponding with service identification is inquired, by the caching figure added with service identification Piece is stored to the spatial cache inquired, including:Inquiry is schemed with the presence or absence of caching corresponding with service identification in spatial cache Piece;If inquire in the presence of caching picture corresponding with service identification, caching picture that Delete query arrives, by the caching of generation Picture storage corresponding with service identification.
In one embodiment, spatial cache corresponding with service identification is inquired, by will cache added with service identification Picture is stored corresponding to service identification to the spatial cache inquired, and the processor is gone back when performing the computer program Realize following steps:Receive the data cached acquisition request that terminal is sent;According to the data cached service identification obtained in request The query caching picture from spatial cache;The caching picture inquired is back to terminal.
In one embodiment, spatial cache corresponding with service identification is inquired, by will cache added with service identification Picture is stored corresponding to service identification to the spatial cache inquired, and the processor performs real during the computer program Existing following steps:Receive the service ending notice that terminal is sent;Extract the service identification in service ending notice;From spatial cache It is middle to delete caching picture corresponding with the service identification extracted.
In one embodiment, following steps are realized when the processor performs the computer program:It periodically obtains each Spatial cache identifies corresponding space occupancy rate;It is more than default occupancy to count each spatial cache and identify corresponding space occupancy rate It is more than number;Determine that it is more than the spatial cache mark corresponding to number to be more than preset times;To determining spatial cache mark Know corresponding spatial cache and carry out pressure recycling.
In the present embodiment, the business datum got is encoded, pixel-parameters array is obtained by coding, according to picture Pixel-parameters in prime number group draw caching picture, and caching picture is corresponded to and is stored in spatial cache with service identification.Pass through Data cached coding is depicted as and cache picture, image cache will be cached in spatial cache, avoid the leakage of business datum, Improve the cached security of business datum.
A kind of computer readable storage medium, is stored thereon with computer program, and the computer program is held by processor During row so that the processor performs following steps:Obtain business datum and service identification;According to the corresponding character of business datum Digit and pre-set image parameter digit determine caching picture pixels size;Business datum is encoded to obtain pixel-parameters number Group;Pixel-parameters are read from pixel-parameters array according to pre-set image parameter digit;It is generated according to the pixel-parameters read With caching the matched caching picture of picture pixels size;Caching picture is stored corresponding to service identification to spatial cache.
In one embodiment, the character bit obtained according to pre-set image parameter digit and service data statistics determines to cache Picture pixels size, including:Obtain cipher mode corresponding with service identification;According to the cipher mode got to business datum It is encrypted to obtain business datum ciphertext;The character digit of service data statistics ciphertext;According to the character digit counted on and in advance If image parameter digit determines caching picture pixels size.
In one embodiment, spatial cache corresponding with service identification is inquired, by the caching figure added with service identification Piece is stored to the spatial cache inquired, including:Inquiry is schemed with the presence or absence of caching corresponding with service identification in spatial cache Piece;If inquire in the presence of caching picture corresponding with service identification, caching picture that Delete query arrives, by the caching of generation Picture storage corresponding with service identification.
In one embodiment, spatial cache corresponding with service identification is inquired, by will cache added with service identification Picture is stored corresponding to service identification to the spatial cache inquired, and the processor also realizes following steps:It receives eventually The data cached acquisition request that end is sent;According to the data cached service identification obtained in request query caching from spatial cache Picture;The caching picture inquired is back to terminal.
In one embodiment, spatial cache corresponding with service identification is inquired, by will cache added with service identification Picture is stored corresponding to service identification to the spatial cache inquired, and the processor also realizes following steps:It receives eventually The service ending notice that end is sent;Extract the service identification in service ending notice;It deletes and extracts from spatial cache The corresponding caching picture of service identification.
In one embodiment, the processor also realizes following steps:It is corresponding periodically to obtain each spatial cache mark Space occupancy rate;It is more than number to count each spatial cache and identify corresponding space occupancy rate more than default occupancy;It determines big In preset times be more than corresponding to number spatial cache mark;Determining spatial cache is identified corresponding spatial cache into Row forces recycling.
In the present embodiment, the business datum got is encoded, pixel-parameters array is obtained by coding, according to picture Pixel-parameters in prime number group draw caching picture, and caching picture is corresponded to and is stored in spatial cache with service identification.Pass through Data cached coding is depicted as and cache picture, image cache will be cached in spatial cache, avoid the leakage of business datum, Improve the cached security of business datum.
One of ordinary skill in the art will appreciate that realizing all or part of flow in above-described embodiment method, being can be with Relevant hardware is instructed to complete by computer program, which can be cached in a computer-readable storage and be situated between In matter, the program is when being executed, it may include such as the flow of the embodiment of above-mentioned each method.Wherein, aforementioned storage medium can be The non-volatile memory mediums such as magnetic disc, CD, read-only cache memory (Read-Only Memory, ROM).
Each technical characteristic of embodiment described above can be combined arbitrarily, to make description succinct, not to above-mentioned reality It applies all possible combination of each technical characteristic in example to be all described, as long as however, the combination of these technical characteristics is not deposited In contradiction, it is all considered to be the range of this specification record.
Embodiment described above only expresses the several embodiments of the present invention, and description is more specific and detailed, but simultaneously It cannot therefore be construed as limiting the scope of the patent.It should be pointed out that those of ordinary skill in the art are come It says, without departing from the inventive concept of the premise, various modifications and improvements can be made, these belong to the protection of the present invention Range.Therefore, the protection domain of patent of the present invention should be determined by the appended claims.

Claims (10)

1. a kind of data cache method, which is characterized in that the method includes:
The business datum cache request received is parsed, the business number in business datum cache request is extracted by parsing According to and service identification;
The character digit obtained according to pre-set image parameter digit and service data statistics determines caching picture pixels size;
The business datum is encoded to obtain pixel-parameters array;
Pixel-parameters are read from the pixel-parameters array according to the pre-set image parameter digit in order;
According to the pixel-parameters generation read and the caching matched caching picture of picture pixels size, by the business mark Know and be added in caching picture;
Inquiry spatial cache corresponding with the service identification, the caching picture added with service identification is stored to inquiry The spatial cache arrived.
It is 2. according to the method described in claim 1, it is characterized in that, described according to pre-set image parameter digit and statistical service number Caching picture pixels size is determined according to obtained character digit, including:
Obtain cipher mode corresponding with the service identification;
The business datum is encrypted according to the cipher mode got to obtain business datum ciphertext;
Count the character digit of the business datum ciphertext;
Character digit and pre-set image parameter digit according to counting on determine caching picture pixels size.
3. according to the method described in claim 2, it is characterized in that, the inquiry is corresponding with the service identification to cache sky Between, the caching picture added with service identification is stored to the spatial cache inquired, including:
Inquiry is with the presence or absence of caching picture corresponding with the service identification in spatial cache;
If in the presence of the caching picture that Delete query arrives, by the storage corresponding with the service identification of the caching picture of generation.
4. according to the method described in claim 3, it is characterized in that, the inquiry is corresponding with the service identification to cache sky Between, by added with service identification by it is described caching picture corresponding to the service identification store to the spatial cache inquired it Afterwards, including:
Receive the data cached acquisition request that terminal is sent;
According to the data cached service identification obtained in request query caching picture from the spatial cache;
The caching picture inquired is back to the terminal.
5. according to the method described in claim 1, it is characterized in that, the inquiry is corresponding with the service identification to cache sky Between, by added with service identification by it is described caching picture corresponding to the service identification store to the spatial cache inquired it Afterwards, including:
Receive the service ending notice that terminal is sent;
Extract the service identification in the service ending notice;
Caching picture corresponding with the service identification extracted is deleted from the spatial cache.
6. method according to any one of claims 1-5, which is characterized in that the method further includes:
It periodically obtains each spatial cache and identifies corresponding space occupancy rate;
It is more than number to count each spatial cache and identify corresponding space occupancy rate more than default occupancy;
Determine that it is more than the spatial cache mark corresponding to number to be more than preset times;
Corresponding spatial cache is identified to determining spatial cache and carries out pressure recycling.
7. a kind of data buffer storage device, which is characterized in that described device includes:
Business datum acquisition module, for being parsed to the business datum cache request received, by parsing extraction business Business datum and service identification in data buffer storage request;
Dimension of picture determining module, the character digit for being obtained according to pre-set image parameter digit and service data statistics determine Cache picture pixels size;
Array of pixels determining module, for being encoded to obtain pixel-parameters array to the business datum;
Pixel-parameters read module, for being read from the pixel-parameters array in order according to the pre-set image parameter digit Take pixel-parameters;
Image generating module is cached, for matched according to the pixel-parameters generation read and the caching picture pixels size Picture is cached, the service identification is added in caching picture;
Picture storage module is cached, it, will be added with service identification for inquiring spatial cache corresponding with the service identification The caching picture is stored to the spatial cache inquired.
8. device according to claim 7, which is characterized in that the dimension of picture determining module includes:
Cipher mode acquisition module, for obtaining cipher mode corresponding with the service identification;
Business datum encrypting module, for the business datum to be encrypted to obtain business number according to the cipher mode got According to ciphertext;
Character digit statistical module, for counting the character digit of the business datum ciphertext;
Pixel Dimensions determining module, for determining caching picture picture according to the character digit and pre-set image parameter digit that count on Plain size.
9. a kind of server, the server includes memory, processor and is stored on the memory and can be at the place The computer program run on reason device, the processor realize any one of claim 1 to 6 when performing the computer program The step of the method.
10. a kind of computer readable storage medium, is stored thereon with computer program, which is characterized in that the computer program The step of method according to any one of claims 1 to 6 is realized when being executed by processor.
CN201711319134.XA 2017-12-12 2017-12-12 Data caching method, device, server and storage medium Active CN108259563B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711319134.XA CN108259563B (en) 2017-12-12 2017-12-12 Data caching method, device, server and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711319134.XA CN108259563B (en) 2017-12-12 2017-12-12 Data caching method, device, server and storage medium

Publications (2)

Publication Number Publication Date
CN108259563A true CN108259563A (en) 2018-07-06
CN108259563B CN108259563B (en) 2021-01-12

Family

ID=62722526

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711319134.XA Active CN108259563B (en) 2017-12-12 2017-12-12 Data caching method, device, server and storage medium

Country Status (1)

Country Link
CN (1) CN108259563B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109614347A (en) * 2018-10-22 2019-04-12 中国平安人寿保险股份有限公司 Processing method, device, storage medium and the server of multi-level buffer data
CN110413644A (en) * 2019-06-17 2019-11-05 中国平安人寿保险股份有限公司 A kind of data cache method, electronic device and computer readable storage medium
CN111753228A (en) * 2019-09-24 2020-10-09 北京京东尚科信息技术有限公司 Data request method and device, computer readable medium and electronic equipment
CN113254480A (en) * 2020-02-13 2021-08-13 ***通信集团广东有限公司 Data query method and device
CN115174757A (en) * 2022-06-08 2022-10-11 广州鲁邦通智能科技有限公司 Form information submitting method, reading method and processing system

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030105879A1 (en) * 2001-11-30 2003-06-05 Erlend Olson Wireless network architecture and method
CN103246830A (en) * 2013-04-28 2013-08-14 北京小米科技有限责任公司 Encrypting processing method, encrypting processing device, deciphering processing method and deciphering processing device of client side scripting
CN103701929A (en) * 2014-01-02 2014-04-02 中安消技术有限公司 Method and device for realizing business data caching
CN105577684A (en) * 2016-01-25 2016-05-11 北京京东尚科信息技术有限公司 Anti-crawling methods, server, client and system
CN105608147A (en) * 2015-12-17 2016-05-25 无锡天脉聚源传媒科技有限公司 Method and device for hiding original addresses of pictures
CN106789856A (en) * 2015-11-25 2017-05-31 阿里巴巴集团控股有限公司 A kind of information coding method, coding/decoding method and device
CN106897141A (en) * 2015-12-21 2017-06-27 北京奇虎科技有限公司 The processing method and processing device of information

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030105879A1 (en) * 2001-11-30 2003-06-05 Erlend Olson Wireless network architecture and method
CN103246830A (en) * 2013-04-28 2013-08-14 北京小米科技有限责任公司 Encrypting processing method, encrypting processing device, deciphering processing method and deciphering processing device of client side scripting
CN103701929A (en) * 2014-01-02 2014-04-02 中安消技术有限公司 Method and device for realizing business data caching
CN106789856A (en) * 2015-11-25 2017-05-31 阿里巴巴集团控股有限公司 A kind of information coding method, coding/decoding method and device
CN105608147A (en) * 2015-12-17 2016-05-25 无锡天脉聚源传媒科技有限公司 Method and device for hiding original addresses of pictures
CN106897141A (en) * 2015-12-21 2017-06-27 北京奇虎科技有限公司 The processing method and processing device of information
CN105577684A (en) * 2016-01-25 2016-05-11 北京京东尚科信息技术有限公司 Anti-crawling methods, server, client and system

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109614347A (en) * 2018-10-22 2019-04-12 中国平安人寿保险股份有限公司 Processing method, device, storage medium and the server of multi-level buffer data
CN109614347B (en) * 2018-10-22 2023-07-21 中国平安人寿保险股份有限公司 Processing method and device for multi-level cache data, storage medium and server
CN110413644A (en) * 2019-06-17 2019-11-05 中国平安人寿保险股份有限公司 A kind of data cache method, electronic device and computer readable storage medium
CN110413644B (en) * 2019-06-17 2023-07-25 中国平安人寿保险股份有限公司 Data caching method, electronic device and computer readable storage medium
CN111753228A (en) * 2019-09-24 2020-10-09 北京京东尚科信息技术有限公司 Data request method and device, computer readable medium and electronic equipment
CN113254480A (en) * 2020-02-13 2021-08-13 ***通信集团广东有限公司 Data query method and device
CN113254480B (en) * 2020-02-13 2024-04-19 ***通信集团广东有限公司 Data query method and device
CN115174757A (en) * 2022-06-08 2022-10-11 广州鲁邦通智能科技有限公司 Form information submitting method, reading method and processing system

Also Published As

Publication number Publication date
CN108259563B (en) 2021-01-12

Similar Documents

Publication Publication Date Title
CN108259563A (en) Data cache method, device, server and storage medium
CN103414840A (en) Data hiding method based on image set
Benedict Improved file security system using multiple image steganography
Bhautmage et al. Advanced video steganography algorithm
Lee et al. An advanced least-significant-bit embedding scheme for steganographic encoding
Meng et al. Coverless video steganography based on maximum DC coefficients
Xu et al. Separable reversible data hiding in encrypted images based on difference histogram modification
Li et al. Reversible data hiding in block compressed sensing images
Debnath et al. An advanced image encryption standard providing dual security: Encryption using hill cipher & RGB image steganography
Cao et al. Separable Reversible Data Hiding in Encrypted VQ‐Encoded Images
Tang et al. A format compliant framework for HEVC selective encryption after encoding
US6023511A (en) Cryptosystem for encrypting digital image or voice file
Vidhya et al. Evaluation and performance analysis of Chinese remainder theorem and its application to lossless image compression
CN108305298A (en) A kind of image based on the only matrix index of number can restore information concealing method
Newman et al. A steganographic embedding undetectable by JPEG compatibility steganalysis
Maheswari et al. Secure layer based compound image compression using XML compression
CN105279728B (en) Pretreated intelligent mobile terminal image latent writing method is encrypted based on secret information
Ramalingam et al. A steganography approach for sequential data encoding and decoding in video images
Yu et al. A Novel Three‐Layer QR Code Based on Secret Sharing Scheme and Liner Code
CN111432242A (en) Encrypted video call method, device, equipment and storage medium
Ashari et al. Image Steganography Analysis Using GOST Algorithm and PRNG Based on LSB.
Akhmametieva Steganalysis of digital contents, based on the analysis of unique color triplets
Yu et al. Reversible data hiding with pixel prediction and additive homomorphism for encrypted image
Banerjee et al. A secure high-capacity video steganography using bit plane slicing through (7, 4) hamming code
Hui et al. A reversible data hiding method for AMBTC compressed image without expansion inside stego format

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
GR01 Patent grant
GR01 Patent grant