A method and system for processing order data based on blockchain
By identifying and processing high-frequency and low-frequency orders, using off-chain intelligent elastic rectification and on-chain transaction processing, the two-way timing synchronization and transmission channel optimization of order transactions is achieved, which solves the problem of inefficient order processing in the existing technology and improves the reliability and efficiency of order transactions.
Patent Information
- Application Number
- CN202510151597.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-11
- Publication Date
- 2025-05-06
- Estimated Expiration
- 2045-02-11
AI Technical Summary
In the prior art, order processing cannot be dynamically optimized according to the access frequency, resulting in inefficiency of the system, and delays or errors are prone to occur during cross-chain transactions or multi-channel transactions, affecting the reliability and efficiency of order transactions.
By obtaining multi-source order data sets, conducting transaction address analysis and server construction, identifying high-frequency and low-frequency orders, and using off-chain intelligent elastic rectifying transactions to process high-frequency orders, and on-chain transactions to process low-frequency orders, realizing two-way timing synchronization and transmission channel optimization of order transactions.
It improves the reliability and efficiency of order transactions, optimizes resource allocation, reduces processing delays and costs, and enhances the scalability and user experience of the system.
Smart Images

Figure CN119624590B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a blockchain-based order data processing method and system. Background Art
[0002] In the early days, traditional order data processing relied on centralized databases, which were vulnerable to single point failures, data tampering, and information asymmetry. As enterprises and consumers continue to increase their requirements for data security, transparency, and efficiency, blockchain technology has gradually become an important tool to solve these problems. Blockchain technology stores order information in multiple nodes in a decentralized manner, and each node has a complete copy of the order data to ensure data consistency and reliability. At the same time, the immutability of blockchain ensures the authenticity of order data and prevents malicious tampering and forgery. With the emergence of smart contracts, blockchain can not only store data, but also automatically execute order-related transactions and operations, which makes the order processing process more efficient, reduces intermediary links and human intervention, and reduces costs. However, in the current existing technology, the processing of orders is often uniform, and it is impossible to dynamically optimize the access frequency of orders. At the same time, when processing cross-chain transactions or multi-channel transactions, delays or errors are prone to occur, resulting in low reliability and efficiency of order transactions. Summary of the invention
[0003] Based on this, it is necessary to provide a blockchain-based order data processing method and system to solve at least one of the above technical problems.
[0004] To achieve the above purpose, a method for processing order data based on blockchain is provided, the method comprising the following steps:
[0005] Step S1: Acquire a multi-source order data set; perform transaction address analysis on the multi-source order data set to generate order transaction address data; construct an order processing server for the multi-source order data using the order transaction address data to generate order processing distribution server data;
[0006] Step S2: Perform order processing access frequency analysis on the multi-source order data set through the order processing distribution server data to generate order processing access frequency data; perform order screening on the multi-source order data set based on the order processing access frequency data to generate high-frequency order access data and low-frequency order access data; perform on-chain transaction processing on the low-frequency order access data to generate low-frequency order on-chain transaction processing data; perform off-chain intelligent elastic rectification transaction processing on the high-frequency order access data to generate high-frequency order off-chain transaction processing data;
[0007] Step S3: Perform bidirectional order transaction timing synchronization on the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data to generate order transaction synchronization data; optimize the transmission channel of the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data according to the order transaction synchronization data, thereby generating order synchronization feedback data;
[0008] Step S4: Confirm the order transaction result of the order synchronization feedback data to obtain order transaction result confirmation data; upload the order transaction result confirmation data to the cloud platform for data visualization, thereby generating an order transaction completion report.
[0009] The present invention integrates multi-source order data sets and analyzes transaction addresses to generate order transaction address data, which can effectively solve the data island problem and realize unified processing and management of multi-source data. By building an order processing server and generating distributed server data, the scalability and efficient processing capabilities of the system are ensured. Through order access frequency analysis, high-frequency and low-frequency orders can be identified, resource allocation can be optimized, and the efficiency of order processing can be improved. High-frequency orders are processed by off-chain intelligent elastic rectification transactions, which reduces the pressure of on-chain transactions and improves the processing speed; low-frequency orders are processed by on-chain transactions to ensure the transparency and security of their processing. Through two-way timing synchronization, it is ensured that the data of low-frequency order on-chain and high-frequency order off-chain transactions can be accurately and consistently synchronized, avoiding delays and confusion. Transmission channel optimization improves data transmission efficiency, reduces bandwidth occupancy and transmission delay, thereby improving the overall performance of the system. By confirming the order transaction results, the accuracy and validity of the transaction data are ensured, and the risk of transaction errors and information inconsistency is reduced. Uploading the order transaction results to the cloud platform for visualization not only improves the transparency of the transaction, but also provides real-time monitoring and decision support for managers, enhancing user experience and system credibility. Therefore, the present invention improves the reliability and efficiency of order transactions by optimizing multi-source data integration, order access frequency analysis, transaction synchronization and channel optimization.
[0010] Preferably, step S1 comprises the following steps:
[0011] Step S11: Acquire a multi-source order data set;
[0012] Step S12: performing data preprocessing on the multi-source order data set to generate a standard multi-source order data set, wherein the data preprocessing includes data cleaning, data denoising, data missing value filling and data standardization;
[0013] Step S13: performing transaction address analysis on the standard multi-source order data set to generate order transaction address data, wherein the order transaction address data includes order initiation address data and order receiving address data;
[0014] Step S14: Deploy order service nodes for standard multi-source order data through order initiation address data and order receiving address data to generate order service node deployment data; construct order processing servers for standard multi-source order data through order service node deployment data to generate order processing distribution server data.
[0015] The present invention can eliminate noise and inconsistency in data through data preprocessing and standardization, ensure the quality of data, and thus improve the efficiency of subsequent analysis and processing. The preprocessed data helps to reduce errors and redundancy, and improve the accuracy and speed of order processing. By analyzing the order initiation and receiving addresses, the geographical location and transaction mode can be accurately identified, which helps to deploy order services at the most suitable nodes, thereby improving the response speed and reliability of order processing, especially in a distributed environment. By establishing an order processing distribution server system, processing resources can be dynamically adjusted according to the distribution of order data, single point failures can be avoided, and the fault tolerance and scalability of the system can be improved, which ensures that the system can still run smoothly under high load conditions. Optimized node deployment and distributed server systems can significantly reduce order processing delays, improve the speed of user order completion, thereby improving user experience, and enhancing user satisfaction and platform loyalty. Through reasonable server resource allocation and distributed processing, waste of resources can be avoided, system operation and maintenance costs can be reduced, and the utilization rate of overall resources can be improved, thereby achieving cost savings.
[0016] Preferably, step S14 comprises the following steps:
[0017] Step S141: Performing geographic cluster analysis on standard multi-source order data through order initiation address data and order receiving address data to generate geographic address cluster data; performing regional order volume and processing demand calculation based on the geographic address cluster data to generate service node demand data;
[0018] Step S142: performing node candidate analysis on the service node demand data to generate server node candidate data; performing server distribution optimization on the standard multi-source order data to generate server distribution optimization data; performing server deployment on the standard multi-source order data according to the server node candidate data and the server distribution optimization data to generate order service node deployment data;
[0019] Step S143: Dynamically load detect the standard multi-source order data through the order service node deployment data to generate server dynamic load detection data; elastically expand the server for the order service node deployment data according to the server dynamic load detection data to generate order processing distribution server data.
[0020] The present invention can classify orders by geographical regions by performing geographic cluster analysis on the initiation address and the receiving address of the order. This analysis helps to identify the order volume and processing requirements of different regions, so that the service nodes can be deployed more reasonably to ensure that sufficient processing capacity is provided in high-demand areas. By calculating the service node demand data, more accurate resource allocation can be achieved, the response speed of the system can be improved, and the order processing process can be optimized. Node candidate analysis helps determine the best server nodes that can be used for order processing, ensuring that these nodes can meet the needs of order processing both geographically and in terms of demand. Through server distribution optimization, the load between each node can be balanced to avoid excessive concentration or idleness of resources, thereby improving the overall operating efficiency of the system. This optimization ensures the reasonable allocation of server resources and helps to improve the scalability and reliability of the system. Through dynamic load detection, the load of each server node can be monitored in real time to ensure timely identification and adjustment of resources during peak periods. At nodes with higher loads, the system can be elastically expanded and automatically increase processing capacity to cope with increased order traffic. This elastic expansion mechanism not only improves the processing capacity of the system, but also ensures that the system can remain stable under different loads to avoid performance degradation or service interruption caused by excessive load. Through real-time load detection and elastic expansion, the system can adapt to different load conditions, ensuring smooth operation during peak traffic periods and reducing the risk of downtime and response delays. Through geographic clustering analysis and server distribution optimization, it can ensure that server node resources are reasonably allocated, avoid over-concentration and waste of idle resources, and improve the resource utilization of the overall system.
[0021] Preferably, step S2 comprises the following steps:
[0022] Step S21: performing order processing access frequency analysis on the multi-source order data set through the order processing distribution server data to generate order processing access frequency data;
[0023] Step S22: Compare the order processing access frequency data with the preset standard order access frequency threshold. When the order processing access frequency data is greater than or equal to the preset standard order access frequency threshold, the corresponding multi-source order data set is marked as high-frequency order access data; when the order processing access frequency data is less than the preset standard order access frequency threshold, the corresponding multi-source order data set is marked as low-frequency order access data;
[0024] Step S23: Perform on-chain transaction processing on the low-frequency order access data based on blockchain technology to generate low-frequency order on-chain transaction processing data;
[0025] Step S24: Perform off-chain intelligent elastic rectification transaction processing on the high-frequency order access data to generate high-frequency order off-chain transaction processing data.
[0026] The present invention can accurately measure the access frequency of each order by analyzing the order access frequency of the order processing distribution server data, which helps to identify active orders and low-frequency orders in the system. Through the analysis of the access frequency data, the system can better understand the flow trend of the order and provide a basis for subsequent processing and resource allocation. Comparing the order access frequency data with the preset standard access frequency threshold can help the system divide the order into high-frequency access data and low-frequency access data. This classification helps to adopt different strategies for different types of orders in the subsequent processing process. For example, high-frequency orders can be given priority and more resource allocation, while low-frequency orders can be processed in different ways, thereby improving the efficiency of the overall system. Through blockchain technology, on-chain transaction processing of low-frequency order data can ensure the data security, transparency and non-tamperability of low-frequency orders. Blockchain provides a highly reliable and decentralized trading platform for low-frequency orders, ensuring that the processing records and transaction history of orders can be permanently preserved, and enhancing the traceability and anti-tampering capabilities of data. For low-frequency orders, blockchain processing can reduce processing delays and provide higher benefits in terms of cost. Off-chain intelligent elastic rectification transaction processing for high-frequency orders can optimize the processing efficiency of high-frequency orders by using smart contracts and elastic resource scheduling without relying on blockchain. This processing method can quickly respond to changes in demand for high-frequency orders by dynamically adjusting the system load, ensuring that the system can flexibly expand resources during peak periods while reducing the cost and delay of transaction processing. By distinguishing between high-frequency and low-frequency orders and adopting targeted processing strategies, the system can optimize resource allocation and improve processing efficiency. High-frequency orders are given priority and elastically expanded, while low-frequency orders can be processed at low cost and safely through blockchain. The application of blockchain technology ensures that the data processing of low-frequency orders is highly secure and tamper-proof, providing more reliable data protection for the business. Intelligent elastic rectification transaction processing helps the high-frequency order processing system to adjust dynamically, reducing unnecessary waste of resources and system overload, thereby reducing system operating costs.
[0027] Preferably, step S23 includes the following steps:
[0028] Step S231: extracting key features of low-frequency order access data to obtain key feature data of low-frequency orders, wherein the extracted key features of orders include order type, geographic location of initiation and receipt, payment method, and commodity category; labeling the low-frequency order access data based on the key feature data of low-frequency orders to generate an order feature label data set;
[0029] Step S232: assigning order priorities to the multi-source order data sets to generate order priority data; uploading the order priority data to a block chain according to the order feature tag data sets to generate low-frequency order up-chain storage data;
[0030] Step S233: Create on-chain transaction records for the low-frequency order on-chain storage data through the smart contract built into the blockchain to generate order on-chain transaction record data; perform hash encryption on the order on-chain transaction record data to generate blockchain encrypted transaction record data;
[0031] Step S234: Perform transaction consensus verification on the blockchain encrypted transaction record data to generate low-frequency order chain transaction processing data.
[0032] The present invention can deeply understand the characteristics of each order by extracting key features of low-frequency orders, including order type, geographic location of initiation and receipt, payment method and commodity category. This feature extraction allows orders to be classified and labeled more accurately. After the order is labeled, it is helpful to accurately identify and operate in the subsequent blockchain storage and smart contract processing. This processing method improves the structured level of order data and provides a clear foundation for subsequent blockchain processing and smart contract applications. Order priority allocation for multi-source order data sets can ensure that high-priority orders obtain more resources and faster processing speeds. In combination with the order feature label data set, the order priority data is stored on the blockchain, which can ensure that the processing priority of the order and its related data are transparent and cannot be tampered with on the chain, thereby ensuring the fairness and security of order processing. This process improves the transparency of order management and provides clear records and traceability for subsequent processing operations. Through the built-in smart contract of the blockchain, the transaction processing process of the order can be automated and standardized. Smart contracts not only ensure the legitimacy of the transaction, but also can realize trust verification without intermediaries, reducing manual intervention. The hash encryption processing of transaction record data enhances the privacy and security of order data, prevents data leakage or tampering, and provides a high degree of security for transactions of low-frequency orders. By verifying the transaction consensus of blockchain encrypted transaction record data, it can ensure that the transaction records in the blockchain are consistent in the distributed network, further enhancing the credibility and reliability of the transaction. Through the consensus mechanism, the system can exclude malicious transactions and ensure that the transaction records of low-frequency orders are valid and recognized by the entire network in the blockchain. Transaction consensus verification improves the system's anti-tampering ability and ensures the consistency and correctness of transaction records. Through hash encryption and blockchain technology, it ensures that the transaction records of low-frequency orders are tamper-proof and highly secure, effectively prevents data leakage or tampering, and improves the privacy protection of user data. Order priority allocation and blockchain storage make the order processing process more transparent, prevent human interference or favoritism, and ensure the fairness and fairness of order processing.
[0033] Preferably, step S24 includes the following steps:
[0034] Step S241: Performing an external server time request on the high-frequency order access data to obtain external server request time data; performing time deviation calculation on the external server request time data and the local clock in the order processing distribution server to obtain request time deviation data;
[0035] Step S242: performing short-term cumulative trend analysis on the request time deviation data to generate short-term cumulative trend data; performing clock drift detection on the high-frequency order access data based on the short-term cumulative trend data to generate clock drift detection data;
[0036] Step S243: performing sliding window compensation on the high-frequency order access data according to the clock drift detection data to generate high-frequency order access time compensation data; performing lightweight order processing flow optimization on the high-frequency order access data by using the high-frequency order access time compensation data to generate high-frequency order processing data;
[0037] Step S244: Transaction traffic rectification is performed on the high-frequency order processing data to generate high-frequency order transaction traffic rectification data; high-frequency order transaction traffic rectification data is used to perform flexible priority scheduling on the high-frequency order access data, thereby generating high-frequency order off-chain transaction processing data.
[0038] The present invention can accurately detect the request time deviation caused by time synchronization problems by calculating the time deviation between the external server time request and the local clock. This process ensures that the order processing system has a consistent time base between different servers, laying a foundation for the precise scheduling and processing of subsequent operations. The accuracy of time deviation calculation can effectively avoid system delays or errors caused by time asynchrony, and enhance the timeliness and reliability of the system. Through short-term cumulative trend analysis, the changing trend of time deviation over time can be quickly identified, and the clock drift problem can be discovered in time. Clock drift detection is performed on high-frequency order access data, and problems caused by system clock asynchrony or drift can be accurately detected, thereby preventing processing delays or errors caused by clock drift. This precise detection mechanism effectively improves the timeliness and accuracy of high-frequency order processing, and ensures data synchronization and system stability. Based on the clock drift detection data, the timing is adjusted by the sliding window compensation technology to ensure that the time accuracy of high-frequency order access data is restored. By optimizing the time compensation data, the problem of high-frequency order flow imbalance caused by time drift can be avoided. Lightweight order processing traffic optimization can effectively balance the order processing load, improve system processing efficiency, and reduce additional resource consumption caused by time synchronization problems, ensuring fast and efficient processing of high-frequency orders. Transaction traffic rectification of high-frequency order processing data can smooth transaction traffic fluctuations and avoid system overload or delay caused by traffic shocks during peak periods. Through elastic priority scheduling based on traffic rectification data, the processing priority of orders can be dynamically adjusted to ensure that important orders are processed in a timely manner, while effectively allocating system resources. This optimization measure improves the flexibility and efficiency of order processing and ensures the smooth operation of the system under different loads. Through precise time deviation calculation and clock drift detection, the time synchronization of different servers is ensured, reducing data processing delays or errors caused by clock errors. Sliding window compensation and lightweight traffic optimization ensure efficient processing of high-frequency orders, avoid uneven load caused by traffic fluctuations, and improve order processing efficiency.
[0039] Preferably, step S3 comprises the following steps:
[0040] Step S31: Integrate the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data to generate order transaction integration data;
[0041] Step S32: performing order transaction bidirectional time synchronization on the order transaction integration data to generate order transaction synchronization data; performing order sending timestamp confirmation on the order transaction integration data according to the order transaction synchronization data to obtain the order sending timestamp;
[0042] Step S33: Synchronize the order transaction integration data with the order initiation address data and the order receiving address data to generate order transaction transmission data; confirm the receiving timestamp of the order transaction transmission data to obtain the seller receiving timestamp and the buyer receiving timestamp;
[0043] Step S34: Use the order sending timestamp to confirm the time interval between the seller receiving timestamp and the buyer receiving timestamp to obtain the order transmission time interval data; optimize the transmission channel of the order transaction transmission data according to the order transmission time interval data, thereby generating order synchronization feedback data.
[0044] The present invention can create a unified order transaction data set by integrating the transaction processing data on the low-frequency order chain and the transaction processing data off the high-frequency order chain. This integration process helps to eliminate the differences between different data sources, making subsequent data processing more efficient, avoiding data redundancy or inconsistency, and improving the overall accuracy and efficiency of the system in processing order transactions. By performing two-way timing synchronization on the order transaction integration data, it is ensured that the timestamps of the order at different processing stages (such as initiation and reception) are accurate and consistent. This timing synchronization can eliminate the problems caused by time differences, so that the life cycle of the order can be accurately recorded and tracked in time, effectively avoiding the loss, delay or repeated processing of orders caused by timing mismatch. At the same time, the confirmation of the order sending timestamp ensures the consistency of the transaction time and improves the traceability of the transaction data. By synchronously transmitting the order transaction according to the order initiation address and the receiving address data, the data consistency and smoothness of the order during the transmission process can be ensured. Confirming the receiving timestamp of the transaction data helps to accurately record the receiving time of the order and provide accurate data support for subsequent analysis and optimization. At the same time, the confirmation of sellers and buyers receiving timestamps further enhances the monitorability of the order transmission process and improves the transparency and reliability of the system. By confirming the transmission time interval of the order, the timeliness of the order during the transmission process can be accurately evaluated, and delay problems can be discovered and solved in a timely manner. Optimizing the transmission channel of the order according to the transmission time interval data can further improve the data transmission efficiency, reduce delays, and improve the smoothness of order processing. The optimized transmission channel not only improves the speed of order synchronization feedback, but also enhances the overall response capability of the system to ensure the smooth progress of high-frequency and high-concurrency transactions. By integrating low-frequency and high-frequency order data, two-way timing synchronization, timestamp confirmation and other steps, the consistency and accuracy of order transaction data can be ensured, avoiding data inconsistency and error accumulation problems. By confirming the time interval and optimizing the transmission channel, the timeliness and response speed of order transmission can be effectively improved, and processing delays caused by delays or transmission bottlenecks can be reduced. Through accurate timestamp confirmation and synchronization mechanism, a complete order life cycle record is provided, providing data support for subsequent order tracking, troubleshooting and optimization.
[0045] Preferably, performing bidirectional time-series synchronization of order transaction integration data includes:
[0046] An order time window is set for the order transaction integration data to obtain an order processing time window; the order processing time is confirmed for the order processing time window to obtain order processing time data; the order processing time data is compared with the order processing time window, and when the order processing time data is within the order processing time window, the order transaction integration data is segmented based on the order processing time data to generate an order transaction data packet;
[0047] When the order processing time data is outside the order processing time window, the order transaction integration data is rescheduled until the order processing time data is within the order processing time window, and an order transaction data packet is generated;
[0048] The transaction timing of the order transaction data packet is bidirectionally confirmed according to the order initiation address data and the order receiving address data, thereby generating order transaction synchronization data.
[0049] The present invention can limit the processing time of the order within a predetermined time range by setting the order time window for the order transaction integration data, ensuring that each order is processed within a reasonable time. This mechanism enables the system to accurately control the timeliness of order processing and provide an effective time frame for subsequent data sharding and scheduling. By confirming the order processing time, it can ensure that the processing time of each order is consistent with the set time window, reducing delays or errors caused by time deviations. When the order processing time is within the predetermined time window, data sharding is performed based on accurate order processing time data to generate order transaction data packets, which helps to improve the efficiency of data transmission, ensure that each data packet can be processed within the correct time range, and avoid data redundancy or processing delays. At the same time, when the order processing time is outside the time window, the processing sequence rescheduling technology is adopted, and the order can be dynamically scheduled to ensure that the order is processed at the right time, avoid timeouts or resource conflicts, and improve the flexibility and adaptability of the system. The order transaction data packet is bidirectionally confirmed through the order initiation address data and the order receiving address data, which can ensure that the order timing from initiation to reception is completely consistent. This confirmation mechanism effectively avoids the problem of timing disorder and ensures the smoothness and accuracy of order transactions. This operation increases the traceability of the system and the consistency of data, and provides guarantees for data verification, backtracking and auditing in the transaction process. After precise timing synchronization and data sharding, the order transaction integration data can improve the overall processing efficiency of the system on the basis of ensuring data processing accuracy. Timing rescheduling and bidirectional timing confirmation avoid potential delays and errors in order processing and improve the system's response speed and stability to high-frequency order processing. Through the setting and confirmation mechanism of the time window, it ensures that the order is processed within a reasonable time, avoiding the system burden and delay caused by too long time. Through timing rescheduling, the system can flexibly adjust the order processing timing to cope with changes in the processing time of different orders, improving the system's fault tolerance.
[0050] Preferably, step S4 comprises the following steps:
[0051] Step S41: confirming the order transaction result of the order synchronization feedback data to obtain order transaction result confirmation data; uploading the order transaction result confirmation data to the cloud platform for transaction completion data storage to generate order transaction completion data;
[0052] Step S42: Visualize the order transaction completion data to generate an order transaction completion report.
[0053] The present invention confirms the order transaction results of the order synchronization feedback data, and the system can effectively verify the processing results of each order, ensuring that all orders are fully confirmed at the end of the process. The implementation of this step ensures the accurate recording of the transaction status and avoids the situation of unfinished orders or transaction omissions. By uploading the order transaction result confirmation data to the cloud platform and storing the transaction completion data, not only the safe storage of the data is ensured, but also the centralized management of the data is realized. The data storage of the cloud platform has high reliability and scalability, which is convenient for subsequent data retrieval and analysis, and improves the overall efficiency and maintainability of the system. The generation and storage of order transaction completion data provides comprehensive data support for subsequent analysis, review and audit. In addition, by visualizing the order transaction completion data, the key information such as the completion status, transaction volume, and processing time of the order can be clearly displayed. The visual report enables business personnel and managers to quickly understand the efficiency and accuracy of order processing, assist decision-making and optimize management processes. Visual display in the form of charts, trend analysis, etc. helps to improve the ability to interpret data and the scientific nature of decision-making. The visual order transaction completion report provides higher transparency, which is convenient for relevant personnel to track and review the order status. Through clear and intuitive data display, managers can better understand the bottlenecks and efficient links in the transaction process, thereby providing a basis for the formulation of subsequent optimization strategies. This process helps the accuracy and timeliness of business decisions and improves the effectiveness of overall business operations. Uploading and storing order transaction results to the cloud platform effectively realizes permanent storage and efficient retrieval of data. This storage method provides sufficient data support for future audits, dispute resolution, historical backtracking, etc. Whether it is a query on the transaction status of a specific order or a backtracking of the overall order processing process, the data storage and management system provided by the cloud platform can effectively support it.
[0054] In this specification, a blockchain-based order data processing system is provided, which is used to execute the above-mentioned blockchain-based order data processing method. The blockchain-based order data processing system includes:
[0055] The server building module is used to obtain multi-source order data sets; perform transaction address analysis on the multi-source order data sets to generate order transaction address data; construct an order processing server for the multi-source order data through the order transaction address data to generate order processing distribution server data;
[0056] The order layering processing module is used to analyze the order processing access frequency of multi-source order data sets through the order processing distribution server data to generate order processing access frequency data; perform order screening on the multi-source order data sets based on the order processing access frequency data to generate high-frequency order access data and low-frequency order access data; perform on-chain transaction processing on the low-frequency order access data to generate low-frequency order on-chain transaction processing data; perform off-chain intelligent elastic rectification transaction processing on the high-frequency order access data to generate high-frequency order off-chain transaction processing data;
[0057] The timing synchronization module is used to perform bidirectional timing synchronization of low-frequency order on-chain transaction processing data and high-frequency order off-chain transaction processing data to generate order transaction synchronization data; based on the order transaction synchronization data, the transmission channel of low-frequency order on-chain transaction processing data and high-frequency order off-chain transaction processing data is optimized to generate order synchronization feedback data;
[0058] The order storage module is used to confirm the order transaction results of the order synchronization feedback data and obtain the order transaction result confirmation data; the order transaction result confirmation data is uploaded to the cloud platform for data visualization, thereby generating an order transaction completion report.
[0059] The beneficial effect of the present invention is that by acquiring a multi-source order data set and performing transaction address analysis, the source and receiving location of the order can be fully understood, ensuring the accuracy and comprehensiveness of the order processing process. The implementation of this step makes the distribution and flow of order data clear at a glance, optimizing the order processing process. Building an order processing server based on transaction address data not only ensures the efficient operation of the order processing system, but also realizes the flexible scheduling of server resources. According to the distribution of order data, the system can dynamically build and adjust the processing server to improve the scalability and resource utilization efficiency of the system. Through the order processing access frequency analysis, high-frequency and low-frequency orders can be accurately identified, so as to carry out different processing strategies, which helps to reasonably allocate resources, reduce the burden on the server, and avoid performance bottlenecks in the processing process. Low-frequency orders ensure the transparency and immutability of data through on-chain processing, while high-frequency orders are processed through off-chain intelligent elastic rectification, which optimizes the efficiency and response speed of transaction processing. This processing strategy greatly improves the processing capacity of high-frequency transactions while ensuring the security of low-frequency transactions. Through the two-way timing synchronization of order transactions, the order and integrity of transaction data are ensured, the loss and duplication of data are avoided, and the consistency and accuracy of transactions are improved. This step effectively reduces transaction conflicts caused by timing asynchrony. The transmission channel of transaction data is optimized to ensure the efficient transmission of order synchronization feedback. By reducing delays and improving the reliability of data transmission, the entire transaction processing process is optimized and the response speed of the system is improved. Through the confirmation of order transaction results, it can ensure that each transaction is confirmed and stored in the system, effectively reducing the risk of transaction disputes and misoperation. This process enhances the transparency and traceability of the transaction process. Uploading the transaction result confirmation data to the cloud platform for visualization not only allows managers to monitor the completion of order transactions in real time, but also enables business analysis through data charts to help managers quickly identify potential problems and optimization strategies. The generation of order transaction completion reports enables business personnel to intuitively understand the processing efficiency, completion status and existing problems of the overall order, providing strong support for subsequent decision-making, adjustment and optimization. Therefore, the present invention improves the reliability and efficiency of order transactions by optimizing multi-source data integration, order access frequency analysis, transaction synchronization and channel optimization. BRIEF DESCRIPTION OF THE DRAWINGS
[0060] Figure 1 A flowchart of a method for processing order data based on blockchain;
[0061] Figure 2 for Figure 1 Detailed implementation steps of step S2 in the flowchart;
[0062] Figure 3 for Figure 1 Detailed implementation steps of step S3 in FIG.
[0063] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0064] The technical method of the present invention is described clearly and completely below in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by technicians in this field without creative work are within the scope of protection of the present invention.
[0065] In addition, the accompanying drawings are only schematic illustrations of the present invention and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. The functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor methods and / or microcontroller methods.
[0066] It should be understood that although the terms "first", "second", etc. may be used herein to describe various units, these units should not be limited by these terms. These terms are used only to distinguish one unit from another. For example, without departing from the scope of the exemplary embodiments, a first unit may be referred to as a second unit, and similarly, a second unit may be referred to as a first unit, and the term "and / or" used herein includes any and all combinations of one or more of the listed associated items.
[0067] To achieve this, please refer to Figures 1 to 3 , a method for processing order data based on blockchain, the method comprising the following steps:
[0068] Step S1: Acquire a multi-source order data set; perform transaction address analysis on the multi-source order data set to generate order transaction address data; construct an order processing server for the multi-source order data using the order transaction address data to generate order processing distribution server data;
[0069] Step S2: Perform order processing access frequency analysis on the multi-source order data set through the order processing distribution server data to generate order processing access frequency data; perform order screening on the multi-source order data set based on the order processing access frequency data to generate high-frequency order access data and low-frequency order access data; perform on-chain transaction processing on the low-frequency order access data to generate low-frequency order on-chain transaction processing data; perform off-chain intelligent elastic rectification transaction processing on the high-frequency order access data to generate high-frequency order off-chain transaction processing data;
[0070] Step S3: Perform bidirectional order transaction timing synchronization on the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data to generate order transaction synchronization data; optimize the transmission channel of the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data according to the order transaction synchronization data, thereby generating order synchronization feedback data;
[0071] Step S4: Confirm the order transaction result of the order synchronization feedback data to obtain order transaction result confirmation data; upload the order transaction result confirmation data to the cloud platform for data visualization, thereby generating an order transaction completion report.
[0072] The present invention integrates multi-source order data sets and analyzes transaction addresses to generate order transaction address data, which can effectively solve the data island problem and realize unified processing and management of multi-source data. By building an order processing server and generating distributed server data, the scalability and efficient processing capabilities of the system are ensured. Through order access frequency analysis, high-frequency and low-frequency orders can be identified, resource allocation can be optimized, and the efficiency of order processing can be improved. High-frequency orders are processed by off-chain intelligent elastic rectification transactions, which reduces the pressure of on-chain transactions and improves the processing speed; low-frequency orders are processed by on-chain transactions to ensure the transparency and security of their processing. Through two-way timing synchronization, it is ensured that the data of low-frequency order on-chain and high-frequency order off-chain transactions can be accurately and consistently synchronized, avoiding delays and confusion. Transmission channel optimization improves data transmission efficiency, reduces bandwidth occupancy and transmission delay, thereby improving the overall performance of the system. By confirming the order transaction results, the accuracy and validity of the transaction data are ensured, and the risk of transaction errors and information inconsistency is reduced. Uploading the order transaction results to the cloud platform for visualization not only improves the transparency of the transaction, but also provides real-time monitoring and decision support for managers, enhancing user experience and system credibility. Therefore, the present invention improves the reliability and efficiency of order transactions by optimizing multi-source data integration, order access frequency analysis, transaction synchronization and channel optimization.
[0073] In the embodiment of the present invention, reference Figure 1As shown, it is a schematic diagram of the steps of a method for processing order data based on blockchain of the present invention. In this example, the method for processing order data based on blockchain includes the following steps:
[0074] Step S1: Acquire a multi-source order data set; perform transaction address analysis on the multi-source order data set to generate order transaction address data; construct an order processing server for the multi-source order data using the order transaction address data to generate order processing distribution server data;
[0075] In an embodiment of the present invention, order data is obtained in real time by integrating with API interfaces of different sales platforms, payment systems or logistics service providers. Historical order data is obtained by database or file import. The data is in CSV, Excel, JSON and other formats. Real-time order information is obtained from different data sources through streaming data transmission (such as Kafka, Webhooks, etc.). Data cleaning and preprocessing are performed on the obtained multi-source order data set, including: removing duplicate order records. Filling missing data fields or deleting incomplete orders. Unifying the data from different sources into a unified format, such as a unified timestamp format, a unified address field structure, etc. Extracting the shipping address and the receiving address from the order data, these address data usually include geographical information of the address, such as provinces, cities, postal codes, detailed addresses, etc. Converting the address information into standardized geographical coordinates (longitude and latitude) through geocoding technology. For example, converting the address into longitude and latitude data through Google Maps API or OpenStreetMap. Converting address data in different formats or languages into a unified standard format. For example, using Chinese or English uniformly and unifying the writing of provinces, cities and districts. According to the geographic coordinates of the shipping and receiving addresses, clustering analysis (such as K-means, DBSCAN, etc.) is used to cluster orders with similar geographical locations, which can help determine the areas where orders are concentrated. Based on the clustering results, the geographic hotspot area data of order transactions can be generated to identify high-density order transaction areas, which has important reference value for subsequent server deployment. Through geographic analysis, the transaction address data of each order is generated, including the shipping address, the receiving address and their corresponding geographic coordinates and clustering information. Using the order transaction address data, especially the geographic hotspot area data, the server can be planned and built. For example, areas with dense orders can select nearby server nodes to improve order processing efficiency and response speed. Analyze the order data of different geographical areas and generate a list of server node candidates. These candidate nodes can be: deployed server nodes, server nodes that need to be newly built (based on areas with dense order volume). According to the number and frequency of orders in each area, predict the computing resources required for each area and determine the load of each server. Adjust the distribution of servers according to the predicted load balancing requirements. For example, areas with large order volumes can deploy multiple server nodes to ensure efficient order processing. The analyzed server node information, load balancing configuration and geographical area information are integrated to generate order processing distribution server data. This data includes: the processing server node identification of each order, the geographical location and resource configuration of each server node, and the workload of each regional server.
[0076] Step S2: Perform order processing access frequency analysis on the multi-source order data set through the order processing distribution server data to generate order processing access frequency data; perform order screening on the multi-source order data set based on the order processing access frequency data to generate high-frequency order access data and low-frequency order access data; perform on-chain transaction processing on the low-frequency order access data to generate low-frequency order on-chain transaction processing data; perform off-chain intelligent elastic rectification transaction processing on the high-frequency order access data to generate high-frequency order off-chain transaction processing data;
[0077] In an embodiment of the present invention, by acquiring order processing distribution server data, including order processing records, access logs, timestamps of processing requests, etc. of each server node. The access frequency of each order can be calculated by counting the number of accesses within a certain time window. For example, the number of accesses to each order in the past hour or day can be counted as an indicator of access frequency. According to the records of the order processing distribution server, the number of accesses to each order in a specific time period is counted. For example, SQL queries or big data processing frameworks (such as Apache Spark) are used to aggregate order access logs. The access frequency of the order is calculated and its distribution is analyzed. The access frequency data of each order can be generated to further analyze the distribution of orders with different frequencies. Based on the above analysis, the access frequency data of each order is generated, and these data will provide a basis for subsequent screening and processing. Orders whose access frequency exceeds a preset threshold within a specified time window usually need to be processed first to ensure that the system can respond to customer needs in a timely manner. Orders whose access frequency is lower than the preset threshold within a specified time window have low processing requirements and can be processed through flexible strategies. Set a threshold for access frequency according to business needs. For example, if an order has been accessed more than 50 times in the past 24 hours, it is considered a high-frequency order, otherwise it is a low-frequency order. According to the access frequency data of each order, it is compared with the preset threshold to screen out high-frequency orders and low-frequency orders. Orders that meet the high-frequency condition are marked as "high-frequency orders" and stored in the high-frequency order data set. Orders that meet the low-frequency condition are marked as "low-frequency orders" and stored in the low-frequency order data set. On-chain transaction processing uses blockchain technology to manage low-frequency orders to ensure the transparency, immutability and security of transactions. By putting low-frequency order data on the chain, the transaction information of the order can be recorded, such as order creation, modification, transaction status, etc. Extract the key features of low-frequency orders, such as order number, product information, transaction time, shipping address, receiving address, etc. Standardize these feature data to ensure that they can be correctly stored and transmitted on the blockchain. Use blockchain technology (such as Ethereum, Hyperledger, etc.) to put the transaction information of low-frequency orders on the chain through smart contracts. Through the smart contract on the blockchain, the transaction information of each low-frequency order is generated into an on-chain transaction record and stored in the blockchain. The transaction record data is encrypted and hashed to ensure the security and integrity of the data. After completing the on-chain transaction record, the on-chain transaction processing data of the low-frequency order is generated, including the encrypted transaction record of the order and the storage information on the blockchain. The processing of high-frequency orders requires a more efficient and real-time transaction processing strategy. Off-chain intelligent elastic rectification transaction processing optimizes system performance by dynamically adjusting the order processing strategy to ensure the smooth processing of high-frequency orders.Obtain the time difference (deviation data) from the local clock through an external server request, for example, obtain an external timestamp, calculate the deviation of the request time, and synchronize the system time. Perform a short-term cumulative trend analysis on the deviation of the request time to derive the timing trend of high-frequency orders. Based on the clock drift detection results, a sliding window compensation mechanism is used to adjust the processing time of high-frequency orders. The sliding window algorithm is used to compensate for the order access time to avoid data processing errors caused by system time asynchrony. According to the compensated time data, the order is optimized for traffic processing, and an elastic priority scheduling algorithm is used to ensure that high-frequency orders can be processed in a timely manner. Using the intelligent elastic rectification mechanism, the order processing strategy and priority are adjusted in real time to optimize system resource allocation and processing efficiency. The optimization processing results of high-frequency orders are used to generate off-chain transaction processing data, which includes processed order information, traffic optimization results, and priority scheduling information.
[0078] Step S3: Perform bidirectional order transaction timing synchronization on the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data to generate order transaction synchronization data; optimize the transmission channel of the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data according to the order transaction synchronization data, thereby generating order synchronization feedback data;
[0079] In the embodiment of the present invention, the timestamp data of low-frequency orders and high-frequency orders (such as order sending time and receiving time) are extracted for comparative analysis. Low-frequency orders usually rely on the timestamp on the blockchain, while high-frequency orders rely on the local clock of the off-chain system. A global time window is set to synchronize the timestamps of low-frequency orders and high-frequency orders within the time range. For low-frequency orders, deviation correction can be performed based on the timestamp of the blockchain; while for high-frequency orders, the local clock needs to be synchronized with the external server time. A two-way timing synchronization algorithm is applied to adjust the clocks in the two systems through a time synchronization mechanism. Common algorithms include NTP (Network Time Protocol) and PTP (Precision Time Protocol) to ensure that the two types of data are synchronized within the same time frame. Based on the results of the timing synchronization algorithm, order transaction synchronization data is generated. These data contain the time information of each order, indicate the sending time, receiving time, etc. after synchronization, and ensure that the two types of order data are aligned in time. Once the order transaction synchronization data is generated, it is necessary to optimize the transmission channel of the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data to ensure that the data can be transmitted efficiently, stably and without packet loss when transmitted on the network. Perform performance analysis on existing transmission channels, focusing on factors such as bandwidth, latency, packet loss rate, and congestion to ensure the stability and reliability of data transmission. Evaluate the latency of different channels by analyzing the network latency from the order processing server to the target node. Use distributed network performance monitoring tools (such as Ping, Traceroute, etc.) to detect network latency and optimize data transmission paths based on the results. Dynamically adjust the load balancing strategy based on network conditions and order priorities. For high-frequency order traffic, use flow control technology to allocate bandwidth and control priorities to ensure that important data packets are transmitted first and avoid data packet loss or delay. For high-frequency order off-chain data, data compression technology can be used to reduce the size of data transmission, thereby improving transmission efficiency. At the same time, for low-frequency order on-chain transaction data, encryption technology can be used to ensure the security of data during transmission. For high-frequency order data transmission, asynchronous transmission technology is used to reduce waiting time, and the confirmation mechanism is used to ensure the integrity of data transmission. The optimized transmission channel should ensure that low-frequency order on-chain transaction data and high-frequency order off-chain transaction data can be transmitted quickly and stably in the network, while reducing packet loss, delay, and improving bandwidth utilization. After completing the transmission channel optimization, the system needs to collect various data and feedback information that occur during the transmission process to generate order synchronization feedback data, which will help with subsequent optimization adjustments.
[0080] Step S4: Confirm the order transaction result of the order synchronization feedback data to obtain order transaction result confirmation data; upload the order transaction result confirmation data to the cloud platform for data visualization, thereby generating an order transaction completion report.
[0081] In the embodiment of the present invention, the order transaction result confirmation is a verification of whether the order transaction is successfully completed. By analyzing the order synchronization feedback data, the system can confirm whether the transaction is completed as expected. The order synchronization feedback data contains various data in the transaction process, such as transmission delay, confirmation reception time, transaction status identification, etc. By analyzing these data, it is confirmed whether the order has successfully passed the predetermined process. Confirm whether the order transaction is successful according to the success criteria set by the system (such as transaction completion time, delay, transaction amount, etc.). If the transaction is successful, the order transaction result confirmation data is generated; if the transaction fails, the order failure confirmation data is generated. If the order synchronization data indicates that all transaction data has been successfully transmitted and meets the predetermined business rules (for example, the order has been paid and received), the order is marked as successfully completed and "order transaction result confirmation data" is generated. If a certain link of the order is not completed on time (such as payment timeout, reception failure, etc.), the order is marked as failed and the corresponding error information is recorded. The order transaction result confirmation data needs to be uploaded to the cloud platform for storage, analysis and processing. The cloud platform provides an efficient and secure storage environment for data and supports subsequent data visualization. The confirmation data is transmitted to the cloud platform through the RESTful API or other upload interfaces supported by the cloud platform. The data upload process needs to be encrypted and compressed to ensure data security and transmission efficiency. For large-volume orders, batch upload is adopted to reduce the burden of single transmission and ensure data consistency. Use WebSocket or other real-time synchronization technologies to ensure that transaction confirmation data can be uploaded to the cloud platform immediately under the real-time requirements of order completion. In the cloud platform, order transaction confirmation data will be stored in a distributed database to provide high availability and disaster recovery capabilities. The data backup mechanism will generate backups regularly to ensure the long-term security and stability of data. Through the cloud platform, transaction completion data can be extracted and generated into charts, reports and other visual forms for managers, analysts or system users to query and make decisions. Display the processing status of each order (such as completion or failure) and the corresponding time information (such as transaction time, receiving time, delay, etc.), generate a trend chart of order transaction completion, and display the transaction volume, success rate, failure rate, etc. in different time periods. By counting the reasons for different transaction failures, help the team identify bottlenecks and optimize the system.
[0082] Preferably, step S1 comprises the following steps:
[0083] Step S11: Acquire a multi-source order data set;
[0084] Step S12: performing data preprocessing on the multi-source order data set to generate a standard multi-source order data set, wherein the data preprocessing includes data cleaning, data denoising, data missing value filling and data standardization;
[0085] Step S13: performing transaction address analysis on the standard multi-source order data set to generate order transaction address data, wherein the order transaction address data includes order initiation address data and order receiving address data;
[0086] Step S14: Deploy order service nodes for standard multi-source order data through order initiation address data and order receiving address data to generate order service node deployment data; construct order processing servers for standard multi-source order data through order service node deployment data to generate order processing distribution server data.
[0087] In an embodiment of the present invention, the original order data is obtained from multiple different order data sources, including e-commerce platforms, logistics systems, payment systems, etc. Relevant order information is extracted from each data source to ensure the diversity and integrity of the data, such as order ID, product information, buyer and seller information, transaction time, etc. Invalid information in the data, such as error records, duplicate data, abnormal data, etc., is checked and removed or corrected. Algorithms such as mean filtering or median filtering are used to remove noise in the data to ensure the stability and accuracy of the data. Missing values are filled by interpolation methods (such as mean interpolation, nearest neighbor interpolation) or machine learning algorithms to ensure that each order record is complete. All numerical data are standardized to eliminate the impact of inconsistent scales of different source data and ensure that the data can be processed and analyzed under the same standard. The initiating address and receiving address data are extracted from the order. These addresses can be physical addresses, IP addresses or account addresses, depending on business needs. The extracted transaction addresses are parsed and classified into different regions or areas. The address can be geocoded using a geographic information system (GIS) tool or a geographic location service (such as IP address positioning). By analyzing the initiation address and receiving address of the order, a set of address data is generated, indicating the starting and ending locations of each order. Based on the initiation address and receiving address data of the order, the location of the service node is determined, which involves deploying the order processing nodes to different geographical areas or data centers. Service nodes should be optimally deployed according to the dense areas of order transactions, latency requirements, and network conditions. Record the deployment location of the service node for each order, including its ID, geographic location, server capabilities and other information. According to the order service node deployment data, order processing servers are configured at the corresponding locations. These servers can perform operations such as order verification, processing, and payment confirmation. All deployed server information is organized into a distributed server cluster data set, including the functions and performance of each server and its connection relationship with other servers.
[0088] Preferably, step S14 comprises the following steps:
[0089] Step S141: Performing geographic cluster analysis on standard multi-source order data through order initiation address data and order receiving address data to generate geographic address cluster data; performing regional order volume and processing demand calculation based on the geographic address cluster data to generate service node demand data;
[0090] Step S142: performing node candidate analysis on the service node demand data to generate server node candidate data; performing server distribution optimization on the standard multi-source order data to generate server distribution optimization data; performing server deployment on the standard multi-source order data according to the server node candidate data and the server distribution optimization data to generate order service node deployment data;
[0091] Step S143: Dynamically load detect the standard multi-source order data through the order service node deployment data to generate server dynamic load detection data; elastically expand the server for the order service node deployment data according to the server dynamic load detection data to generate order processing distribution server data.
[0092] In the embodiment of the present invention, geographic coordinate information is extracted from the order initiation address and the order receiving address. A clustering algorithm suitable for geographic data, such as K-Means, DBSCAN, etc., is used to perform cluster analysis of geographic location. The goal of clustering is to classify orders with similar geographic locations into one category to form "geographic address clustering data". The geographic coordinates are standardized, taking into account the density and distribution characteristics of the geographic location. The center point of each cluster and the cluster category to which each order belongs are output, and this information can help understand the order density in different regions. According to the geographic address clustering data, the number of orders in each clustering area is calculated. According to the processing complexity, processing time, order type, etc. of the order, the processing requirements of each clustering area are calculated. For example, the priority of the order, whether it involves complex operations such as delivery and payment, etc. can be considered. By analyzing the regional order volume and processing requirements, the number of service nodes required for each clustering area and its processing capacity are obtained. Based on the service node demand data, a potential service node candidate list is generated. The candidate node can be an existing physical server, a virtual machine or a data center, etc. According to factors such as node location, processing capacity, network latency, and available resources, the node that best meets the requirements is screened out. This process can use optimization algorithms (such as genetic algorithms, simulated annealing, etc.) to select the best candidate nodes and obtain a set of candidate server node data that can meet specific service requirements. Based on the service node requirements and candidate node data, a distributed optimization algorithm (such as load balancing algorithm, Lagrangian relaxation method, etc.) is used to optimize the distribution of servers. The goal is to balance the server load and minimize communication delay and processing delay. The final server distribution plan is output through the optimization algorithm to ensure that the needs of each service node are effectively met, while making the order processing process efficient and reliable. Based on the server node candidate data and server distribution optimization data, the final deployment location of the processing server for each order is determined. This deployment decision takes into account factors such as geographical distribution, resource capacity, and the timeliness of service requests. Record detailed information of each order service node, including node location, processing capacity, and connection relationship with other nodes, to ensure that the order can be processed on the optimal server. Obtain real-time load data of each server node through the monitoring system, including CPU usage, memory usage, network bandwidth utilization, etc. Based on real-time monitoring data, dynamic load detection is performed to identify nodes with excessive load. Load evaluation can be performed using threshold methods, prediction models (such as time series prediction), and other methods. Output the load status and load change trend of each node to provide a basis for subsequent elastic expansion. When the load of a node exceeds the set threshold, the server elastic expansion mechanism is triggered, which can be achieved by allocating new server resources, migrating loads, or adjusting load balancing strategies. According to the server load data, an automated expansion strategy is adopted, such as automatically starting a new virtual server, dynamically allocating resources, or adjusting task scheduling.According to the elastically expanded server configuration, update the data of the order processing distribution server, which includes the information of the newly added server nodes, load distribution status, etc., to ensure the continuous and stable operation of the system.
[0093] As an example of the present invention, refer to Figure 2 As shown, in this example, step S2 includes:
[0094] Step S21: performing order processing access frequency analysis on the multi-source order data set through the order processing distribution server data to generate order processing access frequency data;
[0095] Step S22: Compare the order processing access frequency data with the preset standard order access frequency threshold. When the order processing access frequency data is greater than or equal to the preset standard order access frequency threshold, the corresponding multi-source order data set is marked as high-frequency order access data; when the order processing access frequency data is less than the preset standard order access frequency threshold, the corresponding multi-source order data set is marked as low-frequency order access data;
[0096] Step S23: Perform on-chain transaction processing on the low-frequency order access data based on blockchain technology to generate low-frequency order on-chain transaction processing data;
[0097] Step S24: Perform off-chain intelligent elastic rectification transaction processing on the high-frequency order access data to generate high-frequency order off-chain transaction processing data.
[0098] In an embodiment of the present invention, the number of accesses and timestamps of each order are obtained by extracting the processing access log of each order from the order processing distribution server data. The order processing distribution server data should contain the detailed processing history of each order, such as the order initiation, processing, completion time and other information. The access frequency of each order is calculated, and the access frequency refers to the number of processing requests for the order per unit time. For example, the number of accesses per minute, hour, or day can be used to measure the access frequency of the order. A frequency analysis is performed on each order to generate "order processing access frequency data", which includes the access frequency, access time distribution, etc. of each order. The access frequency data of each order is output, including order ID, access frequency value, time distribution, etc. A standard access frequency threshold is set, which can be set according to historical data or business requirements. The threshold is used to distinguish high-frequency orders from low-frequency orders. For example, it is set that the number of processing requests per minute is greater than or equal to 5 times as a high-frequency order. The access frequency of each order is compared with the preset standard order access frequency threshold. When the order processing access frequency is greater than or equal to the threshold, the order is marked as a "high-frequency order". When the order processing access frequency is less than the threshold, the order is marked as a "low-frequency order". According to the comparison results, the orders are divided into high-frequency order access data and low-frequency order access data, and tag information is generated. For low-frequency orders, blockchain technology is used to ensure the transparency and immutability of data processing. Low-frequency order processing is relatively simple, and can be processed using the blockchain's smart contract mechanism. A transaction record is generated for each low-frequency order to record the order processing process, transaction information, etc. Low-frequency orders are processed through blockchain smart contracts to ensure the automated execution of all transactions. Smart contracts will automatically execute transaction logic according to the order processing conditions (such as payment, delivery, etc.) to avoid human intervention. Output low-frequency order on-chain transaction processing data, including on-chain transaction records, order processing status, blockchain transaction hash values, etc. High-frequency orders require fast response, and traditional blockchain processing is not applicable due to speed limitations. To this end, off-chain intelligent elastic rectification technology can be used to process high-frequency orders. Intelligent elastic rectification ensures smooth order processing and fast response through dynamic scheduling and optimization of high-frequency orders. For example, the order processing process can be optimized through distributed systems, load balancing and other technologies. The processing process of high-frequency orders uses an off-chain system to handle order status updates, payments, shipments and other operations. The off-chain system can include order management platform, payment system, distribution system, etc. After the off-chain processing is completed, the processing results are synchronized to the blockchain to ensure data consistency. The off-chain data can be uploaded to the chain through periodic batch processing or real-time synchronization mechanism. Output high-frequency order off-chain transaction processing data, including order status update records, payment records, delivery records, etc., and ensure the synchronization of data in the off-chain system and the blockchain.
[0099] Preferably, step S23 includes the following steps:
[0100] Step S231: extracting key features of low-frequency order access data to obtain key feature data of low-frequency orders, wherein the extracted key features of orders include order type, geographic location of initiation and receipt, payment method, and commodity category; labeling the low-frequency order access data based on the key feature data of low-frequency orders to generate an order feature label data set;
[0101] Step S232: assigning order priorities to the multi-source order data sets to generate order priority data; uploading the order priority data to a block chain according to the order feature tag data sets to generate low-frequency order up-chain storage data;
[0102] Step S233: Create on-chain transaction records for the low-frequency order on-chain storage data through the smart contract built into the blockchain to generate order on-chain transaction record data; perform hash encryption on the order on-chain transaction record data to generate blockchain encrypted transaction record data;
[0103] Step S234: Perform transaction consensus verification on the blockchain encrypted transaction record data to generate low-frequency order chain transaction processing data.
[0104] In an embodiment of the present invention, the key features of an order are extracted from the low-frequency order access data, and these features include: Order type: for example, ordinary order, VIP order, urgent order, etc. Geographic location of initiation and reception: geographic location data is extracted through the address or GPS coordinates of the order initiator and recipient. Payment method: such as credit card payment, Alipay, WeChat payment, cash, etc. Product category: the type of product involved in the order, such as electronic products, clothing, food, etc. Use data analysis methods (such as clustering, feature engineering, etc.) to analyze the order data and extract these key features. Label the low-frequency orders according to the extracted key features. Each low-frequency order will be assigned a specific label to form an "order feature label data set". Combined with the above labels, a feature label data set containing low-frequency orders is generated to facilitate subsequent processing and storage. According to the feature label data set of the order, priority is assigned to the low-frequency orders. Priority can be defined based on factors such as order type, product category, payment method, etc. For example: High priority: VIP customer orders, urgent orders. Medium priority: ordinary customer orders. Low priority: non-urgent orders, orders with sufficient inventory, etc. Dynamically assign priorities according to order characteristics through business rules or machine learning models. Use blockchain technology to store order priority information on the chain. When each order is stored on the chain, it will include its priority information and other necessary transaction data. The transparency and immutability of order priority data are guaranteed by the storage mechanism of blockchain. After the order priority is assigned, the relevant data (such as order ID, order priority, order characteristics, etc.) are uploaded and stored on the chain. On the blockchain, the transaction records of low-frequency orders are created through built-in smart contracts. Smart contracts can define transaction rules (such as automatic payment or shipment after order processing) and record every link of order processing. The transaction record of each low-frequency order will contain information such as order ID, transaction time, transaction amount, payment status, and shipment status. The transaction record of the order is hashed to generate a unique transaction hash value. This operation can ensure the security, integrity and privacy protection of transaction data. The transaction record is encrypted using a secure hash algorithm (such as SHA-256 or other encryption algorithms supported by blockchain) to generate "blockchain encrypted transaction record data". The transaction record data finally generated will include the original transaction data, the encrypted hash value, and other information related to the order to ensure the integrity and security of the data. In the blockchain, consensus verification of transactions is a key step to ensure the validity and legitimacy of transaction data. Consensus mechanisms (such as Proof of Work, Proof of Stake, etc.) are used to verify the transaction records of low-frequency orders. Each transaction must be verified by consensus through nodes in the blockchain network. After verification, the order transaction record will be officially added to the blockchain. After the consensus verification is completed, the transaction record is officially confirmed and added to a new block in the blockchain.The transaction results can be used as "low-frequency order on-chain transaction processing data", which contains all transaction details and transaction verification information. The low-frequency order transaction data in the blockchain cannot be tampered with, ensuring the transparency and security of the order processing process.
[0105] Preferably, step S24 includes the following steps:
[0106] Step S241: Performing an external server time request on the high-frequency order access data to obtain external server request time data; performing time deviation calculation on the external server request time data and the local clock in the order processing distribution server to obtain request time deviation data;
[0107] Step S242: performing short-term cumulative trend analysis on the request time deviation data to generate short-term cumulative trend data; performing clock drift detection on the high-frequency order access data based on the short-term cumulative trend data to generate clock drift detection data;
[0108] Step S243: performing sliding window compensation on the high-frequency order access data according to the clock drift detection data to generate high-frequency order access time compensation data; performing lightweight order processing flow optimization on the high-frequency order access data by using the high-frequency order access time compensation data to generate high-frequency order processing data;
[0109] Step S244: Transaction traffic rectification is performed on the high-frequency order processing data to generate high-frequency order transaction traffic rectification data; high-frequency order transaction traffic rectification data is used to perform flexible priority scheduling on the high-frequency order access data, thereby generating high-frequency order off-chain transaction processing data.
[0110] In an embodiment of the present invention, a time request is initiated to an external server for high-frequency order access data. This request usually involves obtaining standard time data of the external server (for example, time obtained through the NTP protocol) to ensure the uniformity of all time records. The external server time data may include timestamp information and be used for comparison and analysis with the local clock time. The external server request time data is compared with the local clock in the order processing distribution server to calculate the time difference (deviation) between the two. Specific deviation calculation method: time deviation = external server request time - local clock time. The time deviation data will provide the necessary basic data for subsequent clock drift detection and traffic optimization. The obtained time deviation data will be recorded according to a certain time period (for example, every minute, every hour) as request time deviation data for subsequent steps to process and analyze. Perform short-term cumulative trend analysis on the obtained request time deviation data. By analyzing the change trend of the time deviation data over a period of time, the accumulation trend of the time deviation is identified, and it is determined whether the system has the risk of clock drift. The short-term cumulative trend analysis can predict the change trend of the time deviation in the short term in the future by calculating the cumulative value or average value of the time deviation. Based on the results of short-term cumulative trend analysis, short-term cumulative trend data is generated to indicate the changing trend of time deviation within a specific time period. Using short-term cumulative trend data, clock drift detection is performed, which can effectively identify the drift between the system clock and the external time source. If the time deviation continues to increase, it means that the system has clock drift. Clock drift detection determines whether the drift reaches the warning level by setting a threshold. When the deviation exceeds the preset threshold, further compensation measures are triggered. Based on the results of clock drift detection, clock drift detection data is generated to indicate which time periods of order access are affected by clock drift and need further processing. Based on the clock drift detection data, sliding window compensation is performed on high-frequency order access data. The sliding window compensation method reduces the time difference caused by clock drift by dynamically adjusting the time window. The specific compensation steps are as follows: For order access detected with drift, the sliding window will adjust the timestamp so that the processing traffic is not affected by clock deviation. During the compensation process, the size of the sliding window can be adjusted according to the system load and the degree of drift to ensure the maximum compensation effect. The deviation data is compensated by the high-frequency order access data after sliding window compensation to generate high-frequency order access time compensation data. This data will be used for subsequent transaction flow optimization. Using high-frequency order access time compensation data, lightweight order processing flow optimization is performed. This optimization is mainly to alleviate the processing pressure caused by clock deviation by adjusting server resource allocation and task scheduling strategies. For example, using compensated access time data, dynamically adjust the priority of processing requests and allocate resources to reduce delays and unnecessary request backlogs caused by clock drift.After time compensation and traffic optimization, the generated high-frequency order processing data contains optimized order access data, which can allocate resources more effectively and reduce system load. The purpose of transaction traffic rectification for high-frequency order processing data is to smooth order access traffic and reduce peak traffic during the transaction process. Traffic rectification uses an algorithm to reschedule and allocate transaction requests according to factors such as priority, time requirements, and processing capacity to ensure traffic balance. Commonly used technologies include queuing theory, load balancing, and request caching. The high-frequency order transaction traffic rectification data processed by the traffic rectification algorithm has higher throughput, lower latency, and balanced system load. According to the high-frequency order transaction traffic rectification data, elastic priority scheduling is performed. This scheduling strategy intelligently adjusts the processing order according to dynamic factors such as order priority, system load, and processing capacity to ensure that high-priority orders are processed first. Elastic scheduling makes intelligent decisions not only based on the importance of the order, but also based on the real-time load and system status to achieve optimal resource allocation. Finally, based on traffic rectification and priority scheduling, high-frequency order off-chain transaction processing data is generated. After optimization, these data can be directly used for order processing and settlement to improve transaction efficiency and processing quality.
[0111] As an example of the present invention, refer to Figure 3 As shown, in this example, step S3 includes:
[0112] Step S31: Integrate the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data to generate order transaction integration data;
[0113] Step S32: performing order transaction bidirectional time synchronization on the order transaction integration data to generate order transaction synchronization data; performing order sending timestamp confirmation on the order transaction integration data according to the order transaction synchronization data to obtain the order sending timestamp;
[0114] Step S33: Synchronize the order transaction integration data with the order initiation address data and the order receiving address data to generate order transaction transmission data; confirm the receiving timestamp of the order transaction transmission data to obtain the seller receiving timestamp and the buyer receiving timestamp;
[0115] Step S34: Use the order sending timestamp to confirm the time interval between the seller receiving timestamp and the buyer receiving timestamp to obtain the order transmission time interval data; optimize the transmission channel of the order transaction transmission data according to the order transmission time interval data, thereby generating order synchronization feedback data.
[0116] In an embodiment of the present invention, the transaction processing data on the low-frequency order chain is integrated with the transaction processing data off the high-frequency order chain. The integration process includes unified formatting and summarization of the two data types to ensure that the low-frequency orders and high-frequency orders are unified in terms of timing, state, and characteristics. The data integration method can be based on a time series or event-triggered method to match the two data for subsequent synchronization and analysis. The specific steps include: matching low-frequency and high-frequency data by timestamp or feature field. Sorting and unifying the integrated data to ensure that they can be transmitted and processed at the same time. After integration, order transaction integration data is generated. This data set contains two different types of order data (low-frequency orders and high-frequency orders) and their merge information for subsequent processing. By performing bidirectional time series synchronization on the low-frequency orders and high-frequency orders in the order transaction integration data, the consistency of the time series of the two types of orders is ensured. The synchronization strategy can use a time alignment algorithm or a time window method to ensure that orders in different time periods can be merged in sequence. The purpose of bidirectional time series synchronization is to ensure that the time dependency between low-frequency and high-frequency orders in the data is accurately processed, so that the sending and receiving time of each order is clear and definite. Through two-way timing synchronization processing, order transaction synchronization data is generated, which includes the synchronized low-frequency and high-frequency order data to ensure the timing consistency between the data. According to the synchronized data, the order sending timestamp is confirmed. The sending timestamp confirmation is based on the initiation time of each order to ensure that all integrated order data has a clear time mark. The confirmation of the order sending timestamp can be completed by querying and marking the relevant fields of each order to ensure the accurate record of the sending time. After confirmation, the order sending timestamp data is generated as the time benchmark for subsequent analysis and processing. Through the order initiation address data and the order receiving address data, the order transaction integration data is synchronized and transmitted. According to the source address and target address of the order, the optimal network channel is selected for data transmission. The data transmission process can use protocols such as TCP / IP, UDP, HTTP, etc. to optimize data synchronization by ensuring the reliability and low latency of the transmission process. Through the synchronous transmission mechanism, order transaction transmission data is generated. This data includes the order data that has undergone the transmission process and has a receiving status mark. The receiving timestamp is confirmed for the transmitted order transaction data. The receiving timestamp is used to record the actual receiving time of the order at the receiving end in this step. According to the arrival time of the data during the transmission process, the receiving timestamps of the buyer and seller are generated. Through the confirmation of the receiving timestamp, the seller's receiving timestamp and the buyer's receiving timestamp are obtained respectively, which serve as the basic data for subsequent order transmission and time analysis. The time interval is calculated using the order sending timestamp and the seller's and buyer's receiving timestamps. This time interval indicates the time required from sending to receiving the order, reflecting the efficiency and delay of order transmission.Specific calculation method: Transmission time interval = (seller receiving timestamp - order sending timestamp) / (buyer receiving timestamp - order sending timestamp) Through this time interval, the delay in the data transmission process can be evaluated. Based on the calculated time interval data, the order transmission time interval data is generated. This data will help identify bottlenecks or delays in the transmission process and further optimize the data transmission process. According to the order transmission time interval data, the transmission channel is optimized. The purpose of transmission channel optimization is to improve the efficiency of data transmission, reduce delays and optimize bandwidth usage. This can be done by optimizing the load balancing of the transmission channel, dynamically selecting the fastest transmission path, and adjusting the transmission protocol and compression strategy. After the transmission channel is optimized, the order synchronization feedback data is generated. This data will contain information such as the transmission status, transmission time, and delay of the order, which will serve as the basis for subsequent decision-making and optimization.
[0117] Preferably, performing bidirectional time-series synchronization of order transaction integration data includes:
[0118] An order time window is set for the order transaction integration data to obtain an order processing time window; the order processing time is confirmed for the order processing time window to obtain order processing time data; the order processing time data is compared with the order processing time window, and when the order processing time data is within the order processing time window, the order transaction integration data is segmented based on the order processing time data to generate an order transaction data packet;
[0119] When the order processing time data is outside the order processing time window, the order transaction integration data is rescheduled until the order processing time data is within the order processing time window, and an order transaction data packet is generated;
[0120] The transaction timing of the order transaction data packet is bidirectionally confirmed according to the order initiation address data and the order receiving address data, thereby generating order transaction synchronization data.
[0121] In an embodiment of the present invention, a time window is set for the order transaction integration data. The purpose of this step is to set a time window for each order to confirm the time range for processing the order. These time windows can be defined according to the initiation time, reception time or other characteristic fields (such as business rules, system time zone, etc.) of the order. When setting the time window, a static window (fixed time period) or a dynamic window (automatically adjusted according to the actual situation of the order) can be used. For example, a window can be set for the upstream and downstream time of order processing, the longest time from the initiation of the order to the reception or processing. After the order time window is set, the specific time of order processing is confirmed. The order processing time data refers to the exact moment when each order is initiated, received and processed. This data can be determined by the event timestamp in the system or by the event trigger mechanism. The order processing time data is compared with the order processing time window. When the order processing time data is within the order time window, it means that the order is processed within the valid time range, and further operations can be performed at this time. If the order processing time data is within the valid time window, the order is processed by data slicing. The purpose of data sharding is to divide the order into multiple data packets according to the size of the time window and the processing time of the order. The purpose of this is to facilitate subsequent data transmission, synchronization and processing. If the order processing time data is not within the set time window, the order needs to be rescheduled. The purpose of this process is to adjust the order processing order or correct the timestamp of the order to ensure that it can be processed within the correct time window. The method of rescheduling can be implemented in the following ways: postpone the processing of the order until its processing time enters the valid time window. Adjust the priority of the order so that it can be processed within the most appropriate time window. If the order cannot be processed within the valid window, the timeout mechanism can be triggered and rescheduled. Rescheduled order transaction data packet. After ensuring that all orders meet the time window requirements, data sharding and synchronization are performed. After the order transaction data packet is generated, the order transaction timing is bidirectionally confirmed according to the order initiation address data and the order receiving address data. This process involves two key data sources: where the order is initiated, usually the customer, seller, etc. That is, the location of the order receiving end, such as the seller, logistics, etc. Two-way confirmation means ensuring that the time sequence from initiation to receipt is completely consistent. This can be achieved by verifying and comparing the sending and receiving time of the order to ensure that the entire order transaction chain is continuous in time sequence.
[0122] Preferably, step S4 comprises the following steps:
[0123] Step S41: confirming the order transaction result of the order synchronization feedback data to obtain order transaction result confirmation data; uploading the order transaction result confirmation data to the cloud platform for transaction completion data storage to generate order transaction completion data;
[0124] Step S42: Visualize the order transaction completion data to generate an order transaction completion report.
[0125] In the embodiment of the present invention, the order synchronization feedback data is analyzed and confirmed. The order synchronization feedback data is the final status information of the order during the transaction process, which includes the processing status, timestamp, transaction confirmation information, etc. of the order. When confirming the order transaction result, the order status information (such as "paid", "shipped", "completed") and the transaction feedback data (such as the recipient confirmation, payment confirmation, etc.) can be compared to confirm whether the transaction is successful. The order transaction result confirmation data needs to be permanently saved for subsequent audits, queries, and future analysis. To this end, the order transaction result confirmation data is uploaded to the cloud platform for storage. The security and integrity of the data need to be guaranteed during the storage process, and it can be protected by data encryption, backup, distributed storage, etc. The cloud platform can provide high availability and high scalability storage to cope with large-scale order data. When uploading to the cloud platform, a corresponding data index can be created to quickly find and retrieve transaction completion data. The order transaction completion data is visualized. The purpose of visualization is to convert complex transaction data into easy-to-understand charts, graphs, and reports, so that business personnel can more intuitively view and analyze the completion of order transactions. The visualization content includes: showing the time span from the initiation to the completion of each order. Showing the transaction status distribution of orders, such as the proportion of success, failure, and in progress. Showing the trend chart of order completion volume according to time periods (such as days, weeks, and months). Showing the order transaction completion status of different regions, customers, and products. Automatically generate a detailed transaction completion report based on the order transaction completion data.
[0126] In this specification, a blockchain-based order data processing system is provided, which is used to execute the above-mentioned blockchain-based order data processing method. The blockchain-based order data processing system includes:
[0127] The server building module is used to obtain multi-source order data sets; perform transaction address analysis on the multi-source order data sets to generate order transaction address data; construct an order processing server for the multi-source order data through the order transaction address data to generate order processing distribution server data;
[0128] The order layering processing module is used to analyze the order processing access frequency of multi-source order data sets through the order processing distribution server data to generate order processing access frequency data; perform order screening on the multi-source order data sets based on the order processing access frequency data to generate high-frequency order access data and low-frequency order access data; perform on-chain transaction processing on the low-frequency order access data to generate low-frequency order on-chain transaction processing data; perform off-chain intelligent elastic rectification transaction processing on the high-frequency order access data to generate high-frequency order off-chain transaction processing data;
[0129] The timing synchronization module is used to perform bidirectional timing synchronization of low-frequency order on-chain transaction processing data and high-frequency order off-chain transaction processing data to generate order transaction synchronization data; based on the order transaction synchronization data, the transmission channel of low-frequency order on-chain transaction processing data and high-frequency order off-chain transaction processing data is optimized to generate order synchronization feedback data;
[0130] The order storage module is used to confirm the order transaction results of the order synchronization feedback data and obtain the order transaction result confirmation data; the order transaction result confirmation data is uploaded to the cloud platform for data visualization, thereby generating an order transaction completion report.
[0131] The beneficial effect of the present invention is that by acquiring a multi-source order data set and performing transaction address analysis, the source and receiving location of the order can be fully understood, ensuring the accuracy and comprehensiveness of the order processing process. The implementation of this step makes the distribution and flow of order data clear at a glance, optimizing the order processing process. Building an order processing server based on transaction address data not only ensures the efficient operation of the order processing system, but also realizes the flexible scheduling of server resources. According to the distribution of order data, the system can dynamically build and adjust the processing server to improve the scalability and resource utilization efficiency of the system. Through the order processing access frequency analysis, high-frequency and low-frequency orders can be accurately identified, so as to carry out different processing strategies, which helps to reasonably allocate resources, reduce the burden on the server, and avoid performance bottlenecks in the processing process. Low-frequency orders ensure the transparency and immutability of data through on-chain processing, while high-frequency orders are processed through off-chain intelligent elastic rectification, which optimizes the efficiency and response speed of transaction processing. This processing strategy greatly improves the processing capacity of high-frequency transactions while ensuring the security of low-frequency transactions. Through the two-way timing synchronization of order transactions, the order and integrity of transaction data are ensured, the loss and duplication of data are avoided, and the consistency and accuracy of transactions are improved. This step effectively reduces transaction conflicts caused by timing asynchrony. The transmission channel of transaction data is optimized to ensure the efficient transmission of order synchronization feedback. By reducing delays and improving the reliability of data transmission, the entire transaction processing process is optimized and the response speed of the system is improved. Through the confirmation of order transaction results, it can ensure that each transaction is confirmed and stored in the system, effectively reducing the risk of transaction disputes and misoperation. This process enhances the transparency and traceability of the transaction process. Uploading the transaction result confirmation data to the cloud platform for visualization not only allows managers to monitor the completion of order transactions in real time, but also enables business analysis through data charts to help managers quickly identify potential problems and optimization strategies. The generation of order transaction completion reports enables business personnel to intuitively understand the processing efficiency, completion status and existing problems of the overall order, providing strong support for subsequent decision-making, adjustment and optimization. Therefore, the present invention improves the reliability and efficiency of order transactions by optimizing multi-source data integration, order access frequency analysis, transaction synchronization and channel optimization.
[0132] Therefore, the embodiments should be regarded as illustrative and non-restrictive from all points, and the scope of the present invention is limited by the appended claims rather than the above description, and it is therefore intended that all changes falling within the meaning and range of equivalent elements of the application documents are included in the present invention.
[0133] The above description is only a specific embodiment of the present invention, so that those skilled in the art can understand or implement the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but should conform to the widest scope consistent with the principles and novel features invented herein.
Claims
1. A method for processing order data based on blockchain, characterized in that: The following steps are involved: Step S1: Acquire a multi-source order data set; perform transaction address analysis on the multi-source order data set to generate order transaction address data; construct an order processing server for the multi-source order data using the order transaction address data to generate order processing distribution server data; Step S2: performing order processing access frequency analysis on the multi-source order data set through the order processing distribution server data to generate order processing access frequency data; performing order screening on the multi-source order data set based on the order processing access frequency data to generate high-frequency order access data and low-frequency order access data; Perform on-chain transaction processing on low-frequency order access data to generate on-chain transaction processing data for low-frequency orders; perform off-chain intelligent elastic rectification transaction processing on high-frequency order access data to generate off-chain transaction processing data for high-frequency orders; The off-chain intelligent elastic rectification transaction processing for high-frequency order access data includes: Perform an external server time request on high-frequency order access data to obtain external server request time data; perform time deviation calculation on the external server request time data and the local clock in the order processing distribution server to obtain request time deviation data; Perform short-term cumulative trend analysis on request time deviation data to generate short-term cumulative trend data; perform clock drift detection on high-frequency order access data based on the short-term cumulative trend data to generate clock drift detection data; Perform sliding window compensation on high-frequency order access data based on clock drift detection data to generate high-frequency order access time compensation data; perform lightweight order processing traffic optimization on high-frequency order access data through high-frequency order access time compensation data to generate high-frequency order processing data; Perform transaction flow rectification on high-frequency order processing data to generate high-frequency order transaction flow rectification data; use high-frequency order transaction flow rectification data to perform flexible priority scheduling on high-frequency order access data, thereby generating high-frequency order off-chain transaction processing data; Step S3: Perform bidirectional order transaction timing synchronization on the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data to generate order transaction synchronization data; optimize the transmission channel of the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data according to the order transaction synchronization data, thereby generating order synchronization feedback data; Step S4: Confirm the order transaction result of the order synchronization feedback data to obtain order transaction result confirmation data; upload the order transaction result confirmation data to the cloud platform for data visualization, thereby generating an order transaction completion report.
2. The order data processing method based on blockchain according to claim 1 is characterized in that: Step S1 includes the following steps: Step S11: Acquire a multi-source order data set; Step S12: performing data preprocessing on the multi-source order data set to generate a standard multi-source order data set, wherein the data preprocessing includes data cleaning, data denoising, data missing value filling and data standardization; Step S13: Perform transaction address analysis on the standard multi-source order data set to generate order transaction address data, wherein the order transaction address data includes order initiation address data and order receiving address data; Step S14: Deploy order service nodes for standard multi-source order data through order initiation address data and order receiving address data to generate order service node deployment data; construct order processing servers for standard multi-source order data through order service node deployment data to generate order processing distribution server data.
3. The order data processing method based on blockchain according to claim 2 is characterized in that: Step S14 includes the following steps: Step S141: Performing geographic cluster analysis on standard multi-source order data through order initiation address data and order receiving address data to generate geographic address cluster data; performing regional order volume and processing demand calculation based on the geographic address cluster data to generate service node demand data; Step S142: performing node candidate analysis on the service node demand data to generate server node candidate data; performing server distribution optimization on the standard multi-source order data to generate server distribution optimization data; performing server deployment on the standard multi-source order data according to the server node candidate data and the server distribution optimization data to generate order service node deployment data; Step S143: Dynamically load detect the standard multi-source order data through the order service node deployment data to generate server dynamic load detection data; elastically expand the server for the order service node deployment data according to the server dynamic load detection data to generate order processing distribution server data.
4. The order data processing method based on blockchain according to claim 1 is characterized in that: Step S2 includes the following steps: Step S21: performing order processing access frequency analysis on the multi-source order data set through the order processing distribution server data to generate order processing access frequency data; Step S22: Compare the order processing access frequency data with the preset standard order access frequency threshold. When the order processing access frequency data is greater than or equal to the preset standard order access frequency threshold, the corresponding multi-source order data set is marked as high-frequency order access data; when the order processing access frequency data is less than the preset standard order access frequency threshold, the corresponding multi-source order data set is marked as low-frequency order access data; Step S23: Perform on-chain transaction processing on the low-frequency order access data based on blockchain technology to generate low-frequency order on-chain transaction processing data; Step S24: Perform off-chain intelligent elastic rectification transaction processing on the high-frequency order access data to generate high-frequency order off-chain transaction processing data.
5. The method for processing order data based on blockchain according to claim 4, characterized in that: Step S23 includes the following steps: Step S231: extracting key features of low-frequency order access data to obtain key feature data of low-frequency orders, wherein the extracted key features of orders include order type, geographic location of initiation and receipt, payment method, and commodity category; labeling the low-frequency order access data based on the key feature data of low-frequency orders to generate an order feature label data set; Step S232: assigning order priorities to the multi-source order data sets to generate order priority data; uploading the order priority data to a block chain according to the order feature tag data sets to generate low-frequency order up-chain storage data; Step S233: Create on-chain transaction records for the low-frequency order on-chain storage data through the smart contract built into the blockchain to generate order on-chain transaction record data; perform hash encryption on the order on-chain transaction record data to generate blockchain encrypted transaction record data; Step S234: Perform transaction consensus verification on the blockchain encrypted transaction record data to generate low-frequency order chain transaction processing data.
6. The method for processing order data based on blockchain according to claim 1, characterized in that: Step S3 includes the following steps: Step S31: Integrate the low-frequency order on-chain transaction processing data and the high-frequency order off-chain transaction processing data to generate order transaction integration data; Step S32: performing order transaction bidirectional time synchronization on the order transaction integration data to generate order transaction synchronization data; performing order sending timestamp confirmation on the order transaction integration data according to the order transaction synchronization data to obtain the order sending timestamp; Step S33: Synchronize the order transaction integration data with the order initiation address data and the order receiving address data to generate order transaction transmission data; confirm the receiving timestamp of the order transaction transmission data to obtain the seller receiving timestamp and the buyer receiving timestamp; Step S34: Use the order sending timestamp to confirm the time interval between the seller receiving timestamp and the buyer receiving timestamp to obtain the order transmission time interval data; optimize the transmission channel of the order transaction transmission data according to the order transmission time interval data, thereby generating order synchronization feedback data.
7. The method for processing order data based on blockchain according to claim 6, characterized in that: The bidirectional time series synchronization of order transaction integration data includes: An order time window is set for the order transaction integration data to obtain an order processing time window; the order processing time is confirmed for the order processing time window to obtain order processing time data; the order processing time data is compared with the order processing time window, and when the order processing time data is within the order processing time window, the order transaction integration data is segmented based on the order processing time data to generate an order transaction data packet; When the order processing time data is outside the order processing time window, the order transaction integration data is rescheduled until the order processing time data is within the order processing time window, and an order transaction data packet is generated; The transaction timing of the order transaction data packet is bidirectionally confirmed according to the order initiation address data and the order receiving address data, thereby generating order transaction synchronization data.
8. The order data processing method based on blockchain according to claim 1 is characterized in that: Step S4 includes the following steps: Step S41: confirming the order transaction result of the order synchronization feedback data to obtain order transaction result confirmation data; uploading the order transaction result confirmation data to the cloud platform for transaction completion data storage to generate order transaction completion data; Step S42: Visualize the order transaction completion data to generate an order transaction completion report.
9. An order data processing system based on blockchain, characterized in that: For executing the blockchain-based order data processing method according to claim 1, the blockchain-based order data processing system comprises: The server building module is used to obtain multi-source order data sets; perform transaction address analysis on the multi-source order data sets to generate order transaction address data; construct an order processing server for the multi-source order data through the order transaction address data to generate order processing distribution server data; The order layering processing module is used to analyze the order processing access frequency of multi-source order data sets through the order processing distribution server data to generate order processing access frequency data; perform order screening on the multi-source order data sets based on the order processing access frequency data to generate high-frequency order access data and low-frequency order access data; perform on-chain transaction processing on the low-frequency order access data to generate low-frequency order on-chain transaction processing data; perform off-chain intelligent elastic rectification transaction processing on the high-frequency order access data to generate high-frequency order off-chain transaction processing data; The timing synchronization module is used to perform bidirectional timing synchronization of low-frequency order on-chain transaction processing data and high-frequency order off-chain transaction processing data to generate order transaction synchronization data; based on the order transaction synchronization data, the transmission channel of low-frequency order on-chain transaction processing data and high-frequency order off-chain transaction processing data is optimized to generate order synchronization feedback data; The order storage module is used to confirm the order transaction results of the order synchronization feedback data and obtain the order transaction result confirmation data; the order transaction result confirmation data is uploaded to the cloud platform for data visualization, thereby generating an order transaction completion report.
Citation Information
Patent Citations
Method and system for processing large-scale order efficient allocation
CN110570115A
Off-chain security payment method and system based on alliance chain, medium and equipment
CN112241884A