Font Size: a A A

Research On The Consensus And Transaction Searching Of Traditional Chinese Medicine Tracing Blockchains

Posted on:2022-08-02Degree:MasterType:Thesis
Country:ChinaCandidate:Y Z ZhangFull Text:PDF
GTID:2491306500965419Subject:Software engineering
Abstract/Summary:PDF Full Text Request
Tracing the provenance of traditional Chinese medicine is of great significance to protect the brand and the interests of consumers.Blockchain has the characteristics of decentralization,immutability and traceability.So,it is an ideal choice fortraditional Chinese medicine tracing systems.In traditional blockchain systems,in order to protect the immutability of the data,data redundancy often causes the low efficiency of data searching.And with the running of the system,the redundancy will become more and more serious.Consensus mechanism is an important guarantee for the credibility of blockchains.However,traditional DPOS mechanism may cause some elected malicious nodes to tamper with part of the transaction information according to their own interests.At the same time,candidates elected by consensus may vote for each other,which can destroy the decentralization characteristics of blockchains.Therefore,take traditional Chinese medicine tracing as a background,the thesis will explore a blockchain discovery method for recently used nodes caching as well as a consensus mechanism that detect and scores nodes and dilutes the number of votes of the elected nodes.The following are the details of the improvements:(1)Combining LRU(Least Recently Used)mechanism with Kademlia node discovery algorithm,a transaction searching algorithm L-Kademlia is proposed.The algorithm can improve the searching efficiency of transactions and the hit rate of the first visit to the node.Experiments show that L-Kademlia can improve the first call hit rate to 85% to 90% compared to Kademlia,reduce the number of database calls Per Second,and improve TPS(Transaction Per Second)by an average of 62.1% compared to the original algorithm.In addition,in order to prevent data redundancy,the state database State DB is set on the light node that stores part of the information,which can improve the query efficiency of a node.At the same time,a Bloom Filter is set in each SPV node to quickly locate the specified transaction and avoid invalid block query.(2)Considering of the disadvantages of DPOS consensus mechanism,a consensus mechanism oriented to traditional Chinese medicine tracing is proposed.The transaction to be submitted by the decision node is broadcast,and other nodes will verify the authenticity of the node.At the same time,the Eigentrust node scoring algorithm is introduced to punish the node that made wrong decisions,so as to reduce the proportion such nodes.In 10,000 runs of consensus experiments,the positive score nodes of correct decisions accounted for 90.83% of the total decision,and the positive score nodes still operated correctly when the malicious nodes were more than 1/3.The number of correct decisions accounted for 90.97%,which is 28.25% higher than that of the original DPOS mechanism.Moreover,in order to prevent a node from being elected as a decision node frequently,the score of election nodes is diluted to avoid the occurrence of partial centralization.
Keywords/Search Tags:Traditional Chinese medicinal tracing, Blockchain, LRU mechanism, Kademlia algorithm, DPOS consensus
PDF Full Text Request
Related items