CN108810144A - A kind of data transmission method, server and storage medium - Google Patents
A kind of data transmission method, server and storage medium Download PDFInfo
- Publication number
- CN108810144A CN108810144A CN201810610477.XA CN201810610477A CN108810144A CN 108810144 A CN108810144 A CN 108810144A CN 201810610477 A CN201810610477 A CN 201810610477A CN 108810144 A CN108810144 A CN 108810144A
- Authority
- CN
- China
- Prior art keywords
- picture
- data
- heat range
- read
- data transmission
- 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
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/50—Network services
- H04L67/56—Provisioning of proxy services
- H04L67/568—Storing data temporarily at an intermediate stage, e.g. caching
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Information Transfer Between Computers (AREA)
Abstract
The present invention provides a kind of data transmission method, server and storage mediums, are related to field of network data transmission technology.The data transmission method receives the data access request that access end is sent first, access request judges whether the access target data of the access end are picture based on the data, when to be, judge whether the picture is hot spot data, when the picture is hot spot data, the picture read from data buffer zone corresponding with the Heat range is sent to the access end by the Heat range for obtaining the picture.Data transmission method provided by the invention is stored in data buffer zone by that will be divided into the picture of hot spot data, and the picture is read from the data buffer zone, reduces data call and expends the time, improves data transmission efficiency.
Description
Technical field
The present invention relates to field of network data transmission technology, in particular to a kind of data transmission method, server and
Storage medium.
Background technology
With the fast development of science and technology and social economy, more and more electronic equipments have network communicating function,
Data interaction can be carried out with same type or other kinds of electronic equipment, to enable multiple electronic equipments to cooperate.In the least
Without query, nowadays network the most universal is exactly internet, and the equipment being connected into however as internet is increasing, while each
Demand of the user to flow is increasing, and the transmission speed of internet and the reduction of transmission reliability are increasingly becoming one can not
Ignorance problem.In the architecture of internet, congestion is its intrinsic attribute, and in network congestion, each electronics is set
Data transmission bauds between standby will be extremely restricted, even occur the data such as packet loss can not accurate delivery to purpose equipment
Situation.
The event of above-mentioned network congestion or other network data transmission limited speeds occurs, can influence user terminal read or
Upload data, the inspection data transmission work that especially this is related to public life and public safety problem to power grid inspection
Generate significant impact makes inspection data (especially larger image data) not transmitted and be analyzed rapidly by network,
Non- timely processing electric network fault can even be caused and then influence the consequence of public electricity-using and public safety.
Invention content
In view of this, the embodiment of the present invention is designed to provide a kind of data transmission method, server and storage medium,
To solve the above problems.
In a first aspect, an embodiment of the present invention provides a kind of data transmission method, the data transmission method receives first
The data access request that access end is sent, based on the data access request judge the access end access target data whether
Judge whether the picture is hot spot data when to be for picture, when the picture is hot spot data, obtains the figure
The picture read from data buffer zone corresponding with the Heat range is sent to the access by the Heat range of piece
End.
Synthesis in the access request based on the data in a first aspect, judge whether the access target data of user are figure
Before piece, the data transmission method further includes:Obtain the reading times that the picture is read in first time interval;Base
In the Heat range for being read number and determining the picture;The picture is stored in corresponding with the Heat range
Data buffer zone.
It is comprehensive in a first aspect, described based on the Heat range for being read number and determining the picture, including:Sentence
Whether the disconnected number that is read is more than first threshold and less than second threshold;When to be, the temperature etc. of the picture is determined
Grade is the first Heat range;When to be no, judge the picture is read whether number is more than second threshold.It is read described
When number being taken to be more than second threshold, determine that the Heat range of the picture is the second temperature etc. higher than first Heat range
Grade.It is described that the picture is stored in data buffer zone corresponding with the Heat range, including:It is described first in the picture
When Heat range, by picture deposit Redis cachings;When the picture is second Heat range, by the picture
It is stored in local cache.
Picture deposit Redis is cached it by synthesis in a first aspect, when the picture is first Heat range
Afterwards, the data transmission method further includes:Judge that the picture is read whether number is more than third in the second time interval
Threshold value;When to be, the Heat range of the picture is updated to second Heat range from the first Heat range, and by institute
It states picture and is stored in the local cache.When the picture is second Heat range, the picture is stored in local cache
Later, the data transmission method further includes:Judge that the picture is read whether number is more than the in the second time interval
Four threshold values are simultaneously less than third threshold value;When to be, the Heat range of the picture is updated to institute from second Heat range
The first Heat range is stated, and the picture is stored in the Redis and is cached.
It is comprehensive in a first aspect, after the data access request that the reception access end is sent, it is described based on the data
Before access request judges whether the access target data of the access end are picture, the data transmission method further includes:Base
Judge the node residing for the access end in the data access request;According at least two data transport services obtained in real time
The network flow and load state of each data transfer server in device, and each data transfer server and the node
Connection state and transmission range, calculate optimum data transmission server corresponding with the node;Judge that the data pass
Whether defeated server is the optimum data transmission server;When to be, step is executed:Access request is sentenced based on the data
Whether the access target data of the disconnected access end are picture.
Second aspect, an embodiment of the present invention provides a kind of data transfer server, the data transfer server includes
Data transmission module, the data transmission module include request reception unit, type judging unit, hot spot judging unit and data
Transmission unit.The request reception unit is for receiving the data access request that access end is sent.The type judging unit is used
Judge whether the access target data of the access end are picture in access request based on the data.The hot spot judging unit
For the access target data in the access end be picture when, judge whether the picture is hot spot data.Data send single
Member, will be from corresponding with the Heat range for when the picture is hot spot data, obtaining the Heat range of the picture
The picture that data buffer zone is read is sent to the access end.
Comprehensive second aspect, the data transfer server further includes temperature division module, the temperature division module packet
Include reading times acquiring unit, Heat range division unit and data storage cell.The reading times acquiring unit is for obtaining
The reading times for taking the picture to be read in first time interval.The Heat range division unit is used to be based on the quilt
Reading times determine the Heat range of the picture.The data storage cell is used for picture deposit and the heat
Spend the corresponding data buffer zone of grade.
Comprehensive second aspect, the data transfer server further includes grade update module, the grade update module packet
Include reading frequency judging unit, the first updating unit and the second updating unit.The reading frequency judging unit is for judging institute
It states picture and is read whether number is more than third threshold value in the second time interval, be additionally operable to judge the picture in the second time
It is read whether number is more than the 4th threshold value and is less than third threshold value in interval.First updating unit is used in the picture
When being read number in the second time interval more than third threshold value, more from the first Heat range by the Heat range of the picture
It is newly second Heat range, and the picture is stored in the local cache.Second updating unit is used for described
Picture is read number more than the 4th threshold value and when being less than third threshold value in the second time interval, by the temperature etc. of the picture
Grade is updated to first Heat range from second Heat range, and the picture is stored in the Redis and is cached.
Comprehensive second aspect, the data transmission device further includes server se-lection module, the server se-lection module
Including node judging unit, computing unit and optimum data transmission server judging unit.The node judging unit is used for base
Judge the node residing for the access end in the data access request.The computing unit is used for basis and obtains in real time at least
The network flow and load state of each data transfer server in two data transfer servers and each data transmission
The connection state and transmission range of server and the node calculate optimum data transmission service corresponding with the node
Device.The optimum data transmission server judging unit is for judging whether the data transfer server is the optimum data
Transmission server.
The third aspect, the embodiment of the present invention additionally provide a kind of storage medium, computer are stored in the storage medium
Program instruction when the computer program instructions are read and run by a processor, executes the step in the method.
Advantageous effect provided by the invention is:
The present invention provides a kind of data transmission method, server and storage medium, the data transmission method is accessing
According to the Heat range of the picture when target data is picture, directly read from data buffer zone corresponding with the Heat range
The picture is taken, the speed of data screening confirmation is improved, improves data transmission efficiency.Meanwhile the present invention is respectively according to every
The number that is read of pictures is carried out Heat range classification, improves Heat range classification reliability.Further, the number
According to transmission method by the picture deposit Redis cachings of the first Heat range, the picture of the second Heat range is stored in local cache,
Make the reading of hot spot data faster, while the classification of hot spot data makes data buffer zone preferably be utilized, it can be more effective
Improve picture reading speed in ground.The present invention, can also be when default after the classification and storage for carrying out Heat range to the picture
Between to the picture carry out Heat range update, with according to the practical frequency being read of the picture to its Heat range i.e.
Shi Gengxin ensures that the data transmission bauds between data transfer server and access end is more stablized, is more bonded actual transmissions
Demand.In addition, heretofore described data transfer server response access end data transfer request before, can also first determine and
The most fast optimum data transmission server of the corresponding transmission speed of the access end, is carried out by the optimum data transmission server
Data transmission further increases transmission speed.
Other features and advantages of the present invention will be illustrated in subsequent specification, also, partly be become from specification
It is clear that by implementing understanding of the embodiment of the present invention.The purpose of the present invention and other advantages can be by saying what is write
Specifically noted structure is realized and is obtained in bright book, claims and attached drawing.
Description of the drawings
In order to illustrate the technical solution of the embodiments of the present invention more clearly, below will be to needed in the embodiment attached
Figure is briefly described, it should be understood that the following drawings illustrates only certain embodiments of the present invention, therefore is not construed as pair
The restriction of range for those of ordinary skill in the art without creative efforts, can also be according to this
A little attached drawings obtain other relevant attached drawings.
Fig. 1 is a kind of flow chart for data transmission method that first embodiment of the invention provides;
Fig. 2 is the flow chart that a kind of Heat range that first embodiment of the invention provides determines step;
Fig. 3 is a kind of module map for data transfer server that second embodiment of the invention provides;
Fig. 4 shows a kind of structure diagram for the electronic equipment 200 that can be applied in the embodiment of the present application.
Icon:100- data transfer servers;110- data transmission modules;120- temperature division modules;130- grades are more
New module;140- server se-lection modules;200- electronic equipments;201- memories;202- storage controls;203- processors;
204- Peripheral Interfaces;205- input-output units;206- audio units;207- display units.
Specific implementation mode
Below in conjunction with attached drawing in the embodiment of the present invention, technical solution in the embodiment of the present invention carries out clear, complete
Ground describes, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.Usually exist
The component of the embodiment of the present invention described and illustrated in attached drawing can be arranged and be designed with a variety of different configurations herein.Cause
This, the detailed description of the embodiment of the present invention to providing in the accompanying drawings is not intended to limit claimed invention below
Range, but it is merely representative of the selected embodiment of the present invention.Based on the embodiment of the present invention, those skilled in the art are not doing
The every other embodiment obtained under the premise of going out creative work, shall fall within the protection scope of the present invention.
It should be noted that:Similar label and letter indicate similar terms in following attached drawing, therefore, once a certain Xiang Yi
It is defined, then it further need not be defined and explained in subsequent attached drawing in a attached drawing.Meanwhile the present invention's
In description, term " first ", " second " etc. are only used for distinguishing description, are not understood to indicate or imply relative importance.
First embodiment
Through the applicant the study found that since the universal and electronic equipment of network is increased, people want power reliability
It asks and is gradually increased, and existing many microelectronic products are even more to have higher demand to various aspects such as power qualities.With state
The interior growing number of machine in system power line road patrols operation normalization, and traditional photo analysis mode cannot meet electric system and work as
Preceding increasingly increased photo analysis demand.Conventional photo analysis is that unification is carried out by staff, and utilizes machine vision
Identification technology realizes polling transmission line image deflects hidden danger automatic identification, it is possible to reduce a line O&M teams and groups are in photo analysis side
The labour in face puts into, and improves the accuracy rate and efficiency of inspection.In the Machine Vision Recognition Technology pair using artificial intelligence platform
Before photo carries out analysis and identification, needs through crowdsourcing platform to be that artificial intelligent platform collects defect sample library, assist artificial intelligence
Platform carries out machine learning training;Analysis and identification is carried out to photo in the Machine Vision Recognition Technology using artificial intelligence platform
Afterwards, it is also necessary to the analysis result of artificial intelligence platform be confirmed and be checked by crowdsourcing platform.But the phase of power grid inspection
It includes a large amount of image data to close data, and transmitted data amount is big, and existing crowdsourcing platform network transmission technology cannot be satisfied electricity
To the high request of volume of transmitted data and data transmission bauds during net inspection.To solve the above-mentioned problems, the present invention first is real
It applies example and provides a kind of data transmission method.
Referring to FIG. 1, Fig. 1 is a kind of flow chart for data transmission method that first embodiment of the invention provides.The number
It is applied to data transfer server according to transmission method, the data transmission method is as follows:
Step S100:Receive the data access request that access end is sent.
Step S200:Access request judges whether the access target data of the access end are picture based on the data.
Step S300:When the access target data are picture, judge whether the picture is hot spot data.
Step S400:The picture be hot spot data when, obtain the Heat range of the picture, will from the temperature
The picture that the corresponding data buffer zone of grade is read is sent to the access end.
For step S100, i.e.,:Receive the data access request that access end is sent, wherein the access end can be meter
Calculation machine, PC server, can also be smart mobile phone, special mobile terminal or other can be carried out with the data transfer server
The terminal device of data transmission.Further, since the operation conditions of network system and public electricity-using and public safety situation are close
Cut phase is closed, therefore in the present embodiment, the safety that the data transfer server should first to the data access request
It is verified, the verification can verify the access end for sending the data access request whether in registering list, may be used also
To be that can ensure data transmission by the way that whether data access request described in key authentication carries correct authentication information or other
The mode of safety.
By taking data transfer server A receives the data access request that mobile phone X and computer Y are sent simultaneously as an example, using
Register list authentication mode when, data transfer server A by the authentication information of mobile phone X and computer Y with registration list into
Row compares, it is found that mobile phone X is registered device, computer Y is unregistered equipment, then data transfer server A and mobile phone X is established
Data connection, the data transfer request of refusal computer Y.
S100 is executed the step, next should execute step S200, i.e.,:Described in access request judges based on the data
Whether the access target data of access end are picture.Due to that may be transmitted between the data transfer server and the access end
Data include picture, word and other data types, wherein passed between the access end and the data transfer server
Throughput rate and the maximum generally picture of transmission frequency, while the size of picture is considerably beyond other data types such as common language,
Therefore the data transfer server can parse it after receiving the data access request, obtain the access end
Access target data data type, and the data type of the access target data be picture when execute step S300,
Corresponding data are transferred directly to the access end when the data type of the access target data is not picture.
Continue by taking data transfer server A and mobile phone X that data connection has been established as an example, data transfer server A opponent
The data access request of machine X learns that the access target data of mobile phone X are picture 1 and daily record 2 after being parsed, judge that picture 1 is
Picture/mb-type data, daily record 2 is not is picture/mb-type data, then daily record 2 is directly sent to mobile phone X by data transfer server A,
Temporarily picture 1 is not sent and executes step S300.
Next the step of according to the present embodiment, should execute step S300, i.e.,:It is picture in the access target data
When, judge whether the picture is hot spot data.As an implementation, judging whether the picture is hot spot data
Before, the picture in database should also be carried out Heat range division by the data transmission method, execute step:Obtain the figure
The reading times that piece is read in first time interval;Based on the temperature etc. for being read number and determining the picture
Grade;The picture is stored in data buffer zone corresponding with the Heat range.Wherein, hot spot data is divided into different temperatures
Grade, and picture is stored in data buffer zone corresponding with its Heat range, resource is more reasonably utilized, picture transfer is made
It is more efficient.Optionally, the first time interval can be arranged as the case may be, such as half an hour, two hours, one day
Even the longer time, the first time interval is shorter, the Heat range of picture divide it is more accurate with it is reasonable.
Referring to FIG. 2, Fig. 2 is the flow chart that a kind of Heat range that first embodiment of the invention provides determines step, institute
It states Heat range and determines that step is specific as follows:
Step S10:It is read whether number is more than first threshold and is less than second threshold described in judgement;When to be, hold
Row step S20;When to be no, step S30 is executed.
Step S20:Determine that the Heat range of the picture is the first Heat range, by picture deposit Redis cachings.
Step S30:It is read whether number is more than second threshold described in judgement, when to be, executes step S40.
Step S40:Determine that the Heat range of the picture is the second Heat range higher than first Heat range, it will
The picture is stored in local cache.
For step S10 to step S40, the size of the first threshold and the second threshold can be according to described first
Interval time and specific implementation situation are configured and adjust.The local cache refers to drawing the physical memory of client computer local
A part of space is separated to be used for buffering the data that client computer is written back to server, since local cache is being stored in local memory,
Its access speed is most fast;The Redis cachings are that a use ANSI C increased income is write, supports network, can be based on memory
Also can persistence log type, Key-Value databases, and provide the API of multilingual, as memory database, all numbers
According to all being read from memory, the consumption of read-write disk is saved, response speed is exceedingly fast, and there is strong applicability, access speed to be only second to
The characteristics of local cache.
It should be understood that after the picture is carried out Heat range classification, the Heat range of the picture can be with quilt
The variation of reading times and change, therefore, the present embodiment can also the picture complete Heat range divide after to the picture
Carry out Heat range update.Specifically, when the picture is first Heat range, picture deposit Redis is delayed
After depositing, the data transmission method further includes:Judge that the picture is read whether number is more than in the second time interval
The Heat range of the picture is updated to second Heat range by third threshold value when to be from the first Heat range, and
The picture is stored in the local cache;When the picture is second Heat range, the picture is stored in local
After caching, the data transmission method further includes:Judge whether the picture is read number in the second time interval big
The Heat range of the picture is updated from second Heat range when to be in the 4th threshold value and less than third threshold value
For first Heat range, and the picture is stored in the Redis and is cached.
Continue by taking the picture 1 in data transfer server A as an example, first time interval is one hour, the second time interval
It it is one hour, first threshold is 100, and second threshold is 200, and third threshold value is 200, and the 4th threshold value is 100.Data transmission
Server A is to judge that picture 1 is read number as 102 in first time interval i.e. one hour carrying out storage to picture 1
Ten is primary, is more than first predetermined threshold value 100 and is less than the second threshold, determines that the Heat range of picture 1 is the first heat
Grade is spent, picture 1 is stored in Redis cachings.In next second time interval i.e. one hour, picture 1 is read number
Reach 208, picture 1 is read number in the second time interval and is more than third threshold value, by the Heat range of picture 1 from
First Heat range is updated to the second Heat range, and picture 1 is stored in the local cache.At this point, data transfer server A
It is connected to the data access request of mobile phone X, judges the Heat range of picture 1 for the second Heat range.
After completing step S300, the present embodiment sequentially executes step S400:When the picture is hot spot data, obtain
The picture read from data buffer zone corresponding with the Heat range is sent to institute by the Heat range of the picture
State access end.Optionally, the present embodiment by the picture when being sent to the access end, in order to make the access end quickly
Receive the picture, can first determine whether node residing for the access end whether with the data transfer server be in it is same in
In net, when to be no, transmission technology is penetrated using Intranet and is carried out data transmission.Further, in this embodiment being used for into line number
May be multiple according to the data transfer server of work is stored and transmitted, at this time before carrying out data transmission task, it should confirm
Whether present data transmission server is fastest optimum data transmission server, is as follows:Based on described
Data access request judges the node residing for the access end;According at least two data transfer servers obtained in real time
The network flow and load state of each data transfer server, and each connection of data transfer server and the node
Situation and transmission range calculate optimum data transmission server corresponding with the node;Judge the data transport service
Whether device is the optimum data transmission server;When to be, step is executed:Described in access request judges based on the data
Whether the access target data of access end are picture;When to be no, the data access request is oriented to the optimum data and is passed
Defeated server is switched to the optimum data transmission server and carries out data transmission with the access end.
Then the Heat range of the picture 1 of data transfer server A is updated to the second Heat range, data transport service
Data access requests of the device A based on mobile phone X judges that mobile phone X is in node 5, and then data transfer server A is obtained according to real-time
All data transfer servers in each data transfer server network flow and load state, and each data pass
The connection state and transmission range of defeated server and the node 5 calculate optimum data transmission clothes corresponding with the node 5
Business device is data transfer server B, and the data access request is forwarded to data transfer server B by data transfer server A,
It is established and is connected by data transfer server B and mobile phone X, and picture 1 is sent to mobile phone X.
The data transmission method that first embodiment of the invention provides receives access end hair by data transfer server
The data access request sent, and determine and the access end communication speed is most fast, most stable of optimum data transmission server is rung
Answer the data access request, to ensure that data communication safety while improve data transmission stability and
Speed.Further, the hot spot data of picture category is also divided into the first Heat range and the second heat by the data transmission method
Grade is spent, and by the picture of first Heat range deposit Redis cachings, the picture of second Heat range is stored in this
Ground caches, and the speed of digital independent is greatly improved under the premise of ensureing memory space utilization ratio, improves data biography
Defeated efficiency.
Second embodiment
In order to realize that the above-mentioned data transmission method of first embodiment of the invention offer, second embodiment of the invention provide
A kind of data transfer server 100.Referring to FIG. 3, Fig. 3 is a kind of data transfer server that second embodiment of the invention provides
Module map.
Data transfer server 100 includes data transmission module 110, temperature division module 120, grade update module 130
With server se-lection module 140.
Data transmission module 110 includes that request reception unit, type judging unit, hot spot judging unit and data send list
Member.The request reception unit is for receiving the data access request that access end is sent.The type judging unit is for being based on
The data access request judges whether the access target data of the access end are picture.The hot spot judging unit is used for
When the access target data of the access end are picture, judge whether the picture is hot spot data.The data transmission unit
It, will be from number corresponding with the Heat range for when the picture is hot spot data, obtaining the Heat range of the picture
It is sent to the access end according to the picture that buffering area is read.
Temperature division module 120 includes reading times acquiring unit, Heat range division unit and data storage cell.Institute
Reading times acquiring unit is stated for obtaining the reading times that the picture is read in first time interval.Described temperature etc.
Grade division unit is used for based on the Heat range for being read number and determining the picture.The data storage cell is used
In the picture is stored in corresponding with Heat range data buffer zone.
Grade update module 130 includes reading frequency judging unit, the first updating unit and the second updating unit.The reading
It takes frequency judging unit to be read whether number is more than third threshold value in the second time interval for judging the picture, also uses
In judging the picture in the second time interval and be read whether number is more than the 4th threshold value and is less than third threshold value.Described
One updating unit is used for when the picture is read number more than third threshold value in the second time interval, by the picture
Heat range is updated to second Heat range from the first Heat range, and the picture is stored in the local cache.Institute
The second updating unit is stated, for being read number in the second time interval more than the 4th threshold value in the picture and being less than third
When threshold value, the Heat range of the picture is updated to first Heat range from second Heat range, and will be described
Picture is stored in the Redis cachings.
Server se-lection module 140 includes that node judging unit, computing unit and optimum data transmission server judge list
Member.Wherein, the node judging unit judges the node residing for the access end for access request based on the data.It is described
Computing unit is used for the network according to each data transfer server at least two data transfer servers obtained in real time
Flow and load state, and each data transfer server and the node connection state and transmission range, calculate and
The corresponding optimum data transmission server of the node.The optimum data transmission server judging unit is for judging the number
Whether it is the optimum data transmission server according to transmission server.
It is apparent to those skilled in the art that for convenience and simplicity of description, the device of foregoing description
Specific work process, can refer to preceding method in corresponding process, no longer excessively repeat herein.
3rd embodiment
Fig. 4 is please referred to, Fig. 4 shows a kind of structure diagram for the electronic equipment 200 that can be applied in the embodiment of the present application.
Electronic equipment 200 may include that data transfer server 100, memory 201, storage control 202, processor 203, peripheral hardware connect
Mouth 204, input-output unit 205, audio unit 206, display unit 207.
The memory 201, storage control 202, processor 203, Peripheral Interface 204, input-output unit 205, sound
Frequency unit 206,207 each element of display unit are directly or indirectly electrically connected between each other, to realize the transmission or friendship of data
Mutually.It is electrically connected for example, these elements can be realized between each other by one or more communication bus or signal wire.The data
Transmission server 100 can be stored in the form of software or firmware (firmware) in the memory 201 including at least one
Or it is solidificated in the software function module in the operating system (operating system, OS) of data transfer server 100.It is described
Processor 203 is used to execute the executable module stored in memory 201, such as the software that data transfer server 100 includes
Function module or computer program.
Wherein, memory 201 may be, but not limited to, random access memory (Random Access Memory,
RAM), read-only memory (Read Only Memory, ROM), programmable read only memory (Programmable Read-Only
Memory, PROM), erasable read-only memory (Erasable Programmable Read-Only Memory, EPROM),
Electricallyerasable ROM (EEROM) (Electric Erasable Programmable Read-Only Memory, EEPROM) etc..
Wherein, memory 201 is for storing program, and the processor 203 executes described program after receiving and executing instruction, aforementioned
The method performed by server that the stream process that any embodiment of the embodiment of the present invention discloses defines can be applied to processor 203
In, or realized by processor 203.
Processor 203 can be a kind of IC chip, the processing capacity with signal.Above-mentioned processor 203 can
To be general processor, including central processing unit (Central Processing Unit, abbreviation CPU), network processing unit
(Network Processor, abbreviation NP) etc.;Can also be digital signal processor (DSP), application-specific integrated circuit (ASIC),
Ready-made programmable gate array (FPGA) either other programmable logic device, discrete gate or transistor logic, discrete hard
Part component.It may be implemented or execute disclosed each method, step and the logic diagram in the embodiment of the present invention.General processor
Can be microprocessor or the processor 203 can also be any conventional processor etc..
The Peripheral Interface 204 couples various input/output devices to processor 203 and memory 201.At some
In embodiment, Peripheral Interface 204, processor 203 and storage control 202 can be realized in one single chip.Other one
In a little examples, they can be realized by independent chip respectively.
Input-output unit 205 is for being supplied to user input data to realize user and the server (or local terminal)
Interaction.The input-output unit 205 may be, but not limited to, the equipment such as mouse and keyboard.
Audio unit 206 provides a user audio interface, may include that one or more microphones, one or more raises
Sound device and voicefrequency circuit.
Display unit 207 provides an interactive interface (such as user's operation circle between the electronic equipment 200 and user
Face) or for display image data give user reference.In the present embodiment, the display unit 207 can be liquid crystal display
Or touch control display.Can be the capacitance type touch control screen or resistance for supporting single-point and multi-point touch operation if touch control display
Formula touch screen etc..Single-point and multi-point touch operation is supported to refer to touch control display and can sense on the touch control display one
Or at multiple positions simultaneously generate touch control operation, and by the touch control operation that this is sensed transfer to processor 203 carry out calculate and
Processing.
It is appreciated that structure shown in Fig. 4 is only to illustrate, the electronic equipment 200 may also include more than shown in Fig. 4
Either less component or with the configuration different from shown in Fig. 4.Hardware, software may be used in each component shown in Fig. 4
Or combinations thereof realize.
It is apparent to those skilled in the art that for convenience and simplicity of description, the device of foregoing description
Specific work process, can refer to preceding method in corresponding process, no longer excessively repeat herein.
In conclusion an embodiment of the present invention provides a kind of data transmission method, server and storage medium, the data
Transmission method when access target data are picture according to the Heat range of the picture, directly from corresponding with the Heat range
Data buffer zone read the picture, improve the speed of data screening confirmation, improve data transmission efficiency.Meanwhile this
Invention is carried out Heat range classification according to the number that is read per pictures respectively, improves Heat range classification reliability.
Further, the data transmission method is by the picture deposit Redis cachings of the first Heat range, by the figure of the second Heat range
Piece is stored in local cache, makes the reading of hot spot data faster, while the classification of hot spot data makes data buffer zone obtain preferably
It utilizes, can more effectively improve picture reading speed.The present invention is in the classification and storage for carrying out Heat range to the picture
Afterwards, also Heat range update can be carried out to the picture in preset time, with according to the practical frequency pair being read of the picture
Its Heat range carries out immediate updating, ensures that the data transmission bauds between data transfer server and access end is more stablized,
More it is bonded actual transmissions demand.In addition, heretofore described data transfer server is asked in the data transmission of response access end
Before asking, the most fast optimum data transmission server of transmission speed corresponding with the access end can be also first determined, by described best
Data transfer server carries out data transmission, and further increases transmission speed.
In several embodiments provided herein, it should be understood that disclosed device and method can also pass through
Other modes are realized.The apparatus embodiments described above are merely exemplary, for example, the flow chart in attached drawing and block diagram
Show the device of multiple embodiments according to the present invention, the architectural framework in the cards of method and computer program product,
Function and operation.In this regard, each box in flowchart or block diagram can represent the one of a module, section or code
Part, a part for the module, section or code, which includes that one or more is for implementing the specified logical function, to be held
Row instruction.It should also be noted that at some as in the realization method replaced, the function of being marked in box can also be to be different from
The sequence marked in attached drawing occurs.For example, two continuous boxes can essentially be basically executed in parallel, they are sometimes
It can execute in the opposite order, this is depended on the functions involved.It is also noted that every in block diagram and or flow chart
The combination of box in a box and block diagram and or flow chart can use function or the dedicated base of action as defined in executing
It realizes, or can be realized using a combination of dedicated hardware and computer instructions in the system of hardware.
In addition, each function module in each embodiment of the present invention can integrate to form an independent portion
Point, can also be modules individualism, can also two or more modules be integrated to form an independent part.
It, can be with if the function is realized and when sold or used as an independent product in the form of software function module
It is stored in a computer read/write memory medium.Based on this understanding, technical scheme of the present invention is substantially in other words
The part of the part that contributes to existing technology or the technical solution can be expressed in the form of software products, the meter
Calculation machine software product is stored in a storage medium, including some instructions are used so that a computer equipment (can be
People's computer, server or network equipment etc.) it performs all or part of the steps of the method described in the various embodiments of the present invention.
And storage medium above-mentioned includes:USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), arbitrary access are deposited
The various media that can store program code such as reservoir (RAM, Random Access Memory), magnetic disc or CD.
The foregoing is only a preferred embodiment of the present invention, is not intended to restrict the invention, for the skill of this field
For art personnel, the invention may be variously modified and varied.All within the spirits and principles of the present invention, any made by repair
Change, equivalent replacement, improvement etc., should all be included in the protection scope of the present invention.It should be noted that:Similar label and letter exist
Similar terms are indicated in following attached drawing, therefore, once being defined in a certain Xiang Yi attached drawing, are then not required in subsequent attached drawing
It is further defined and is explained.
The above description is merely a specific embodiment, but scope of protection of the present invention is not limited thereto, any
Those familiar with the art in the technical scope disclosed by the present invention, can easily think of the change or the replacement, and should all contain
Lid is within protection scope of the present invention.Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.
It should be noted that herein, relational terms such as first and second and the like are used merely to a reality
Body or operation are distinguished with another entity or operation, are deposited without necessarily requiring or implying between these entities or operation
In any actual relationship or order or sequence.Moreover, the terms "include", "comprise" or its any other variant are intended to
Non-exclusive inclusion, so that the process, method, article or equipment including a series of elements is not only wanted including those
Element, but also include other elements that are not explicitly listed, or further include for this process, method, article or equipment
Intrinsic element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that
There is also other identical elements in process, method, article or equipment including the element.
Claims (10)
1. a kind of data transmission method, which is characterized in that be applied to data transfer server, the data transmission method includes:
Receive the data access request that access end is sent;
Access request judges whether the access target data of the access end are picture based on the data;
When to be, judge whether the picture is hot spot data;
When to be, the Heat range of the picture is obtained, will be read from data buffer zone corresponding with the Heat range
The picture be sent to the access end.
2. data transmission method according to claim 1, which is characterized in that sentence in the access request based on the data
Before whether the access target data of disconnected user are picture, the data transmission method further includes:
Obtain the reading times that the picture is read in first time interval;
Based on the Heat range for being read number and determining the picture;
The picture is stored in data buffer zone corresponding with the Heat range.
3. data transmission method according to claim 2, which is characterized in that the number that is read based on described in determines institute
The Heat range of picture is stated, including:
It is read whether number is more than first threshold and is less than second threshold described in judgement;
When to be, determine that the Heat range of the picture is the first Heat range;
It is read whether number is more than second threshold when to be no, described in judgement;
When to be, determine that the Heat range of the picture is the second Heat range higher than first Heat range;
It is described that the picture is stored in data buffer zone corresponding with the Heat range, including:
When the picture is first Heat range, by picture deposit Redis cachings;
When the picture is second Heat range, the picture is stored in local cache.
4. data transmission method according to claim 3, which is characterized in that the picture be first Heat range
When, after picture deposit Redis cachings, the data transmission method further includes:
Judge that the picture is read whether number is more than third threshold value in the second time interval;
When to be, the Heat range of the picture is updated to second Heat range from the first Heat range, and by institute
It states picture and is stored in the local cache;
When the picture is second Heat range, after the picture is stored in local cache, the transmission side data
Method further includes:
Judge that the picture is read whether number is more than the 4th threshold value and is less than third threshold value in the second time interval;
When to be, the Heat range of the picture is updated to first Heat range from second Heat range, and
The picture is stored in the Redis cachings.
5. data transmission method according to claim 1 or 4, which is characterized in that in the number that the reception access end is sent
After access request, the access request based on the data judges whether the access target data of the access end are picture
Before, the data transmission method further includes:
Access request judges the node residing for the access end based on the data;
According to the network flow of each data transfer server at least two data transfer servers obtained in real time and bear
Load situation, and each connection state and transmission range of data transfer server and the node, calculate and the node
Corresponding optimum data transmission server;
Judge whether the data transfer server is the optimum data transmission server;
When to be, step is executed:Based on the data access request judge the access end access target data whether be
Picture.
6. a kind of data transfer server, which is characterized in that the data transfer server includes data transmission module, the number
Include according to transmission module:
Request reception unit, the data access request sent for receiving access end;
Type judging unit judges whether the access target data of the access end are figure for access request based on the data
Piece;
Hot spot judging unit, for when the access target data of the access end are picture, judging whether the picture is heat
Point data;
Data transmission unit, for the picture be hot spot data when, obtain the Heat range of the picture, will from it is described
The picture that the corresponding data buffer zone of Heat range is read is sent to the access end.
7. data transfer server according to claim 6, which is characterized in that the data transfer server further includes heat
Division module is spent, the temperature division module includes:
Reading times acquiring unit, the reading times being read in first time interval for obtaining the picture;
Heat range division unit, for based on the Heat range for being read number and determining the picture;
Data storage cell, for the picture to be stored in data buffer zone corresponding with the Heat range.
8. data transfer server according to claim 6, which is characterized in that the data transfer server further includes
Grade update module, the grade update module include:
Reading frequency judging unit is read whether number is more than third threshold for judging the picture in the second time interval
Value is additionally operable to judge that the picture is read whether number is more than the 4th threshold value and is less than third threshold in the second time interval
Value;
First updating unit, for the picture be read in the second time interval number more than third threshold value when, by institute
The Heat range for stating picture is updated to second Heat range from the first Heat range, and the picture is stored in the local
Caching;
Second updating unit, for being read number in the second time interval more than the 4th threshold value and less than the in the picture
When three threshold values, the Heat range of the picture is updated to first Heat range from second Heat range, and by institute
It states picture and is stored in the Redis cachings.
9. according to the data transmission device described in any claims of claim 6-8, which is characterized in that the data transmission device is also
Including server se-lection module, the server se-lection module includes:
Node judging unit judges the node residing for the access end for access request based on the data;
Computing unit, for according to each data transfer server at least two data transfer servers obtained in real time
Network flow and load state, and each connection state and transmission range of data transfer server and the node, calculate
Go out optimum data transmission server corresponding with the node;
Optimum data transmission server judging unit, for judging whether the data transfer server is that the optimum data passes
Defeated server.
10. a kind of computer read/write memory medium, which is characterized in that be stored with meter in the computer read/write memory medium
Calculation machine program instruction, when the computer program instructions are read and run by a processor, perform claim requires any one of 1-5 institutes
State the step in method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810610477.XA CN108810144A (en) | 2018-06-14 | 2018-06-14 | A kind of data transmission method, server and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810610477.XA CN108810144A (en) | 2018-06-14 | 2018-06-14 | A kind of data transmission method, server and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108810144A true CN108810144A (en) | 2018-11-13 |
Family
ID=64086133
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810610477.XA Pending CN108810144A (en) | 2018-06-14 | 2018-06-14 | A kind of data transmission method, server and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108810144A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110362400A (en) * | 2019-06-17 | 2019-10-22 | 中国平安人寿保险股份有限公司 | Distribution method, device, equipment and the storage medium of caching resource |
CN111597479A (en) * | 2020-04-18 | 2020-08-28 | 北京奇保信安科技有限公司 | Intelligent picture loading method and device for terminal and electronic equipment |
CN113608685A (en) * | 2021-06-30 | 2021-11-05 | 济南浪潮数据技术有限公司 | Hot spot identification method and system of distributed storage block device |
CN117834304A (en) * | 2024-03-05 | 2024-04-05 | 东方电气风电股份有限公司 | Autonomous controllable master control network safety protection system |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2013178155A1 (en) * | 2012-08-03 | 2013-12-05 | 中兴通讯股份有限公司 | Storage method and apparatus for distributed file system |
CN104702625A (en) * | 2015-03-31 | 2015-06-10 | 北京奇艺世纪科技有限公司 | Method and device for scheduling access request in CDN (Content Delivery Network) |
CN106888381A (en) * | 2015-12-16 | 2017-06-23 | 中兴通讯股份有限公司 | A kind of data resource storage method and device |
CN107797758A (en) * | 2016-09-07 | 2018-03-13 | 腾讯科技(深圳)有限公司 | Date storage method, data access method and device |
-
2018
- 2018-06-14 CN CN201810610477.XA patent/CN108810144A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2013178155A1 (en) * | 2012-08-03 | 2013-12-05 | 中兴通讯股份有限公司 | Storage method and apparatus for distributed file system |
CN104702625A (en) * | 2015-03-31 | 2015-06-10 | 北京奇艺世纪科技有限公司 | Method and device for scheduling access request in CDN (Content Delivery Network) |
CN106888381A (en) * | 2015-12-16 | 2017-06-23 | 中兴通讯股份有限公司 | A kind of data resource storage method and device |
CN107797758A (en) * | 2016-09-07 | 2018-03-13 | 腾讯科技(深圳)有限公司 | Date storage method, data access method and device |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110362400A (en) * | 2019-06-17 | 2019-10-22 | 中国平安人寿保险股份有限公司 | Distribution method, device, equipment and the storage medium of caching resource |
CN110362400B (en) * | 2019-06-17 | 2022-06-17 | 中国平安人寿保险股份有限公司 | Resource cache allocation method, device, equipment and storage medium |
CN111597479A (en) * | 2020-04-18 | 2020-08-28 | 北京奇保信安科技有限公司 | Intelligent picture loading method and device for terminal and electronic equipment |
CN113608685A (en) * | 2021-06-30 | 2021-11-05 | 济南浪潮数据技术有限公司 | Hot spot identification method and system of distributed storage block device |
CN117834304A (en) * | 2024-03-05 | 2024-04-05 | 东方电气风电股份有限公司 | Autonomous controllable master control network safety protection system |
CN117834304B (en) * | 2024-03-05 | 2024-05-03 | 东方电气风电股份有限公司 | Autonomous controllable master control network safety protection system |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10834123B2 (en) | Generating data clusters | |
CN108810144A (en) | A kind of data transmission method, server and storage medium | |
US11893627B2 (en) | Adaptive risk-based verification and authentication platform | |
WO2019149145A1 (en) | Compliant report class sorting method and apparatus | |
US20240086414A1 (en) | Efficient access of chainable records | |
US11775504B2 (en) | Computer estimations based on statistical tree structures | |
CN110201393A (en) | Configuration data storage method and device and electronic equipment | |
WO2020024898A1 (en) | Method and apparatus for searching blockchain data, and storage medium | |
CN109241722A (en) | For obtaining method, electronic equipment and the computer-readable medium of information | |
CN108734510B (en) | Advertisement recommendation method and system based on attribute matching | |
US9305075B2 (en) | Extending dynamic matrices for improved setup capability and runtime search performance of complex business rules | |
CN109684093A (en) | Data processing method and system | |
CN103366128A (en) | Information processing apparatus, information processing method, information processing system, and program | |
WO2024093226A1 (en) | Configuration data processing method, and system, device and computer-readable storage medium | |
CN107404491A (en) | Terminal environments method for detecting abnormality, detection means and computer-readable recording medium | |
CN115481026A (en) | Test case generation method and device, computer equipment and storage medium | |
CN106790160B (en) | Security level identification and method of calibration and device | |
CN114064510A (en) | Function testing method and device, electronic equipment and storage medium | |
KR102118076B1 (en) | Method for provide rewards to ai(artificial intelligence) and distribute the rewards to other users | |
TWI838461B (en) | Methods and systems for accessing chainable records | |
CN111930620B (en) | Application running environment data processing method and device | |
US11921707B2 (en) | Automatically recommending database access patterns for transactions in microservices | |
JP2003030282A (en) | System and method for managing quality information | |
KR20050103997A (en) | Method for managing on-line knowledge community and system for enabling the method | |
US20230036688A1 (en) | Calibrated risk scoring and sampling |
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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20181113 |