CN108566420A - Data processing method, equipment and computer readable storage medium for block chain - Google Patents

Data processing method, equipment and computer readable storage medium for block chain Download PDF

Info

Publication number
CN108566420A
CN108566420A CN201810270065.6A CN201810270065A CN108566420A CN 108566420 A CN108566420 A CN 108566420A CN 201810270065 A CN201810270065 A CN 201810270065A CN 108566420 A CN108566420 A CN 108566420A
Authority
CN
China
Prior art keywords
data
chain
under
memory
stored
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201810270065.6A
Other languages
Chinese (zh)
Inventor
陈曦
谭峰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shanghai Point Information Technology Co Ltd
Original Assignee
Shanghai Point Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shanghai Point Information Technology Co Ltd filed Critical Shanghai Point Information Technology Co Ltd
Priority to CN201810270065.6A priority Critical patent/CN108566420A/en
Publication of CN108566420A publication Critical patent/CN108566420A/en
Pending legal-status Critical Current

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/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]
    • 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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

This disclosure provides a kind of data processing method for block chain, the data processing method includes:Receive request for storing data, wherein the request for storing data includes information associated with the data to be stored;Storage rule is obtained from the block chain, wherein the storage rule includes that judgment rule and uplink data format are stored under chain;Based on storing judgment rule under described information and the chain, it is determined whether by least part of the data be stored on the block chain and chain under in memory;In determining store the data on the block chain in memory under the chain, based on the data with the uplink data format, the metadata of the data is generated;And the metadata is stored on the block chain, and store the data under the chain in memory.

Description

Data processing method, equipment and computer readable storage medium for block chain
Technical field
This disclosure relates to block chain technologies, relate more particularly to the data processing method for block chain, are used for The data processing equipment of block chain and the corresponding computer readable storage medium for implementing the above method.
Background technology
Block chain has obtained extensive discussion and research as the emerging technology risen in recent years.Block chain be it is a kind of with Block structure stores data, ensures transmission and access safety using cryptography, can realize data consistency storage, tamper-resistant, go The technical system at center.
Intelligent contract is a computer program that can be accurately run on block chain.User is by using intelligent contract It is traded, shared data, establishes and trust and the storage of data is ensured by the characteristic of block chain technology, reading, executes entire mistake Journey is transparent to be can be traced, can not distort.
Since block chain belongs to peer-to-peer network, user may have access to the node of any node or any tissue on block chain and obtain Block and transaction data.
Storage data itself under line, the storage abstract i.e. mode of cryptographic Hash on line are disclosed in the prior art.But it is existing Incidence relation is not present in data under data and chain on the chain in the storage scheme in technology.
Invention content
Based on the understanding for the above technical problem and the state of the art, present disclosure inventors herein proposes a kind of mark The method that big file is stored in combination on the block chain of standardization and under chain, to solve the above problems.
The first aspect of present disclosure provides a kind of data processing method for block chain, the data processing side Method includes:
Receive request for storing data, wherein the request for storing data include with it is to be stored described in The associated information of data;
Storage rule is obtained from the block chain, wherein the storage rule includes that judgment rule and upper is stored under chain Chain data format;
Based on storing judgment rule under described information and the chain, it is determined whether store at least part of the data On the block chain and under chain in memory;
Determine store the data on the block chain and the chain under in memory when, based on the data and The uplink data format, generates the metadata of the data;And
The metadata is stored on the block chain, and is stored the data under the chain in memory.
The second aspect of present disclosure provides a kind of data processing equipment for block chain comprising:
Processor;And
Memory makes the processor execute following operation when described instruction executes for storing instruction:
Receive request for storing data, wherein the request for storing data include with it is to be stored described in The associated information of data;
Storage rule is obtained from the block chain, wherein the storage rule includes that judgment rule and upper is stored under chain Chain data format;
Based on storing judgment rule under described information and the chain, it is determined whether store at least part of the data On the block chain and under chain in memory;
Determine store the data on the block chain and the chain under in memory when, based on the data and The uplink data format, generates the metadata of the data;And
The metadata is stored on the block chain, and is stored the data under the chain in memory.
Finally, the third aspect of present disclosure provides a kind of tangible computer readable storage medium, has and deposits Storage computer-readable program instructions on it, the computer-readable program instructions are used to execute the according to present disclosure Method described in one side.
The data processing method that present disclosure according to present disclosure is proposed, realizes big file on block chain And the systematization under chain and standardized storage scheme.In addition, in some embodiments of the present disclosure, each node on block chain Built-in intelligence contract can be installed, and the interface of the contract is disclosed, user can be by accessing or calling the side of intelligent contract Formula obtains file storage rule and completes to store, and with the popularization and application of block chain, the technical solution in the disclosure can embody Larger technological value and commercial value.
Description of the drawings
It refers to the following detailed description in conjunction with the accompanying drawings, the feature, advantage and other aspects of the presently disclosed embodiments will become Must be more obvious, show several embodiments of the disclosure by way of example rather than limitation herein, in the accompanying drawings:
Fig. 1 shows the flow chart of the data processing method 100 for block chain;
Fig. 2 shows showing for one embodiment 200 of the data processing method for block chain of foundation present disclosure It is intended to;And
Fig. 3 shows the schematic diagram of the data processing equipment 300 for block chain.
Specific implementation mode
Each exemplary embodiment of the disclosure is described in detail below with reference to attached drawing.Although examples described below side Method, device include the software and/or firmware executed on hardware in other components, it should be noted that these examples are only It is merely illustrative, and is not to be taken as restrictive.For example, it is contemplated that within hardware exclusively, in software exclusively or It can implement any or all hardware, software and fastener components in any combinations of hardware and software.Therefore, although below Illustrative method and apparatus are described, but those skilled in the art should be easily understood that, the example provided is not used to Limit the mode for realizing these method and apparatus.
In addition, flowcharts and block diagrams in the drawings show method and system according to various embodiments of the present disclosure can The architecture, function and operation that can be realized.It should be noted that the function of being marked in box can also be according to different from attached drawing The sequence marked occurs.For example, two boxes succeedingly indicated can essentially be basically executed in parallel or they have When can also execute in a reverse order, this depend on involved function.It should also be noted that flow chart and/or The combination of each box in block diagram and the box in flowchart and or block diagram can use function or behaviour as defined in executing The dedicated hardware based system made is realized, or can make to combine using a combination of dedicated hardware and computer instructions to realize.
Before the specific technical solution according to present disclosure is discussed in detail, present disclosure institute base will be introduced first In the technical issues of, such as the big file of a 10kb, if necessary to carry out storing on chain to it, then pushing away with the time It moves, more and more big files will be all stored on block chain, then data will be drastically swollen on the chain of entire block chain Swollen, it is excessive to eventually lead to overabundance of data on the chain of block chain, to be unfavorable for the operation of block chain network;On the other hand, if The data are only carried out to store under chain, then the data there is a possibility that be tampered, and data safety cannot be guaranteed.
In addition, block chain uses distributed storage pattern, to the storage of data, there are probelem in two aspects at present.
The problem of first aspect, is that reading and writing size of data is limited.Specifically, block chain have to uplink data it is stringent Size limits, and not can be well solved big file storage.
The problem of second aspect, is that memory capacity is difficult to estimate.Specifically, each node can get on block chain The data that full chain is submitted, safeguard full dose data backup.Over time, the data volume that node is preserved will be with uncontrollable Mode increases.
Big file is stored, data preservation is a kind of normal method under chain at present.However, there is no one kind to be directed at present Storage solution under the systematization of file, standardized chain cochain greatly.That is under the chain being previously mentioned in the prior art There is no the flows of systematization for data storage.To the processing of big file at present still based on storage location under chain, do not carry out Information processing on chain, the prior art are not prescribed by under chain with how data on chain are associated, and how to judge that data are answered on chain also It is to be stored under chain, and how the data stored under this chain cochain are read out.
In order to solve the above-mentioned technical problem, the design of present disclosure is as follows, i.e., the disclosure proposes a kind of for block chain Chain cochain under data processing method, to solve the problems, such as that the size of data on the chain for reading or being written is restricted.Together When this is used for data processing method under the chain cochain of block chain and can control uplink data amount, held with alleviating the storage of block chain node Amount increases too fast pressure.
Specifically, storage rule intelligence contract can be defined under the chain cochain in data processing method, to limit cochain number According to rule and uplink data format;In addition, when executing block chain write operation, whether data are judged according to pre-defined rule Directly store to block chain.In the case where data are not stored directly on block chain, according to storage rule intelligence contract come really Surely the format of the metadata to the uplink data on block chain is stored.At the same time, data also may include data on chain under chain Relevant information, such as block chain nodal information, cochain time etc..Data can guarantee tamper-resistant and data integrity, while chain on chain The presence of lower data also can effectively control the scale of uplink data.
Correspond ground, when executing block chain read operation, can support to read simultaneously on chain with chain under data.It is optional Ground, write operation interface can further support data compression or batch data to submit, to be further reduced uplink data amount.
The data processing method 100 for block chain according to present disclosure is specifically described below with reference to Fig. 1.Figure 1 shows the flow chart of one embodiment of the data processing method 100 for block chain according to present disclosure.From figure As can be seen that the data processing method 100 for block chain according to present disclosure includes the following steps:
First, request for storing data is received in method and step 110, wherein the asking for storing data It asks including information associated with the data to be stored, such as the information such as the size of data to be stored or format;For example, The request for storing data can indicate to need store transaction data.Certainly, which can be with table Show and needs to store a complex data, treaty documents and corresponding friendship of the complex data for example including pdf formats Easy data;
Next, in method and step 120, which will obtain from the block chain Take storage rule, wherein the storage rule includes that judgment rule and uplink data format are stored under chain;For example, storage rule In can specify that transaction data can be stored on block chain, and will only carry out chain more than the document of the pdf formats of 1kb sizes Lower storage, on chain by preserve include its abstract cryptographic Hash metadata;
Then, it is based on storing judgment rule under described information and the chain in method and step 130, it is determined whether will be described At least part of data is stored on the block chain in memory under chain, is sentenced based on being stored under described information and the chain Disconnected rule determine whether at least part by the data be stored on the block chain and chain under can be into one in memory Step include the data to be stored included by described information size information and the chain under it is specified in storage judgment rule File size threshold information between relationship determine whether that at least part by the data is stored on the block chain In memory under chain.;And it is stored the data on the block chain and the chain in method and step 140 determining When in lower memory, based on the data with the uplink data format, the metadata of the data is generated.For example, if should Request expression for storing data needs store transaction data, and can specify that transaction data in storage rule and can be stored On block chain, then transaction data will be stored on block chain, in addition, will be generated according to transaction data corresponding Metadata, and the metadata is stored on block chain.For another example, if request for storing data can indicate needs pair The complex data of treaty documents and corresponding transaction data including pdf formats is stored, and is provided in storage rule super Crossing the document of the pdf formats of 1kb sizes will only carry out storing under chain, on chain by preserve include its abstract cryptographic Hash metadata, So the data processing method for being used for block chain will calculate its cryptographic Hash of making a summary, then according to included in storage rule Uplink data format generates corresponding metadata;
Finally, which will store the metadata in method and step 150 On the block chain, and store the data under the chain in memory.If request for storing data can To indicate to need to store the complex data of treaty documents and corresponding transaction data including pdf formats, and store Regulation will only carry out storing under chain more than the document of the pdf formats of 1kb sizes in rule, and will be preserved on chain includes its Hash of making a summary The metadata of value, then the demand that can be stored according to data under chain, generation respective meta-data (such as chain fixing region block chain number of nodes, Node visit address, intelligent contract address and information etc.), it completes data under chain and stores.Data storage can be with data on chain under chain Storage synchronously completes, and also can sequentially complete.
Preferably, above-mentioned metadata includes indicating whether that there are the sizes of data under the information of data, expression chain under chain Information, summary info and temporal information, wherein the summary info is, for example, the cryptographic Hash of data to be stored.Into one Preferably, above-mentioned temporal information includes in the generated time information of the metadata and the cochain temporal information of the metadata to step It is at least one.In addition, the metadata further includes accessing united resource locator (URLS) information of storage service under chain.By The accessing united resource locator information of storage service under chain is contained in the metadata, so can be according to the URLS information The location information of storage service under chain is obtained, and then the data can be obtained.
It is not seen in fig. 1, the data processing method 100 for being used for block chain can also include reading service, it is described Reading service includes:Receive the request for reading data;Based on the request for reading data, from the block chain Obtain the metadata of the data;And when the metadata indicates that the data store on the block chain, from described The data are obtained on block chain;Or when the metadata indicate the data be stored on the block chain and the chain under When in memory, the data are obtained from the block chain and under the chain in memory.
Optionally or alternatively, the data processing method further includes that the metadata is stored in memory under the chain In and reading service, and the metadata being wherein stored under the chain in memory further includes related to data on chain The information of connection, at this point, the reading service includes:Receive the request for reading data;Based on described for reading data Request, obtains the metadata of the data from memory under the chain;And when the metadata indicates the data storage When under the chain in memory, the data are obtained from memory under the chain;Or described in being indicated when the metadata Data store when on the block chain and under the chain in memory, from the block chain and under the chain in memory Obtain the data.
Preferably, the storage rule further includes the data information for limiting applicable data compression or batch processing.So as to The accounting of non-effective data in the data on block chain is enough further decreased, and then improves the transmission effect of valid data on block chain Rate.
Those skilled in the art is it is to be appreciated that the above-mentioned data processing method 100 for block chain can be can In the terminal (such as smart mobile phone, notebook personal computer etc.) communicated with block chain, intermediate treatment device, such as BaaS (Blockchain as a Service:Block chain services) it is run on platform or on any one node of block chain, It can be executed by least two in above-mentioned terminal, intermediate treatment device and node are common.
Fig. 2 shows showing for one embodiment 200 of the data processing method for block chain of foundation present disclosure It is intended to.It can be seen from the figure that block chain service module 210 can include reading interface and writing interface, below first to write interface For introduce according to the data processing method for block chain disclosed in present disclosure.
When block chain service module 210 receives at user 220 and submits the request of data to block chain, the block chain The communication module that service module 210 will be included by means of the block chain service module 210 is wrapped with block chain network 230 The block chain node contained is (such as in the block chain node 213,232,233,234,235,236,237,238 or 239 in Fig. 2 Any one is multiple) it is communicated, to read institute in the storage rule intelligence contract run on the block chain node Including data are stored to the storage rule on block chain chain and/or under chain for determining, wherein the storage rule includes Uplink data rule and uplink data format.Those skilled in the art it is to be appreciated that nine block chain nodes herein only It is exemplary and not limiting, the block chain communicated with block chain service module 210 can include more or less A block chain node.
Next, the data in block chain are written whether in the data processing method for being used for block chain required for will judging Only include the data stored on the progress chain of defined in storage rule, if the data in required write-in block chain only include The data that are stored on the progress chain of defined in storage rule, then to following the uplink data format of defined in storage rule Metadata is by calling the storage intelligence contract run in block chain stored on chain;If in required write-in block chain Data include not only the data that store on the progress chain of defined in storage rule, further include in storage rule defined should The data stored under chain are carried out, then can generate corresponding cochain metadata and the storage run in block chain is called intelligently to close respectively About carry out chain on store and call chain under storage service (not shown) carry out chain under store.
In this embodiment, the content of storage rule intelligence contract may include judging whether data directly store to block chain (such as according to data format, size), uplink data metadata format (such as whether there are under data, chain under chain data it is big The access urls of storage service under small, abstract (such as cryptographic Hash), generated time, chain);Optionally, storage rule intelligence contract Content also may include limit applicable data compression or batch processing data information (such as according to format, size etc.).
In this embodiment, storage rule intelligence contract is shared for full chain, to ensure the consistency of data on chain.And it stores Intelligent contract is the intelligent contract of reading and writing data, it is understood that there may be it is one or more, and store intelligent contract and may include storage rule The then information of intelligent contract, such as address can support whether across contract calling is met with verify data in storage rule intelligence contract Defined metadata.
And when block chain service module executes read operation, there are several realization methods:Only read data on chain;Read chain Upper data access data under chain according to the metadata for being included;Only read data under chain;Data under chain are read, according to being included Metadata, access chain on data.
And storage service is capable of providing data read and write interface under chain under the chain in the embodiment, wherein storage service under chain Specific implementation prior art completion can be used, the selection of concrete database can carry out type selecting and realize (such as according to demand Mysql, mongodb, elasticsearch etc.).
As described above, the above-mentioned block chain service module run wherein for the data processing method 100 of block chain 210 can either be in the terminal (such as smart mobile phone, notebook personal computer etc.) that can be communicated with block chain, middle Manage device, such as BaaS (Blockchain as a Service:Block chain is to service) on platform or block chain it is any one It runs on a node, can also be executed by least two in above-mentioned terminal, intermediate treatment device and node are common
In addition, alternatively, the above method can be by computer program product, i.e. computer readable storage medium is real It is existing.Computer program product may include computer readable storage medium, containing for executing each of present disclosure The computer-readable program instructions of aspect.Computer readable storage medium can be kept and store by instruction execution equipment The tangible device of the instruction used.Computer readable storage medium for example can be but not limited to storage device electric, magnetic storage is set Standby, light storage device, electromagnetism storage device, semiconductor memory apparatus or above-mentioned any appropriate combination.It is computer-readable The more specific example (non exhaustive list) of storage medium includes:Portable computer diskette, hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read only memory (EPROM or flash memory), static RAM (SRAM), Portable compressed disk read-only memory (CD-ROM), digital versatile disc (DVD), memory stick, floppy disk, mechanical coding Equipment, the punch card for being for example stored thereon with instruction or groove internal projection structure and above-mentioned any appropriate combination.Here Used computer readable storage medium is not interpreted instantaneous signal itself, such as radio wave or other Free propagations Electromagnetic wave, the electromagnetic wave (for example, the light pulse for passing through fiber optic cables) propagated by waveguide or other transmission mediums or logical Cross the electric signal of electric wire transmission.
Fig. 3 shows the schematic block diagram of the data processing equipment 300 for block chain.It should be appreciated that data processing is set Standby 300 may be implemented as realizing the function of the block chain service module 210 in Fig. 2.As can be seen from Figure 3 it is used for block chain Data processing equipment 300 include central processing unit (CPU) 301 (such as processor), can be according to being stored in read-only deposit Computer program instructions in reservoir (ROM) 302 are loaded into from storage unit 308 in random access storage device (RAM) 303 Computer program instructions, to execute various actions appropriate and processing.It, can also the operation of storage device 300 institute in RAM 303 The various programs and data needed.CPU 301, ROM 302 and RAM 303 are connected with each other by bus 304.Input/output (I/ O) interface 305 is also connected to bus 304.
Multiple components in data processing equipment 300 are connected to I/O interfaces 305, including:Input unit 306, such as key Disk, mouse etc.;Output unit 307, such as various types of displays, loud speaker etc.;Storage unit 308, such as disk, CD Deng;And communication unit 309, such as network interface card, modem, wireless communication transceiver etc..Communication unit 309 allows equipment 300 exchange information/data by the computer network and/or various telecommunication networks of such as internet with other equipment.
Various methods described above, such as the data processing method 100 for block chain or block chain service module 210 can be executed by processing unit 301.For example, in some embodiments, the data processing method 100 for block chain or area Block chain service module 210 may be implemented as computer software programs, is tangibly embodied in machine readable media, such as deposit Storage unit 308.In some embodiments, some or all of of computer program can be via ROM 302 and/or communication unit 309 and be loaded into and/or be installed in equipment 300.When computer program is loaded into RAM 303 and is executed by CPU 301, The action of one or more of method as described above 100 or 200 or step can be executed.
In general, the various example embodiments of the disclosure can in hardware or special circuit, software, firmware, logic, or Implement in any combination thereof.Some aspects can be implemented within hardware, and other aspects can be can be by controller, microprocessor Implement in the firmware or software that device or other computing devices execute.When the various aspects of embodiment of the disclosure are illustrated or described as When block diagram, flow chart or other certain graphical representations of use, it will be understood that box described herein, device, system, techniques or methods Can be used as unrestricted example hardware, software, firmware, special circuit or logic, common hardware or controller or other Implement in computing device or its certain combination.
Generally, on various memories can store instruction, make the processor 301 hold when described instruction executes The following operation of row:Receive request for storing data, wherein the request includes letter associated with data to be accessed Breath;It obtains and stores data to the storage rule on block chain chain and/or under chain for determining, wherein the storage rule packet Include uplink data rule and uplink data format;The request is handled according to the storage rule, institute is followed to obtain State the metadata of uplink data format;And storage on chain is carried out to the metadata and is handled.
Although described above is the various example embodiments of the disclosure to be realized in hardware or special circuit, on Stating can both be implemented in hardware for the data processing equipment of block chain, can also be by the form of software come real It is existing, this is because:In the 1990s, a technological improvement can easily belong to the improvement improvement on hardware (for example, improvement to circuit structures such as diode, transistor, switches) still falls within the improvement on software (such as method The improvement of flow).However, with the sustainable development of technology, the improvement of many method flows of today can nearly all pass through by Improved method flow is programmed into hardware circuit to realize, in other words, by programming different programs for hardware circuit To obtain corresponding hardware circuit, that is, realize the change of hardware circuit, therefore the improvement of such method flow It can also be considered as directly improving for hardware circuit.Therefore, it cannot be said that the improvement of a method flow cannot use hardware Entity module is realized.For example, programmable logic device (Programmable Logic Device:PLD) (such as scene can Program gate array (Field Programmable Gate Array:FPGA)) it is exactly such a integrated circuit, logic work( Device programming can be determined by user.It is voluntarily programmed by designer a digital display circuit " integrated " may be programmed a piece of On logical device, dedicated IC chip is designed and made without asking chip maker.Moreover, nowadays replacing IC chip is manually made, this programming is also used " logic compiler (logic compi1er) " software instead and come in fact mostly Existing, software compiler used is similar when it writes with program development, and the source code before compiling is also handy specific Programming language write, this is referred to as hardware description language (Hardware Description Language:HDL), and HDL also not only-kind, but there are many kind, as ABEL (Advanced Boolean Expression Language), AHDL(Altera Hardware Description Language)、Confluence、CUPL(Cornell University Programming Language)、HDCal、JHDL(Java Hardware Description Language)、Lava、 Lola, MyHDL, PALASM, RHDL (Ruby Hardware Description Language) etc., most generally use at present VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) with Verilog.Those skilled in the art, which also will be apparent to the skilled artisan that, only to need with above-mentioned several hardware description languages slightly to patrol method flow It collects and programs and be programmed into integrated circuit, so that it may to be readily available the hardware circuit for realizing the logical method flow.
The computer-readable program instructions or computer program product of various aspects for executing present disclosure It can store beyond the clouds, when needing to call, user can be accessed by mobile Internet, fixed network or other networks and is stored in The computer-readable program instructions of the various aspects for executing present disclosure on high in the clouds, in the implementation basis disclosure Technical solution disclosed in the various aspects of appearance.
The foregoing is merely embodiment of the disclosure alternative embodiments, are not limited to embodiment of the disclosure, for For those skilled in the art, embodiment of the disclosure can have various modifications and variations.It is all in embodiment of the disclosure Within spirit and principle, made by any modification, equivalence replacement, improvement etc., should be included in the protection of embodiment of the disclosure Within the scope of.
Although describing embodiment of the disclosure by reference to several specific embodiments, it should be appreciated that, the disclosure Embodiment is not limited to disclosed specific embodiment.Embodiment of the disclosure be intended to cover appended claims spirit and Included various modifications and equivalent arrangements in range.Scope of the following claims is to be accorded the broadest interpretation, thus comprising All such modifications and equivalent structure and function.

Claims (19)

1. a kind of data processing method for block chain, the data processing method include:
Receive request for storing data, wherein the request for storing data includes and the data to be stored Associated information;
Storage rule is obtained from the block chain, wherein the storage rule includes that judgment rule and cochain number are stored under chain According to format;
Determine whether that at least part by the data is stored in institute based on judgment rule is stored under described information and the chain State on block chain and chain under in memory;
Determine store the data on the block chain and the chain under in memory when, based on the data with it is described Uplink data format generates the metadata of the data;And
The metadata is stored on the block chain, and is stored the data under the chain in memory.
2. data processing method according to claim 1, wherein information associated with the data to be stored includes The size information and/or format information of data to be stored.
3. data processing method according to claim 2, wherein based on storing judgment rule under described information and the chain Determine whether that at least part by the data is stored on the block chain with memory under chain to further comprise:
Specified by being stored under the size information of data to be stored included by described information and the chain in judgment rule Relationship between file size threshold information determine whether at least part by the data be stored on the block chain and Under chain in memory.
4. data processing method according to claim 1 or 2, wherein the metadata includes indicating whether that there are under chain The information of data, information, summary info and the temporal information for indicating the size of data under chain.
5. data processing method according to claim 4, wherein when the temporal information includes the generation of the metadata Between information and the metadata at least one of cochain temporal information.
6. data processing method according to claim 4, wherein the metadata further includes the access of storage service under chain URL information.
7. data processing method according to claim 4, the data processing method further includes reading service, the reading Service includes:
Receive the request for reading data;
Based on the request for reading data, the metadata of the data is obtained from the block chain;And
When the metadata indicates that the data store on the block chain, the data are obtained from the block chain; Or
When the metadata indicates that the data store on the block chain and under the chain in memory, from the block The data are obtained on chain and under the chain in memory.
8. data processing method according to claim 1, the data processing method further includes storing the metadata Under the chain in memory and reading service, and the metadata being wherein stored under the chain in memory is also wrapped Information associated with data on chain is included, the reading service includes:
Receive the request for reading data;
Based on the request for reading data, the metadata of the data is obtained from memory under the chain;And
When the metadata indicates that the data store under the chain in memory, institute is obtained from memory under the chain State data;Or
When the metadata indicates that the data store on the block chain and under the chain in memory, from the block The data are obtained on chain and under the chain in memory.
9. data processing method according to claim 1, wherein the storage rule further includes limiting applicable data compression Or the data information of batch processing.
10. a kind of data processing equipment for block chain comprising:
Processor;And
Memory makes the processor execute following operation when described instruction executes for storing instruction:
Receive request for storing data, wherein the request for storing data includes and the data to be stored Associated information;
Storage rule is obtained from the block chain, wherein the storage rule includes that judgment rule and cochain number are stored under chain According to format;
Determine whether that at least part by the data is stored in institute based on judgment rule is stored under described information and the chain State on block chain and chain under in memory;
Determine store the data on the block chain and the chain under in memory when, based on the data with it is described Uplink data format generates the metadata of the data;And
The metadata is stored on the block chain, and is stored the data under the chain in memory.
11. data processing equipment according to claim 10, wherein packet associated with the data to be stored Include the size information and/or format information of data to be stored.
12. data processing equipment according to claim 10, wherein judge rule based on storage under described information and the chain Then determine whether that at least part by the data is stored on the block chain with memory under chain to further comprise:
Specified by being stored under the size information of data to be stored included by described information and the chain in judgment rule Relationship between file size threshold information determine whether at least part by the data be stored on the block chain and Under chain in memory.
13. the data processing equipment according to claim 10 or 11, wherein the metadata includes indicating whether that there are chains The information of lower data, information, summary info and the temporal information for indicating the size of data under chain.
14. data processing equipment according to claim 12, wherein the temporal information includes the generation of the metadata At least one of the cochain temporal information of temporal information and the metadata.
15. data processing equipment according to claim 12, wherein the metadata further includes the visit of storage service under chain Ask URL information.
16. data processing equipment according to claim 13 also makes the processor execute when described instruction executes It operates below:
Receive the request for reading data;
Based on the request for reading data, the metadata of the data is obtained from the block chain;And
When the metadata indicates that the data store on the block chain, the data are obtained from the block chain; Or
When the metadata indicates that the data store on the block chain and under the chain in memory, from the block The data are obtained on chain and under the chain in memory.
17. data processing equipment according to claim 10 also makes the processor execute when described instruction executes It operates below:
The metadata is stored under the chain in memory, wherein being stored under the chain metadata in memory Further include information associated with data on chain;
Receive the request for reading data;
Based on the request for reading data, the metadata of the data is obtained from memory under the chain;And
When the metadata indicates that the data store under the chain in memory, institute is obtained from memory under the chain State data;Or
When the metadata indicates that the data store on the block chain and under the chain in memory, from the block The data are obtained on chain and under the chain in memory.
18. data processing equipment according to claim 10, wherein the storage rule further includes limiting applicable data pressure The data information of contracting or batch processing.
19. a kind of computer readable storage medium has the computer-readable program instructions being stored thereon, the computer Readable program instructions are for executing method according to any one of claim 1 to 9.
CN201810270065.6A 2018-03-29 2018-03-29 Data processing method, equipment and computer readable storage medium for block chain Pending CN108566420A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810270065.6A CN108566420A (en) 2018-03-29 2018-03-29 Data processing method, equipment and computer readable storage medium for block chain

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810270065.6A CN108566420A (en) 2018-03-29 2018-03-29 Data processing method, equipment and computer readable storage medium for block chain

Publications (1)

Publication Number Publication Date
CN108566420A true CN108566420A (en) 2018-09-21

Family

ID=63533257

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810270065.6A Pending CN108566420A (en) 2018-03-29 2018-03-29 Data processing method, equipment and computer readable storage medium for block chain

Country Status (1)

Country Link
CN (1) CN108566420A (en)

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109284197A (en) * 2018-10-25 2019-01-29 中思博安科技(北京)有限公司 Distributed Application platform and implementation method based on intelligent contract
CN109542455A (en) * 2018-11-29 2019-03-29 杭州复杂美科技有限公司 Contract executes method, contract compressing method, equipment and storage medium
CN109617964A (en) * 2018-12-12 2019-04-12 成都四方伟业软件股份有限公司 Big data storage method and device based on block chain
CN109726249A (en) * 2018-12-12 2019-05-07 杭州基尔区块链科技有限公司 A kind of decentralization chip research and development transaction data storage method and system
CN110020542A (en) * 2018-12-20 2019-07-16 阿里巴巴集团控股有限公司 Data read-write method and device, electronic equipment
CN110109935A (en) * 2019-05-13 2019-08-09 北京共识数信科技有限公司 A kind of Gang Hang business alliance design method based on block chain
CN110147202A (en) * 2019-05-15 2019-08-20 杭州云象网络技术有限公司 A method of reducing block chain intelligence contract code storage volume
CN110363663A (en) * 2019-07-12 2019-10-22 深圳前海微众银行股份有限公司 Batch data processing method, device, equipment and storage medium based on block chain
CN110427380A (en) * 2019-08-07 2019-11-08 北京艾摩瑞策科技有限公司 It is related to rent a house associated data processing method and its device of block chain
CN112200690A (en) * 2020-10-27 2021-01-08 西安纸贵互联网科技有限公司 Ship quality traceability system based on block chain
CN112513853A (en) * 2018-12-11 2021-03-16 松下电器(美国)知识产权公司 Data management method, data management system, and program
CN112507028A (en) * 2020-12-18 2021-03-16 杭州趣链科技有限公司 Data storage method, device, equipment and storage medium
CN112988726A (en) * 2021-03-24 2021-06-18 北京百度网讯科技有限公司 Data management method and device, computer equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106534273A (en) * 2016-10-31 2017-03-22 中金云金融(北京)大数据科技股份有限公司 Block chain metadata storage system, and storage method and retrieval method thereof
CN107103252A (en) * 2017-04-27 2017-08-29 电子科技大学 Data access control method based on block chain
CN107103405A (en) * 2017-03-22 2017-08-29 暨南大学 A kind of mass-rent system and its building method based on block chain technology
CN107273410A (en) * 2017-05-03 2017-10-20 上海点融信息科技有限责任公司 Distributed storage based on block chain
JP2017204707A (en) * 2016-05-10 2017-11-16 日本電信電話株式会社 Content distribution system, content distribution method, content generation device, and content generation program

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017204707A (en) * 2016-05-10 2017-11-16 日本電信電話株式会社 Content distribution system, content distribution method, content generation device, and content generation program
CN106534273A (en) * 2016-10-31 2017-03-22 中金云金融(北京)大数据科技股份有限公司 Block chain metadata storage system, and storage method and retrieval method thereof
CN107103405A (en) * 2017-03-22 2017-08-29 暨南大学 A kind of mass-rent system and its building method based on block chain technology
CN107103252A (en) * 2017-04-27 2017-08-29 电子科技大学 Data access control method based on block chain
CN107273410A (en) * 2017-05-03 2017-10-20 上海点融信息科技有限责任公司 Distributed storage based on block chain

Cited By (23)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109284197A (en) * 2018-10-25 2019-01-29 中思博安科技(北京)有限公司 Distributed Application platform and implementation method based on intelligent contract
CN109284197B (en) * 2018-10-25 2024-02-23 中思博安科技(北京)有限公司 Distributed application platform based on intelligent contract and implementation method
CN109542455A (en) * 2018-11-29 2019-03-29 杭州复杂美科技有限公司 Contract executes method, contract compressing method, equipment and storage medium
CN109542455B (en) * 2018-11-29 2021-08-06 杭州复杂美科技有限公司 Contract execution method, contract reduction method, device, and storage medium
CN112513853A (en) * 2018-12-11 2021-03-16 松下电器(美国)知识产权公司 Data management method, data management system, and program
CN109726249A (en) * 2018-12-12 2019-05-07 杭州基尔区块链科技有限公司 A kind of decentralization chip research and development transaction data storage method and system
CN109617964B (en) * 2018-12-12 2021-11-09 成都四方伟业软件股份有限公司 Big data storage method and device based on block chain
CN109726249B (en) * 2018-12-12 2020-06-09 杭州基尔区块链科技有限公司 Decentralized chip research and development transaction data storage method and system
WO2020118859A1 (en) * 2018-12-12 2020-06-18 杭州基尔区块链科技有限公司 Decentralized chip research and development transaction data storage method and system
CN109617964A (en) * 2018-12-12 2019-04-12 成都四方伟业软件股份有限公司 Big data storage method and device based on block chain
CN110020542A (en) * 2018-12-20 2019-07-16 阿里巴巴集团控股有限公司 Data read-write method and device, electronic equipment
US11200226B2 (en) 2018-12-20 2021-12-14 Advanced New Technologies Co., Ltd. Data read and write method and apparatus, and electronic device
CN110020542B (en) * 2018-12-20 2020-05-19 阿里巴巴集团控股有限公司 Data reading and writing method and device and electronic equipment
CN110109935A (en) * 2019-05-13 2019-08-09 北京共识数信科技有限公司 A kind of Gang Hang business alliance design method based on block chain
CN110147202A (en) * 2019-05-15 2019-08-20 杭州云象网络技术有限公司 A method of reducing block chain intelligence contract code storage volume
CN110363663A (en) * 2019-07-12 2019-10-22 深圳前海微众银行股份有限公司 Batch data processing method, device, equipment and storage medium based on block chain
CN110363663B (en) * 2019-07-12 2023-08-22 深圳前海微众银行股份有限公司 Block chain-based data batch processing method, device, equipment and storage medium
CN110427380A (en) * 2019-08-07 2019-11-08 北京艾摩瑞策科技有限公司 It is related to rent a house associated data processing method and its device of block chain
CN112200690A (en) * 2020-10-27 2021-01-08 西安纸贵互联网科技有限公司 Ship quality traceability system based on block chain
CN112507028A (en) * 2020-12-18 2021-03-16 杭州趣链科技有限公司 Data storage method, device, equipment and storage medium
CN112507028B (en) * 2020-12-18 2023-02-21 杭州趣链科技有限公司 Data storage method, device, equipment and storage medium
CN112988726A (en) * 2021-03-24 2021-06-18 北京百度网讯科技有限公司 Data management method and device, computer equipment and storage medium
CN112988726B (en) * 2021-03-24 2024-03-01 北京百度网讯科技有限公司 Method, device, computer equipment and storage medium for data management

Similar Documents

Publication Publication Date Title
CN108566420A (en) Data processing method, equipment and computer readable storage medium for block chain
CN110648138B (en) Transaction query and transaction data processing method, device and equipment based on block chain
CN107424069A (en) A kind of generation method of air control feature, risk monitoring and control method and apparatus
CN107025559A (en) A kind of method for processing business and device
CN110472438B (en) Transaction data processing and transaction inquiring method, device and equipment based on blockchain
CN107395665A (en) A kind of block chain service handling and business common recognition method and device
CN107450979A (en) A kind of block chain common recognition method and device
CN107679700A (en) Business flow processing method, apparatus and server
TWI684944B (en) Accounting method and device
CN105335389B (en) A kind of business method for visualizing and system
CN110503435A (en) Transaction method for early warning, device and equipment based on block chain
CN107329899A (en) A kind of application compatibility method of testing and device
US20210326871A1 (en) Resource transfer methods, apparatuses, devices, and systems
CN107016029A (en) A kind of processing method of business datum, apparatus and system
CN110264332A (en) The method, apparatus and electronic equipment that account is entered an item of expenditure in the accounts
CN109389412A (en) A kind of method and device of training pattern
CN105684027A (en) House resource verifying method and system for real estate network
CN108415792A (en) Disaster tolerance system, method, apparatus and equipment
CN109428900B (en) Data processing method and device
CN109241749A (en) Data encryption, machine learning model training method, device and electronic equipment
CN110264213A (en) A kind of processing method of information, device and equipment
CN108876382A (en) The method, apparatus and readable storage medium storing program for executing of digital certificate are handled on block chain
CN115563584B (en) Model training method and device, storage medium and electronic equipment
CN107066872A (en) Plug-in right control method and device, plug-in system
CN110489392A (en) Data access method, device, system, storage medium and equipment between multi-tenant

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
REG Reference to a national code

Ref country code: HK

Ref legal event code: DE

Ref document number: 1255844

Country of ref document: HK

WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20180921

WD01 Invention patent application deemed withdrawn after publication