Data processing method, device and system and storage medium
By building an instruction sending queue in the Internet of Things system, the problem of error-prone in issuing instructions is solved, and the stable transmission of instructions and the stability of the platform system is achieved.
Patent Information
- Application Number
- CN202311641961.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-01
- Publication Date
- 2025-06-03
AI Technical Summary
In the Internet of Things system, issuing instructions is prone to errors, resulting in too many device interaction requests and insufficient instruction processing capabilities, which may lead to loss of instructions and confusing order.
Build an instruction sending queue, and send the issuing instructions to the target device through the queue to ensure that the instructions are not lost and reduce the probability of errors in the issuing order. Only when there is enough free storage space in the instruction sending queue will the issuing instructions be placed to avoid taking up too much memory.
Send the command queue through the command to ensure that the command will not be lost, reduce the chance of errors in the order of command issuance, improve the stability of the platform system, and avoid memory overflow.
Smart Images

Figure CN120086031A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of Internet of Things technology, for example, it relates to methods, devices, systems, and storage media for data processing. Background Art
[0002] With the development of intelligent technology, the Internet of Things has been widely applied in daily life, such as: smart home systems, intelligent logistics systems, and so on. Currently, a platform system that can be built using the Java language is available in the Internet of Things, and the platform server needs to send instructions to the devices in the Internet of Things, including: request instructions for obtaining device data, control instructions carrying control values, and so on.
[0003] Since there are many services and various operations in the Internet of Things, this may cause the platform server to frequently send instructions to the devices, which will lead to too many interaction requests for the devices. Moreover, for the large number of instructions built, the platform system cannot process them in a short time. And some instructions also have a certain order, which may also lead to chaos in the order of service instructions and loss of instructions.
[0004] It should be noted that the information disclosed in the above background art section is only used to enhance the understanding of the background of this application. Therefore, it may include information that does not constitute the prior art known to those of ordinary skill in the art. Summary of the Invention
[0005] To have a basic understanding of some aspects of the disclosed embodiments, a simple summary is given below. This summary is not a general review, nor is it intended to identify key / important constituent elements or delineate the protection scope of these embodiments. Instead, it serves as a preface to the subsequent detailed description.
[0006] Embodiments of the present disclosure provide a method, device, system, and storage medium for data processing to solve the technical problem of error-prone instruction sending in the Internet of Things system.
[0007] In some embodiments, the method includes:
[0008] Determine a first instruction to be sent corresponding to the current application;
[0009] When the first data storage space corresponding to the first instruction to be sent is less than or equal to the current free storage space in the instruction sending queue, put the first instruction to be sent into the instruction sending queue;
[0010] Send the first instruction to be sent to the corresponding target device through the instruction sending queue.
[0011] In some embodiments, the device includes:
[0012] A determination module configured to determine a first instruction to be sent corresponding to the current application;
[0013] A storage module, configured to put the first instruction for distribution into the instruction sending queue when the first data storage space corresponding to the first instruction for distribution is less than or equal to the currently free storage space in the instruction sending queue.
[0014] A distribution module, configured to send the first instruction for distribution to the corresponding target device through the instruction sending queue.
[0015] In some embodiments, the apparatus for data processing includes a processor and a memory storing program instructions, and the processor is configured to execute the above-mentioned method for data processing when executing the program instructions.
[0016] In some embodiments, the system includes a client, a platform server, and multiple devices, wherein the above-mentioned apparatus for data processing is installed in the platform server.
[0017] In some embodiments, the storage medium stores program instructions, and the program instructions, when running, execute the above-mentioned method for data processing.
[0018] The method, apparatus, and system for data processing provided by the embodiments of the present disclosure can achieve the following technical effects:
[0019] Construct an instruction sending queue. In this way, through the instruction sending queue, the instruction for distribution can be sent to the corresponding target device, ensuring that the instruction for distribution is not lost and reducing the probability of incorrect instruction distribution order. Moreover, only when there is enough free storage space in the instruction sending queue can the instruction for distribution be put in. In this way, it will not occupy too much memory of the platform system due to the large size of the instruction for distribution, further improving the stability of the platform system.
[0020] The above general description and the following description are only exemplary and explanatory, and are not used to limit the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] One or more embodiments are exemplarily illustrated by corresponding drawings. These exemplary illustrations and the drawings do not constitute limitations on the embodiments. Elements with the same reference numerals in the drawings are shown as similar elements. The drawings do not constitute a scale limitation, and among them:
[0022] Figure 1 is a schematic structural diagram of a data processing system provided by an embodiment of the present disclosure;
[0023] Figure 2 is a schematic flowchart of a data processing method provided by an embodiment of the present disclosure;
[0024] Figure 3It is a schematic flowchart of a data processing method provided by an embodiment of the present disclosure;
[0025] Figure 4 It is a schematic structural diagram of a data processing device provided by an embodiment of the present disclosure;
[0026] Figure 5 It is a schematic structural diagram of a data processing device provided by an embodiment of the present disclosure;
[0027] Figure 6 It is a schematic structural diagram of a data processing device provided by an embodiment of the present disclosure;
[0028] Figure 7 It is a schematic diagram of a platform server provided by an embodiment of the present disclosure. Detailed implementation manners
[0029] In order to be able to understand the features and technical content of the embodiments of the present disclosure in more detail, the implementation of the embodiments of the present disclosure will be described in detail below with reference to the accompanying drawings. The attached drawings are only for reference and illustration purposes and are not intended to limit the embodiments of the present disclosure. In the following technical descriptions, for the sake of explanation, numerous details are provided to give a full understanding of the disclosed embodiments. However, one or more embodiments can still be implemented without these details. In other cases, well-known structures and devices can be shown in a simplified manner to simplify the drawings.
[0030] In the description of the embodiments of the present disclosure, the terms "first", "second", etc. in the specification and claims of the embodiments of the present disclosure and the above-mentioned drawings are used to distinguish similar objects and do not necessarily describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances so as to implement the embodiments of the present disclosure described herein. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion.
[0031] Unless otherwise specified, the term "plurality" means two or more.
[0032] In the embodiments of the present disclosure, the character " / " indicates that the objects before and after are in an "or" relationship. For example, A / B means: A or B.
[0033] The term "and / or" is a description of the associated relationship of an object and indicates that three relationships can exist. For example, A and / or B means: A or B, or, the three relationships of A and B.
[0034] In the embodiments of the present disclosure, an instruction sending queue is constructed. In this way, through the instruction sending queue, the issued instructions can be sent to the corresponding target devices, ensuring that the issued instructions are not lost and reducing the probability of incorrect instruction issuing order. Moreover, only when there is enough free storage space in the instruction sending queue can the issued instructions be put in. In this way, it will not occupy too much memory of the platform system due to the large size of the issued instructions, further improving the stability of the platform system. Additionally, in some embodiments, the instruction sending queue is a memory-safe instruction queue, that is, the storage space of the instruction queue is determined according to the storage space of the application memory, without setting the size of the storage space of the instruction queue. Thus, there will be no phenomenon of corresponding instructions being lost due to too small a setting, nor will there be a phenomenon of memory overflow caused by too large a system memory occupation due to too large a setting.
[0035] Figure 1 is a schematic structural diagram of a data processing system provided by an embodiment of the present disclosure. As Figure 1 shown, the data processing system includes: a client 100, a platform server 200, and multiple devices 300. The platform server 200 can communicate with the client 100 and each device 300 respectively.
[0036] In some embodiments, the data processing system can be based on the Internet of Things. In this way, the client 100 can be a remote control, a mobile terminal, a tablet computer, a computer, etc., and can perform human-computer interaction with users. The platform server 200 can be an Internet of Things platform server, and the devices 300 are not limited to PCs, mobile phones, tablet computers, smart air conditioners, smart range hoods, smart refrigerators, smart ovens, smart stoves, smart washing machines, smart water heaters, smart washing equipment, smart dishwashers, smart projection devices, smart TVs, smart drying racks, smart curtains, smart audio and video, smart sockets, smart speakers, smart sound boxes, smart fresh air devices, smart kitchen and bathroom equipment, smart bathroom equipment, smart floor sweeping robots, smart window cleaning robots, smart mopping robots, smart air purification devices, smart steamers, smart microwave ovens, smart kitchen water heaters, smart purifiers, smart water dispensers, smart door locks, etc.
[0037] The user can initiate relevant information of an application through the client 100, and this application can be the current application. In this way, the platform server 200 can determine the issued instructions corresponding to the current application, including: a request instruction for obtaining device data, a control instruction carrying a control value, etc.
[0038] Moreover, the platform server 200 can construct an instruction sending queue corresponding to the current application. The instruction sending queue is configured with a set order, for example: first in, first out. And the storage space of the instruction sending queue is also determined and can be set. Or, in some embodiments, the storage space of the instruction sending queue can be configured according to the memory storage space of the current application.
[0039] In this way, after the platform server 200 determines the first distribution instruction corresponding to the current application, if the first data storage space corresponding to the first distribution instruction is less than or equal to the current free storage space in the instruction sending queue, that is, there is enough free storage space in the instruction sending queue, the first distribution instruction can be put into the instruction sending queue, and through the instruction sending queue, the first distribution instruction is sent to the corresponding target device 300.
[0040] In this way, since the instruction sending queue has a set order, it is ensured that the distributed instructions will not be lost, and the probability of incorrect instruction distribution order is also reduced. Moreover, in some embodiments, since the storage space of the instruction queue is determined according to the storage space of the application memory, thus, there will be no phenomenon that the corresponding instructions are lost due to too small setting, nor will there be a phenomenon that the system memory occupancy is too large and causes memory overflow due to too large setting.
[0041] It can be seen that the platform server can distribute instructions through the instruction sending queue. Figure 2 It is a schematic flowchart of a data processing method provided by an embodiment of the present disclosure. As Figure 2 shown, the process of data processing includes:
[0042] Step 201: Determine the first distribution instruction corresponding to the current application.
[0043] The user can start the relevant information of an application through the client, and this application can be the current application. In this way, the platform server can construct an instruction sending queue corresponding to the current application. The instruction sending queue is configured with a set order, for example: first in, first out. Moreover, the storage space of the instruction sending queue is also determined and can be set. Or, in some embodiments, an instruction sending queue can be constructed, and the storage space of the instruction sending queue is determined according to the available memory storage space of the current application.
[0044] For example: Build a secure instruction queue based on Java language
[0045] MemorySafeLinkedBlockingQueue. Among them, a
[0046] MemorySafeLinkedBlockingQueue object can be constructed, and then, relying on the ManagementFactory class of Java, obtain the available memory size of the current application, that is, obtain the available memory storage space of the current application, and then, determine the storage space of the instruction sending queue according to the available memory storage space.
[0047] In this way, during the operation of the current application, the platform server can determine a corresponding distribution instruction for the current application according to the user request information, the status information of the device, or other triggering conditions. There may be multiple distribution instructions for the current application. Taking any one of the distribution instructions as an example, that is, determining a first distribution instruction corresponding to the current application.
[0048] In some embodiments, determining the first distribution instruction corresponding to the current application includes: performing data encapsulation according to the request information for obtaining target device data and the address information of the target device to obtain the first distribution instruction; or, performing data encapsulation according to the control value information of the target device and the address information of the target device to obtain the first distribution instruction. For example: The request information for obtaining target device data, the address information of the target device, etc. can be uniformly encapsulated into a whole, which is the first distribution instruction.
[0049] Step 202: When the first data storage space corresponding to the first distribution instruction is less than or equal to the current free storage space in the instruction sending queue, put the first distribution instruction into the instruction sending queue.
[0050] When the platform server determines the current application, an instruction sending queue has been constructed, and the storage space of the instruction sending queue is also determined. Then, it is necessary to determine whether the free storage space in the instruction sending queue can store the first distribution instruction? If it can be stored, that is, the first data storage space corresponding to the first distribution instruction is less than or equal to the current free storage space in the instruction sending queue, then the first distribution instruction can be put into the instruction sending queue.
[0051] Of course, if it cannot be stored, the first distribution instruction cannot be put into the instruction sending queue, and error handling can also be performed, including: discarding the first distribution instruction, sending an error reminder message to the client, etc., one or more of which. That is, in some embodiments, error handling is performed when the first data storage space is greater than the current free storage space in the instruction sending queue.
[0052] For example: If the first data storage space is greater than the current free storage space in the instruction sending queue, the first distribution instruction can be directly discarded and "false" can be returned to the client.
[0053] Step 203: Send the first distribution instruction to the corresponding target device through the instruction sending queue.
[0054] The instruction sending queue corresponding to the current application constructed by the platform server is configured with a set order. In this way, one thread can put the issued instructions corresponding to the current application into the instruction sending queue, while another parallel thread can issue the issued instructions in the instruction sending queue one by one according to the set order. That is, in some embodiments, when it is determined that the issuing order corresponding to the first issued instruction is reached, the first issued instruction is taken out from the instruction sending queue; through the gateway device, the first issued instruction is sent to the target device. That is, by issuing the corresponding issued instructions through the instruction sending queue, the orderliness of the instructions is guaranteed, and the probability of incorrect instruction issuing order is reduced.
[0055] It can be seen that in the embodiments of the present disclosure, an instruction sending queue corresponding to the current application is constructed, and the instruction sending queue has a determined storage space. In this way, through the instruction sending queue, the issued instructions can be sent to the corresponding target devices, ensuring that the issued instructions are not lost, and also reducing the probability of incorrect instruction issuing order. Moreover, only when there is enough free storage space in the instruction sending queue can the issued instructions be put in. In this way, it will not occupy too much memory of the platform system due to the excessive size of the issued instructions, further improving the stability of the platform system. In addition, the instruction sending queue can be a memory-safe instruction queue, that is, the storage space of the instruction queue is determined according to the storage space of the application memory, without setting the size of the storage space of the instruction queue. Thus, the phenomenon of corresponding instructions being lost due to too small setting will not occur, nor will the phenomenon of memory overflow caused by excessive system memory occupation due to too large setting occur.
[0056] In some embodiments, when constructing the instruction sending queue corresponding to the current application by the platform server, the available memory storage space of the current application can be obtained, and according to the available memory storage space of the current application, the storage space of the instruction sending queue is determined, and this storage space can be the initial storage space of the instruction sending queue. In some embodiments, the storage space of the instruction sending queue can be updated, that is, regularly obtain the current available memory storage space of the current application, and update the storage space of the instruction sending queue according to the current available memory storage space. For example: the regular time can be 30ms, 50ms, or 80ms, etc. In this way, during the operation of the current application, every corresponding regular time interval, the current available memory storage space of the current application can be obtained once, and then, according to the current available memory storage space, the storage space of the instruction sending queue is updated. In this way, the accuracy and real-time nature of the maximum available memory are guaranteed, and thus the accuracy and real-time nature of instruction issuing are improved.
[0057] Next, the operation process will be incorporated into specific embodiments to illustrate the data processing process provided by the embodiments of the present invention.
[0058] In an embodiment of the present disclosure, as Figure 1The data processing system shown can be applied to an Internet of Things-based smart home. The devices can be refrigerators, washing machines, air conditioners, TVs, smart switches, smart speakers, etc. The platform server can communicate with the client and can also communicate with devices such as refrigerators, washing machines, and air conditioners through gateway devices.
[0059] Figure 3 It is a flowchart showing a data processing method provided by an embodiment of the present disclosure. As Figure 3 shown, the data processing process includes:
[0060] Step 301: The platform server determines the current application, constructs a secure instruction queue MemorySafeLinkedBlockingQueue object through the Java language, and depends on the ManagementFactory class of Java to obtain the available memory storage space of the current application.
[0061] Step 302: The platform server determines the storage space of the secure instruction queue MemorySafeLinkedBlockingQueue according to the available memory storage space of the current application.
[0062] Step 303: Determine whether the first issued instruction corresponding to the current application is determined? If yes, execute Step 304, otherwise, execute Step 307.
[0063] The user can send a request message to obtain the data of the target device through the client, then the platform server can encapsulate the obtain request message, the address information of the target device, etc. into a whole, which is the first issued instruction; or, if the current application generates control value information, the platform server can encapsulate the control value information, the address information of the target device, etc. into a whole, which is the first issued instruction.
[0064] Step 304: Determine whether the first data storage space corresponding to the first issued instruction is less than or equal to the current free storage space in the secure instruction queue? If yes, execute Step 305, otherwise, execute Step 306.
[0065] Step 305: The platform server puts the first issued instruction into the secure instruction queue MemorySafeLinkedBlockingQueue. Transfer to Step 307.
[0066] Step 306: The platform server performs error handling. Transfer to Step 307.
[0067] The first issued instruction cannot be put into the secure instruction queue
[0068] In the MemorySafeLinkedBlockingQueue. Moreover, the platform server can also generate a "false" message and return it to the current application or the corresponding client.
[0069] Step 307: Determine whether the current application running time corresponding to the set interval time of 50 ms has been reached? If so, execute Step 308; otherwise, return to Step 303.
[0070] Step 308: The platform server depends on the ManagementFactory class of Java to obtain the currently available memory storage space of the current application.
[0071] Step 309: The platform server updates the storage space of the secure instruction queue MemorySafeLinkedBlockingQueue according to the currently available memory storage space and returns to Step 303.
[0072] Step 310: The platform server sends the issued instructions in the secure instruction queue to the corresponding target devices one by one through the gateway device according to the set order through the secure instruction queue MemorySafeLinkedBlockingQueue.
[0073] Among them, when it is determined that the issuing order corresponding to the first issued instruction has been reached, the platform server retrieves the first issued instruction from the secure instruction queue MemorySafeLinkedBlockingQueue; then, through the gateway device, the first issued instruction is sent to the target device.
[0074] Based on the fact that the data put into and taken out of the secure instruction queue are two parallel threads, Step 310 can run in parallel with Steps 303 - 309. That is, after constructing the secure instruction queue MemorySafeLinkedBlockingQueue corresponding to the current application, issued instructions can be put into the queue in parallel through the secure instruction queue, and the issued instructions can be retrieved and issued.
[0075] It can be seen that in this embodiment, after constructing the secure instruction queue, the platform server can ensure that issued instructions are put into the secure instruction queue when there is available memory space. In this way, the system memory can be used as much as possible without worrying about the infinite growth of the queue size and finally memory leakage, while ensuring the security of the system memory. Moreover, when there are too many instruction messages and the memory corresponding to the current application is insufficient, the corresponding issued instructions can be not accepted, further ensuring the stability of the system memory. At the same time, the secure instruction queue MemorySafeLinkedBlockingQueue can ensure that instructions are not lost and the instruction issuing order, and provide a more efficient, more orderly and more scalable data processing method.
[0076] According to the above process for data processing, an apparatus for data processing can be constructed.
[0077] Figure 4 It is a schematic structural diagram of an apparatus for data processing provided by an embodiment of the present disclosure. As Figure 4 shown, the apparatus 400 for data processing includes: a determination module 410, a storage module 420, and a distribution module 430.
[0078] The determination module 410 is configured to determine a first distribution instruction corresponding to the current application.
[0079] The storage module 420 is configured to put the first distribution instruction into the instruction sending queue when the first data storage space corresponding to the first distribution instruction is less than or the first distribution instruction is equal to the current free storage space in the instruction sending queue.
[0080] The distribution module 430 is configured to send the first distribution instruction to the corresponding target device through the instruction sending queue.
[0081] In some embodiments, it further includes:
[0082] A construction module, configured to construct an instruction sending queue and determine the storage space of the instruction sending queue according to the available memory storage space of the current application.
[0083] In some embodiments, it further includes:
[0084] An update module, configured to periodically obtain the current available memory storage space of the current application and update the storage space of the instruction sending queue according to the current available memory storage space.
[0085] In some embodiments, the determination module 410 is specifically configured to perform data encapsulation according to the request information for obtaining target device data and the address information of the target device to obtain a first distribution instruction; or, perform data encapsulation according to the control value information of the target device and the address information of the target device to obtain a first distribution instruction.
[0086] In some embodiments, the distribution module 430 is specifically configured to take out the first distribution instruction from the instruction sending queue when it is determined that the distribution order corresponding to the first distribution instruction is reached; and send the first distribution instruction to the target device through the gateway device.
[0087] In some embodiments, it further includes:
[0088] An error reporting module, configured to perform error reporting processing when the first data storage space is greater than the current free storage space in the instruction sending queue.
[0089] The data processing process for a data processing device will be further described below in conjunction with embodiments.
[0090] In this embodiment, Figure 5 is a schematic structural diagram of a data processing device provided by an embodiment of the present disclosure. As Figure 5 shown, the data processing device 400 includes: a determination module 410, a storage module 420, a distribution module 430, a construction module 440, an update module 450, and an error reporting module 460.
[0091] In this embodiment, to determine the current application, the construction module 440 constructs an object of a secure instruction queue MemorySafeLinkedBlockingQueue through the Java language, and depends on the ManagementFactory class of Java to obtain the available memory storage space of the current application, and determines the storage space of the secure instruction queue MemorySafeLinkedBlockingQueue according to the available memory storage space of the current application.
[0092] In this way, the user can send a request message for obtaining target device data through the client, or the current application generates control value information of the target device. The determination module 410 can uniformly encapsulate the request message or the control value information with the address information of the target device, etc., to obtain a first distribution instruction.
[0093] When the first data storage space corresponding to the first distribution instruction is less than or equal to the current free storage space in the secure instruction queue, the storage module 420 can put the first distribution instruction into the secure instruction queue MemorySafeLinkedBlockingQueue; when the first data storage space is greater than the current free storage space in the secure instruction queue, the error reporting module 460 performs error reporting processing.
[0094] Of course, during the operation of the current application, when the current application running time corresponding to the set interval time of 50 ms is reached, the update module 450 can depend on the ManagementFactory class of Java to obtain the current available memory storage space of the current application, and update the storage space of the secure instruction queue MemorySafeLinkedBlockingQueue according to the current available memory storage space.
[0095] Since the data putting and taking based on the secure instruction queue are two parallel threads, the sending module 430 can, through the secure instruction queue MemorySafeLinkedBlockingQueue, send the sending instructions in the secure instruction queue to the corresponding target devices one by one through the gateway device according to the set order. Among them, when determining that the sending order corresponding to the first sending instruction is reached, the sending module 430 can take out the first sending instruction from the secure instruction queue MemorySafeLinkedBlockingQueue; then, through the gateway device, send the first sending instruction to the target device.
[0096] It can be seen that in this embodiment, after constructing the secure instruction queue, the device for data processing can ensure that when there is available space in the memory, the sending instructions are put into the secure instruction queue. In this way, the system memory can be used as much as possible without worrying about the infinite growth of the queue size and finally memory leakage, while ensuring the security of the system memory. And when there is too much instruction information and the memory corresponding to the current application is insufficient, the corresponding sending instructions can be not accepted, further ensuring the stability of the system memory. At the same time, the secure instruction queue MemorySafeLinkedBlockingQueue can ensure that instructions are not lost and the instruction sending order, and provide a more efficient, more orderly and more scalable data processing method.
[0097] Combined Figure 6 , the present disclosure embodiment provides a device 600 for data processing, including:
[0098] A processor 1000 and a memory 1001, and may further include a communication interface 1002 and a bus 1003. Among them, the processor 1000, the communication interface 1002, and the memory 1001 can complete mutual communication through the bus 1003. The communication interface 1002 can be used for information transmission. The processor 1000 can call the logical instructions in the memory 1001 to execute the method for data processing in the above embodiment.
[0099] In addition, when the logical instructions in the above-mentioned memory 1001 are implemented in the form of software functional units and sold or used as an independent product, they can be stored in a computer-readable storage medium.
[0100] The memory 1001, as a computer-readable storage medium, can be used to store software programs and computer-executable programs, such as the program instructions / modules corresponding to the methods in the embodiments of the present disclosure. The processor 1000 executes functional applications and data processing by running the program instructions / modules stored in the memory 1001, that is, implements the method for data processing in the above method embodiments.
[0101] The memory 1001 may include a program storage area and a data storage area. Among them, the program storage area may store an operating system and application programs required for at least one function; the data storage area may store data created according to the use of the terminal device, etc. In addition, the memory 1001 may include high-speed random access memory and may also include non-volatile memory.
[0102] The embodiments of the present disclosure provide a data processing device, including: a processor and a memory storing program instructions, and the processor is configured to execute a data processing method when executing the program instructions.
[0103] The embodiments of the present disclosure provide a system for data processing, including: a client, a platform server, and multiple devices. Figure 7 The data processing device 400(600) is installed in the platform server 700. The installation relationship described here is not limited to being placed inside the product, but also includes the installation connection with other components of the product, including but not limited to physical connection, electrical connection, or signal transmission connection, etc. Those skilled in the art can understand that the data processing device 400(600) can be adapted to a feasible platform server, thereby implementing other feasible embodiments.
[0104] The embodiments of the present disclosure provide a storage medium storing program instructions, and when the program instructions are running, they execute the method for data processing as described above.
[0105] The embodiments of the present disclosure provide a computer program product, and the computer program product includes a computer program stored on a storage medium. The computer program includes program instructions, and when the program instructions are executed by a computer, the computer is made to execute the above method for data processing.
[0106] The above storage medium may be a transient computer-readable storage medium or a non-transient computer-readable storage medium.
[0107] The technical solution of the embodiments of the present disclosure may be embodied in the form of a software product. The computer software product is stored in a storage medium and includes one or more instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in the embodiments of the present disclosure. The foregoing storage medium may be a non-transitory storage medium, including: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disc, and other media that can store program codes, or may also be a transient storage medium.
[0108] The above description and the accompanying drawings fully illustrate the embodiments of the present disclosure, enabling those skilled in the art to practice them. Other embodiments may include structural, logical, electrical, process, and other changes. The embodiments merely represent possible variations. Unless explicitly required, individual components and functions are optional, and the order of operations may vary. Parts and features of some embodiments may be included in or replace parts and features of other embodiments. The scope of the embodiments of the present disclosure includes the entire scope of the claims and all available equivalents of the claims. When used in this application, although terms such as "first", "second", etc. may be used in this application to describe various elements, these elements should not be limited by these terms. These terms are only used to distinguish one element from another. For example, without changing the meaning of the description, the first element may be called the second element, and similarly, the second element may be called the first element, as long as all occurrences of "the first element" are consistently renamed and all occurrences of "the second element" are consistently renamed. The first element and the second element are both elements, but they may not be the same element. Moreover, the terms used in this application are only used to describe the embodiments and do not limit the claims. As used in the description of the embodiments and the claims, unless the context clearly indicates otherwise, the singular forms "a", "an", and "the" are intended to also include the plural forms. Similarly, as used in this application, the term "and / or" refers to any and all possible combinations including one or more of the associated listed items. Additionally, when used in this application, the term "comprise" and its variants "comprises" and / or "comprising" etc. mean the presence of the stated features, wholes, steps, operations, elements, and / or components, but do not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components, and / or groups of these. Without further limitation, an element defined by the statement "comprising one..." does not exclude the presence of additional identical elements in the process, method, or device comprising the element. Herein, each embodiment may focus on the differences from other embodiments, and the same or similar parts between the embodiments may be referred to each other. For the methods, products, etc. disclosed in the embodiments, if they correspond to the method part disclosed in the embodiments, the relevant parts may refer to the description of the method part.
[0109] Those skilled in the art can realize that the units and algorithm steps of each example described in combination with the embodiments disclosed herein can be implemented by electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are executed in a hardware or software manner may depend on the specific application and design constraints of the technical solution. The technician can use different methods for each specific application to implement the described functions, but such implementation should not be considered to exceed the scope of the embodiments of the present disclosure. Those skilled in the art can clearly understand that for the convenience and conciseness of description, the specific working processes of the systems, devices, and units described above can refer to the corresponding processes in the foregoing method embodiments and will not be elaborated herein.
[0110] In the embodiments disclosed herein, the disclosed methods, products (including but not limited to devices, equipment, etc.) can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the units can be only a logical function division, and there can be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Additionally, the couplings, direct couplings, or communication connections shown or discussed among each other can be through some interfaces. The indirect couplings or communication connections of devices or units can be in electrical, mechanical, or other forms. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they can be located in one place or distributed to multiple network units. Some or all of the units can be selected according to actual needs to implement this embodiment. Additionally, in the embodiments of the present disclosure, the functional units can be integrated in one processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit.
[0111] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to embodiments of the present disclosure. In this regard, each block in the flowchart or block diagram may represent a module, a segment of a program, or a portion of code, which contains one or more executable instructions for implementing a specified logical function. In some alternative implementations, the functions noted in the blocks may occur in a different order than noted in the accompanying drawings. For example, two consecutive blocks may in fact be executed substantially in parallel, or they may sometimes be executed in the reverse order, depending on the functions involved. In the description corresponding to the flowcharts and block diagrams in the accompanying drawings, the operations or steps corresponding to different blocks may also occur in a different order than disclosed in the description, and sometimes there is no specific order between different operations or steps. For example, two consecutive operations or steps may in fact be executed substantially in parallel, or they may sometimes be executed in the reverse order, depending on the functions involved. Each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented by a dedicated hardware-based system that performs the specified functions or actions, or can be implemented by a combination of dedicated hardware and computer instructions.
Claims
1. A method for data processing, characterized in that, comprising: determining a first distribution instruction corresponding to the current application; when the first data storage space corresponding to the first distribution instruction is less than or equal to the current free storage space in the instruction sending queue, putting the first distribution instruction into the instruction sending queue; sending the first distribution instruction to the corresponding target device through the instruction sending queue.
2. The method according to claim 1, characterized in that, further comprising: constructing an instruction sending queue and determining the storage space of the instruction sending queue according to the available memory storage space of the current application.
3. The method according to claim 2, characterized in that, further comprising: periodically obtaining the current available memory storage space of the current application and updating the storage space of the instruction sending queue according to the current available memory storage space.
4. The method according to claim 1, characterized in that, the determining the first distribution instruction corresponding to the current application includes: performing data encapsulation according to the request information for obtaining target device data and the address information of the target device to obtain the first distribution instruction; or, performing data encapsulation according to the control value information of the target device and the address information of the target device to obtain the first distribution instruction.
5. The method according to claim 1, characterized in that, the sending the first distribution instruction to the corresponding target device includes: when it is determined that the distribution order corresponding to the first distribution instruction is reached, taking out the first distribution instruction from the instruction sending queue; sending the first distribution instruction to the target device through the gateway device.
6. The method according to any one of claims 1-5, characterized in that, further comprising: performing an error reporting process when the first data storage space is greater than the current free storage space in the instruction sending queue.
7. A device for data processing, characterized in that, comprising: a determining module configured to determine a first distribution instruction corresponding to the current application; a storing module configured to put the first distribution instruction into the instruction sending queue when the first data storage space corresponding to the first distribution instruction is less than or equal to the current free storage space in the instruction sending queue; a sending module configured to send the first distribution instruction to the corresponding target device through the instruction sending queue.
8. A device for data processing, the device includes a processor and a memory storing program instructions, characterized in that, the processor is configured to execute the method for data processing according to any one of claims 1 to 6 when executing the program instructions.
9. A system for data processing, characterized in that, comprising: a client, a platform server, and multiple devices, wherein, the device for data processing according to claim 7 or 8 is installed in the platform server.
10. A storage medium storing program instructions, characterized in that, the program instructions, when running, execute the method for data processing according to any one of claims 1 to 6.