| As a national strategic resource,the quality and safety of agricultural products are of great concern to the public.The establishment of a perfect traceability system through the joint collaboration of enterprises in the whole agricultural products industry chain is of great significance for maintaining a healthy market environment and consumer rights.This thesis provides a reasonable analysis of existing traceability technologies at home and abroad.To address the problems of centralized data storage,opaque shared information and weak security performance of traditional traceability systems,this thesis makes full use of Io T and blockchain technologies to build a traceability optimization model and platform to improve information query efficiency and data security.The main work of this thesis is as follows:1.This thesis completes the overall architecture of agricultural product traceability system based on Internet of Things and blockchain technology.Firstly,it summarizes the organizational nodes of the complex supply chain,abstractes the core requirements of the traceability system,and maps them to the three sub-platforms of Io T monitoring,QR code identification and blockchain network.It integrates a high-quality universal traceability system,and provides different services for different users in the supply chain.2.This thesis implements the functions of Io T monitoring and QR code identification sub-platform for the overall architecture design.The Io T monitoring sub-platform adopts a combination of software and hardware,uses NB-Io T communication technology to upload sensor data to the cloud,and develops We Chat mini programs through JS SDK to provide farmers with real-time monitoring services for farmland environment.The QR code identification sub-platform uses PHP and My SQL databases as the underlying technologies to generate logistics codes and anti-counterfeiting QR codes for agricultural products,mainly serving logistics and transportation enterprises and consumers.The two sub-platforms provide users with more convenient management and query methods,and also provide a more reliable data source for the traceability system.3.This thesis implements the function of blockchain network sub-platform according to the overall architecture design.The platform adopts Hyperledger Fabric consortium chain technology scheme,uses Go language to write smart contracts,starts PBFT consensus mechanism,completes the front-end and back-end construction of web pages based on Ruo Yi-Vue and Spring Boot framework,focusing on serving regulatory authorities,processing enterprises and raw material manufacturers,the platform receives key data from the Internet of Things monitoring and two-dimensional code identification sub-platform through the interface,forming a complete traceability blockchain,so that the supply chain data has tamper-proof characteristics.4.This thesis proposes the blockchain division and multi-database storage structure of "main chain + child chain".According to the survey results,it summarizes 19 factors affecting traceability,uses DEMATEL-AISM fusion analysis method to construct an adversarial multi-level hierarchical structure model,and then divides 6 blockchain child chains,and stores data on different chains in different databases such as Couch DB,My SQL,Redis and Fast DFS,which reduces the storage pressure of the database to a certain extent.All in all,this thesis combines the traceability needs of agricultural products,and uses Hyperledger Fabric consortium chain combined with Internet of Things technology to design a set of traceability and anti-counterfeiting system that is superior to the traditional,credible,tamper-proof and decentralized,which provides basic information technology guarantee for safeguarding consumer rights and interests,and has certain research value. |