| In this era of "Internet of Everything",unmanned vending machine is a popular product in current IoT devices,and the Internet of Things of unmanned vending machines has correspondingly made businesses increasingly demanding IoT platforms.Since the existing Internet of Things(IoT)platforms on the market are mostly intelligent agriculture,Internet of Vehicles,health equipment and other related platforms,there is no IoT platform related to unmanned vending machines,so they are part of the IoT platform for unmanned vending machines.With the unmanned vending machine order service module,the demand for our product came into being.With the urging of the demand background,the design and development of the order service module for the unmanned vending machines IoT platform has become easier.The main work of this thesis realizes a solution based on the Web technology unmanned vending machine IoT platform order service module.This paper first analyzes the background,significance,application status,application purpose,content and the organization structure of the paper.Secondly,it gives an overview of the trusted order server,introduces the system objectives and problems to be solved and the demand acquisition mode,and analyzes the functional and non-functional requirements of the unmanned vending machine order service module.Then,based on the Internet of Things architecture,the overall architecture and detailed system of the unmanned vending machine order service module are designed.This paper is based on the Linux system,based on the idea that "Nginx+Gunicorn+Dj-ango+MySQL uses HTTP protocol to solve the problem of unmanned vending machine accessing the Internet of Things platform and realize sales",so that all kinds of unmanned vending machines can pass this the protocol connects to our IoT platform.The paper designs and implements the Order Server.The business functions on the order server mainly include the following parts:the trusted verification vending machine service module realizes the function of reporting the vending machine and providing the trusted service to the order server externally and internally.The order service module realizes the whole sales process of the vending machine,and the process of WeChat public order to notify the vending machine to sell.The message push module achieves the initialization of the vending machine(including the vending machine when the power supply is requested,the goods table,the replenishment table,the advertising table),the upgrade of the vending machine app and the contents of each vending machine(including product table,vending machine product relationship table,advertising table,log uploading table,cargo lane deactivation table,etc.).Timing mechanism uses third-party library django-crontab of Django to achieve scheduled tasks for database backup whose strategy is full backup + incremental backup + binary log.Log system achieves the interception of all levels of log.Reconciliation module achieves clear order.Heartbeat diagnosis achieves the status diagnosis of Server and vending machine and selling app.And RSAćAES combined decryption method ensures reliable data communication between servers,etc.This paper designs and implements the main functions of the order service module,and adopts the method of maintaining the thread pool to improve the performance and user experience of data communication between the order server and the unmanned vending machine,payment server,core server and background management server.Subsequently,the system performance was systematically tested.The test results show that the order server is reliable and stable enough. |