CN112666906B - Data processing method and device, server and storage medium - Google Patents

Data processing method and device, server and storage medium Download PDF

Info

Publication number
CN112666906B
CN112666906B CN202011540388.6A CN202011540388A CN112666906B CN 112666906 B CN112666906 B CN 112666906B CN 202011540388 A CN202011540388 A CN 202011540388A CN 112666906 B CN112666906 B CN 112666906B
Authority
CN
China
Prior art keywords
time
offline
industrial equipment
detection
data processing
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011540388.6A
Other languages
Chinese (zh)
Other versions
CN112666906A (en
Inventor
李金东
张军旺
金鹏
孙岳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Rootcloud Technology Co Ltd
Original Assignee
Rootcloud Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Rootcloud Technology Co Ltd filed Critical Rootcloud Technology Co Ltd
Priority to CN202011540388.6A priority Critical patent/CN112666906B/en
Publication of CN112666906A publication Critical patent/CN112666906A/en
Application granted granted Critical
Publication of CN112666906B publication Critical patent/CN112666906B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/02Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]

Landscapes

  • Information Transfer Between Computers (AREA)
  • Computer And Data Communications (AREA)

Abstract

The embodiment of the application provides a data processing method and device, a server and a storage medium, and relates to the technical field of data processing. The data processing method is applied to a server, the server is in communication connection with industrial equipment, and the data processing method comprises the following steps: firstly, acquiring online time of industrial equipment, wherein the online time represents a time point of real-time uploading of working condition data by the industrial equipment; secondly, calculating to obtain the predicted off-line time of the industrial equipment according to the on-line time and a preset off-line detection period; and then, carrying out off-line detection on the industrial equipment according to the preset off-line detection period and the predicted off-line time. By the method, offline detection can be indirectly carried out through the offline detection period and the expected offline time, and the problem that in the prior art, some industrial equipment is possibly in an unstable network environment, and the reliability of offline detection is low due to the fact that offline detection is directly carried out according to the network connection condition is solved.

Description

Data processing method and device, server and storage medium
Technical Field
The present application relates to the field of data processing technologies, and in particular, to a data processing method and apparatus, a server, and a storage medium.
Background
After an access system of an industrial internet is developed, in order to display the connection state of equipment in real time, the system is required to provide the capability of processing the storage and display of the connection state of hundreds of thousands or millions of equipment in real time, and a user can intuitively judge the on-site equipment online state according to the equipment state displayed by the system. However, the inventor researches and discovers that some industrial equipment may be in an unstable network environment in an actual scene, and the prior art directly performs offline detection according to the network connection condition, so that the reliability of the offline detection is low.
Disclosure of Invention
In view of the above, an object of the present application is to provide a data processing method and apparatus, a server, and a storage medium, so as to solve the problems in the prior art.
In order to achieve the above purpose, the embodiment of the present application adopts the following technical solutions:
in a first aspect, the present invention provides a data processing method applied to a server, where the server is in communication connection with an industrial device, and the data processing method includes:
acquiring the online time of the industrial equipment, wherein the online time represents the time point of uploading the working condition data by the industrial equipment in real time;
calculating to obtain the expected off-line time of the industrial equipment according to the on-line time and a preset off-line detection period;
and carrying out off-line detection on the industrial equipment according to the preset off-line detection period and the predicted off-line time.
In an optional embodiment, the server stores a first detection time for performing offline detection on the industrial device last time, and the step of performing offline detection on the industrial device according to the preset offline detection period and the expected offline time includes:
calculating to obtain current detection time according to the first detection time and a preset offline detection period;
judging whether the predicted offline time of the industrial equipment is between the first detection time and the current detection time;
and if so, setting the state of the industrial equipment between the first detection time and the current detection time as an offline state.
In an optional embodiment, the data processing method further includes:
and updating the first detection time to the current detection time.
In an optional embodiment, the step of performing offline detection on the industrial device according to the preset offline detection period and the expected offline time includes:
detecting whether the industrial equipment uploads new working condition data before the predicted offline time or not in the preset offline detection period;
and if not, setting the state of the industrial equipment before the expected offline time in the preset offline detection period as an offline state.
In an optional embodiment, the data processing method further includes:
when the industrial equipment uploads new working condition data, determining new predicted offline time according to new online time and the preset offline detection period;
and carrying out off-line detection on the industrial equipment according to the preset off-line detection period and the new predicted off-line time.
In an optional embodiment, the server includes a micro-service unit and an EMQ unit that are in communication connection, the EMQ unit is in communication connection with the industrial device, and the step of obtaining the online time of the industrial device includes:
and monitoring the EMQ unit through the micro-service unit to obtain the online time from the industrial equipment to report the working condition data to the EMQ unit.
In an optional embodiment, the data processing method further includes a step of acquiring a preset offline detection period, where the step includes:
and acquiring a corresponding preset offline detection period according to the type of the industrial equipment.
In a second aspect, the present invention provides a data processing apparatus applied to a server, wherein the server is in communication connection with an industrial device, and the data processing apparatus includes:
the online time acquisition module is used for acquiring the online time of the industrial equipment, wherein the online time represents the time point of the industrial equipment for uploading the working condition data in real time;
the estimated offline time calculation module is used for calculating and obtaining the estimated offline time of the industrial equipment according to the online time and a preset offline detection period;
and the off-line detection module is used for carrying out off-line detection on the industrial equipment according to the preset off-line detection period and the predicted off-line time.
In a third aspect, the present invention provides a server, comprising a memory and a processor, wherein the processor is configured to execute an executable computer program stored in the memory to implement the data processing method of any one of the foregoing embodiments.
In a fourth aspect, the present invention provides a storage medium having stored thereon a computer program which, when executed, implements the steps of the data processing method of any one of the preceding embodiments.
According to the data processing method and device, the server and the storage medium, the expected offline time is obtained through the online time of the industrial equipment and the preset offline detection period, offline detection is carried out according to the preset offline detection period and the expected offline time, offline detection indirectly through the offline detection period and the expected offline time is achieved, and the problem that in the prior art, some industrial equipment possibly is in an unstable network environment, and offline detection directly according to the network connection condition causes low reliability of offline detection is solved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are required to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present application and therefore should not be considered as limiting the scope, and for those skilled in the art, other related drawings can be obtained from the drawings without inventive effort.
Fig. 1 is a block diagram of a data processing system according to an embodiment of the present disclosure.
Fig. 2 is a schematic flow chart of a data processing method according to an embodiment of the present application.
Fig. 3 is another schematic flow chart of a data processing method according to an embodiment of the present application.
Fig. 4 is another schematic flow chart of the data processing method according to the embodiment of the present application.
Fig. 5 is another schematic flow chart of the data processing method according to the embodiment of the present application.
Fig. 6 is another schematic flow chart of the data processing method according to the embodiment of the present application.
Fig. 7 is a block diagram of a data processing apparatus according to an embodiment of the present application.
Icon: 10-a data processing system; 100-a server; 200-industrial equipment; 700-a data processing apparatus; 710-an online time acquisition module; 720-expected offline time calculation module; 730-offline detection module.
Detailed Description
The prior art device state judgment logic is usually realized by means of redis to indirectly judge or directly use the mqtt connection state. Wherein, the indirect judgment step by using redis: 1. the consumption real-time working condition is updated to redis by taking the equipment identifier as key and the last cloud time of the equipment as value; 2. starting a timing task, acquiring an off-line detection period, scanning cloud-up time of all devices in the redis in a full amount, and using a detection algorithm: when the (current time-last cloud time) < ═ offline detection period, judging that the equipment is online; and when the (current time-last cloud time) > is in an offline detection period, determining that the equipment is offline. Direct determination using mqtt connection status: when the device establishes connection with the mqtt server of the platform, namely the representative device is online, and when the connection is lost, the representative device is offline.
The prior art has the following technical problems:
1. the existing equipment state judging method has high requirements on network environment, can not shake, and can normally display the equipment state only when the equipment is always in a stable and reliable network environment. However, in practical situations, some devices may be in an unstable environment of the network, and in such a situation, a method for determining the logical state of the device needs to be provided to ensure that the logical state of the device does not change frequently due to occasional jitter of the network.
2, the redis can not scan according to conditions, the total amount of scanning is required to be operated in every time, the total amount of system equipment reaches million levels, the total amount of scanning in every time is not necessary, but great pressure is generated on the redis, certain influence is generated on the performance, and service resources are wasted to a certain extent.
3. If the mqtt connection state is used for directly judging the state of the equipment, when the connection is unstable, the mqtt server can frequently monitor that the connection state changes, and for the million-level equipment scale, even if an abnormal connection state occurs in a small range, huge pressure is brought to the whole system.
In order to improve at least one of the above technical problems proposed by the present application, embodiments of the present application provide a data processing method and apparatus, a server, and a storage medium, and the following describes technical solutions of the present application through possible implementation manners.
The defects of the above solutions are the results of the inventor after practice and careful study, and therefore, the discovery process of the above problems and the solution proposed by the present application to the above problems should be the contribution of the inventor to the present application in the process of the present application.
To make the purpose, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be described in detail below with reference to the drawings in the embodiments of the present application, and it should be understood that the drawings in the present application are only for illustration and description purposes and are not used to limit the protection scope of the present application. Additionally, it should be understood that the schematic drawings are not necessarily drawn to scale. The flowcharts used in this application illustrate operations implemented according to some embodiments of the present application. It should be understood that the operations of the flow diagrams may be performed out of order, and steps without logical context may be performed in reverse order or simultaneously. One skilled in the art, under the guidance of this application, may add one or more other operations to, or remove one or more operations from, the flowchart.
In addition, the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present application without making any creative effort, shall fall within the protection scope of the present application.
In order to enable a person skilled in the art to make use of the present disclosure, the following embodiments are given. It will be apparent to those skilled in the art that the general principles defined herein may be applied to other embodiments and applications without departing from the spirit and scope of the application. Applications of the system or method of the present application may include web pages, plug-ins for browsers, client terminals, customization systems, internal analysis systems, or artificial intelligence robots, among others, or any combination thereof.
It should be noted that in the embodiments of the present application, the term "comprising" is used to indicate the presence of the features stated hereinafter, but does not exclude the addition of further features.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
Fig. 1 is a block diagram of a data processing system 10 according to an embodiment of the present disclosure, which provides a possible implementation manner of the data processing system 10, and referring to fig. 1, the data processing system 10 may include one or more of a server 100 and an industrial device 200, and the server 100 may include a processor for executing instruction operations.
Wherein, the server 100 is connected with the industrial device 200 in a communication way to acquire the online time of the industrial device 200.
For the server 100, it should be noted that, in some embodiments, the server 100 may be a single server device or a server group. The server group may be centralized or distributed (e.g., the server 100 may be a distributed system). In some embodiments, the server 100 can be local or remote with respect to the industrial device 200. For example, the server 100 can access information and/or data stored in the industrial device 200 via a network. As another example, the server 100 can be directly connected to the industrial device 200 to access stored information and/or data. In some embodiments, the server 100 may be implemented on a cloud platform. By way of example only, the cloud platform may include a private cloud, a public cloud, a hybrid cloud, a resilient cloud, a community cloud (community cloud), a distributed cloud, a cross-cloud (inter-cloud), a multi-cloud (multi-cloud), and the like, or any combination thereof. In some embodiments, the server 100 can be implemented on an industrial device 200.
In some embodiments, the server 100 may include a processor. The processor can process information and/or data transmitted by the industrial device 200 to perform one or more of the functions described herein.
The network may be used for the exchange of information and/or data. In some embodiments, one or more components in data processing system 10 (e.g., server 100 and industrial device 200) may send information and/or data to other components. For example, the server 100 can obtain data from the industrial device 200 via a network. In some embodiments, the network may be any type of wired or wireless network, or combination thereof.
In some embodiments, the network may include one or more network access points. For example, a network may include wired or wireless network access points, such as base stations and/or network switching nodes, through which one or more components of data processing system 10 may connect to the network to exchange data and/or information.
A database may be included in server 100 and may store data and/or instructions. In some embodiments, the database can store data obtained from the industrial device 200. In some embodiments, a database may store data and/or instructions for the exemplary methods described herein. In some embodiments, the database may include mass storage, removable storage, volatile Read-write Memory, or Read-Only Memory (ROM), among others, or any combination thereof.
In some embodiments, the database may be implemented on a cloud platform. By way of example only, the cloud platform may include a private cloud, a public cloud, a hybrid cloud, a community cloud, a distributed cloud, cross-cloud, multi-cloud, elastic cloud, or the like, or any combination thereof.
In some embodiments, a database may be connected to a network to communicate with one or more components in data processing system 10 (e.g., server 100 and industrial device 200). One or more components in data processing system 10 may access data or instructions stored in a database via a network. In some embodiments, the database may be directly connected to one or more components in the data processing system 10 (e.g., the server 100 and the industrial device 200). Alternatively, in some embodiments, the database may also be part of the server 100. In some embodiments, one or more components in data processing system 10 (e.g., server 100 and industrial device 200) may have access to a database.
As for the industrial device 200, it should be noted that the specific type of the industrial device 200 is not limited, as long as it is a device on line on a root cloud platform included in the server 100. Alternatively, industrial device 200 may include, but is not limited to, an electric meter, a controller, and the like.
Fig. 2 shows one of flowcharts of a data processing method provided in an embodiment of the present application, where the method is applicable to the server 100 shown in fig. 1 and is executed by the server 100 in fig. 1. It should be understood that, in other embodiments, the order of some steps in the data processing method of this embodiment may be interchanged according to actual needs, or some steps may be omitted or deleted. The flow of the data processing method shown in fig. 2 is described in detail below.
Step S210, acquiring the online time of the industrial device 200.
Wherein, the online time represents a time point at which the industrial equipment 200 uploads the working condition data in real time.
Step S220, calculating an expected offline time of the industrial equipment 200 according to the online time and a preset offline detection period.
Step S230, performing offline inspection on the industrial equipment 200 according to the preset offline inspection period and the expected offline time.
According to the method, the expected offline time is obtained through the online time and the preset offline detection period of the industrial equipment 200, offline detection is performed according to the preset offline detection period and the expected offline time, offline detection indirectly through the offline detection period and the expected offline time is achieved, and the problem that in the prior art, some industrial equipment 200 may be in an unstable network environment, and offline detection directly according to the network connection condition causes low reliability of offline detection is solved.
For step S210, it should be noted that, the specific manner of obtaining the online time is not limited, and may be set according to the actual application requirement. For example, in an alternative example, the server 100 includes a micro-service unit and an EMQ unit communicatively connected, the EMQ unit communicatively connected with the industrial device 200, and step S210 may include the sub-steps of:
and monitoring the EMQ unit through the micro-service unit to acquire the online time from the working condition data reported by the industrial equipment 200 to the EMQ unit.
That is to say, the industrial device 200 may be directly connected to an EMQ server unit (an mqtt server) of a root cloud platform on the server 100 or indirectly connected to the EMQ server unit through a box, the micro-service on the platform also establishes a connection with the EMQ server to monitor a message channel reported by a working condition, the industrial device 200 sends a message to the message channel on the specified EMQ server, and the micro-service monitors the message on the specified channel through the EMQ server, so as to obtain the online time of reporting the working condition data by the industrial device 200.
Before step S220, it should be noted that the data processing method provided in the embodiment of the present application may further include a step of acquiring a preset offline detection period. Therefore, on the basis of fig. 2, fig. 3 is a schematic flow chart of another data processing method provided in the embodiment of the present application, and referring to fig. 3, the data processing method may further include:
step S240, obtaining a corresponding preset offline detection period according to the category of the industrial device 200.
Alternatively, the specific value of the preset offline detection period is not limited, and may be specifically set according to the type of the industrial equipment 200. For example, in an alternative example, where the industrial device 200 is a machine tool, the preset offline sensing period may be 1 min.
As for step S220, it should be noted that, the specific calculation manner for obtaining the expected offline time of the industrial equipment 200 according to the online time and the preset offline detection period is not limited, and may be set according to actual application requirements. For example, in an alternative example, the online time can be directly added to the preset offline detection period, and the expected offline time of the industrial device 200 can be calculated. For example, when the online time of the industrial equipment 200 is 10 o 'clock 9 minutes and the preset offline detection period is 10 minutes, the offline time is expected to be 10 o' clock 19 minutes. That is, in the embodiment of the present application, after the industrial device 200 uploads the operating condition data, the industrial device goes offline after a preset offline detection period.
Further, after obtaining the projected offline time of the industrial device 200, the projected offline time of the industrial device 200 can be stored. Where the mongoDB database is included on the server 100, the expected offline time of the industrial device 200 may be stored into the mongoDB database.
For step S230, it should be noted that, a specific manner of performing the offline detection is not limited, and the offline detection may be set according to an actual application requirement. For example, in an alternative example, the server 100 stores a first detection time of the last offline detection of the industrial device 200, and the step S230 may include a step of calculating a current detection time. Therefore, on the basis of fig. 2, fig. 4 is a schematic flowchart of another data processing method provided in the embodiment of the present application, and referring to fig. 4, step S230 may include:
and S231, calculating to obtain the current detection time according to the first detection time and the preset offline detection period.
In step S232, it is determined whether the expected offline time of the industrial device 200 is between the first detection time and the current detection time.
In the embodiment of the present application, when the expected offline time of the industrial device 200 is between the first detection time and the current detection time, it is determined that the industrial device 200 is offline, and step S233 is executed; when the expected offline time of the industrial device 200 is not between the first detection time and the current detection time, it is determined that the industrial device 200 is online.
In step S233, the state of the industrial equipment 200 between the first detection time and the current detection time is set to the offline state.
In detail, in an alternative example, the first detection time of the server 100 storing the last offline detection on the industrial device 200 may be 10: 5 minutes, the preset offline detection period is 10 minutes, and the current detection time may be calculated to be 10: 15 minutes. That is, the last offline detection is performed at 10 point 5, and the current offline detection is performed at 10 point 15, so that the timing offline detection is realized. And after the current detection time is obtained, starting a timing task, regularly inquiring the industrial equipment 200 of which the expected offline time is in the middle of the last offline detection time to the current offline detection time from the mongoDB database, if the industrial equipment 200 is found, judging that the industrial equipment 200 is offline, setting the state of the industrial equipment 200 between the first detection time and the current detection time to be an offline state, and broadcasting a message.
Further, after step S233, the data processing method provided in the embodiment of the present application may further include a step of updating the first detection time, and therefore, the data processing method may further include the following sub-steps:
and updating the first detection time to the current detection time.
That is, after the step of the current offline detection is completed, the current detection time may be stored as the updated first detection time, so as to calculate the time of the next offline detection according to the current detection time at the time of the next detection.
For step S230, it should be noted that the specific way of performing the offline detection is not limited, and may be set according to the actual application requirement. For another example, in another alternative example, step S230 can include the step of detecting whether industrial equipment 200 uploads new operating condition data. Therefore, on the basis of fig. 2, fig. 5 is a schematic flowchart of another data processing method provided in the embodiment of the present application, and referring to fig. 5, step S230 may include:
step S234, detecting whether the industrial equipment 200 uploads new operating condition data before the expected offline time within a preset offline detection period.
In the embodiment of the present application, when it is detected that the industrial equipment 200 uploads new operating condition data before the expected offline time within a preset offline detection period, it is determined that the industrial equipment 200 is online; when it is detected within the preset offline detection period that the industrial equipment 200 does not upload new operating condition data before the expected offline time, it is determined that the industrial equipment 200 is offline, and step S235 is performed.
In step S235, the state of the industrial equipment 200 before the expected offline time in the preset offline detection period is set as the offline state.
In detail, when the industrial device 200 is a machine tool, the machine tool establishes a network connection with the root cloud platform on the server 100, and the online state of the machine tool can be monitored through the root cloud platform. Due to the unstable network of the field environment, the network connection between the machine tool and the root cloud platform is often disconnected. An offline detection period can be set on the root cloud platform for the equipment to be 1min, the machine tool reports a working condition for several seconds normally, when the network connection of the machine tool is disconnected, the root cloud platform cannot immediately determine that the machine tool is offline, and the machine tool can be seen on the platform at the moment; if the platform does not receive the information reported by the machine tool within 1min (the set off-line detection period), the equipment is determined to be off-line, and meanwhile, the machine tool can be seen on the platform.
It should be noted that, when the industrial equipment 200 uploads new operating condition data before the expected offline time within the preset offline detection period, the data processing method provided in the embodiment of the present application may further include a step of obtaining the new expected offline time. Therefore, on the basis of fig. 5, fig. 6 is a schematic flowchart of another data processing method provided in the embodiment of the present application, and referring to fig. 6, the data processing method may further include:
and step S236, determining a new expected offline time according to the new online time and the preset offline detection period.
In step S237, the industrial device 200 is offline tested according to the preset offline testing period and the new expected offline time.
In detail, when the online time of the first uploading of the working condition data by the industrial equipment 200 is 10 o 'clock 9 minutes and the preset offline detection period is 10 minutes, the first expected offline time is calculated to be 10 o' clock 19 minutes. At 10 o ' clock 15, the industrial equipment 200 uploads new working condition data, that is, the second time online time is 10 o ' clock 15 o ' clock, the second time predicted offline time is 10 o ' clock 25 o ' clock, so that offline detection is performed according to the second time predicted offline time, and offline detection is performed according to the latest predicted offline time calculated according to the latest online time of the industrial equipment 200, thereby improving the accuracy of offline detection.
With reference to fig. 7, an embodiment of the present application further provides a data processing apparatus 700, where functions implemented by the data processing apparatus 700 correspond to steps executed by the foregoing method. The data processing device 700 may be understood as a processor of the server 100, or may be understood as a component that is independent of the server 100 or the processor and that implements the functions of the present application under the control of the server 100. The data processing apparatus 700 may include an online time obtaining module 710, an expected offline time calculating module 720, and an offline detecting module 730.
The online time obtaining module 710 is configured to obtain an online time of the industrial device 200, where the online time represents a time point at which the industrial device 200 uploads the operating condition data in real time. In this embodiment of the application, the online time obtaining module 710 may be configured to perform step S210 shown in fig. 2, and for the relevant content of the online time obtaining module 710, reference may be made to the foregoing description of step S210.
The expected offline time calculating module 720 is configured to calculate an expected offline time of the industrial equipment 200 according to the online time and a preset offline detection period. In the embodiment of the present application, the off-line time calculation module 720 may be configured to perform step S220 shown in fig. 2, and reference may be made to the foregoing description of step S220 for relevant contents of the off-line time calculation module 720.
The offline detection module 730 is configured to perform offline detection on the industrial apparatus 200 according to a preset offline detection period and a predicted offline time. In this embodiment, the offline detection module 730 can be used to execute step S230 shown in fig. 2, and reference may be made to the description of step S230 for relevant contents of the offline detection module 730.
In addition, an embodiment of the present application further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the computer program performs the steps of the data processing method.
For a computer program product of the data processing method provided in this embodiment, the computer program product includes a computer readable storage medium storing a program code, and instructions included in the program code may be used to execute steps of the data processing method in the foregoing method embodiment.
To sum up, according to the data processing method and apparatus, the server and the storage medium provided in the embodiments of the present application, the expected offline time is obtained through the online time and the preset offline detection period of the industrial device, and the offline detection is performed according to the preset offline detection period and the expected offline time, so that the offline detection is indirectly performed through the offline detection period and the expected offline time, which improves the problem that some industrial devices in the prior art may be in an unstable network environment and the reliability of the offline detection is low due to the fact that the offline detection is directly performed according to the network connection condition.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. The apparatus embodiments described above are merely illustrative, and for example, the flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods and computer program products according to embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
In addition, functional modules in the embodiments of the present application may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
The functions, if implemented in the form of software functional modules and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server 100, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk, and various media capable of storing program codes.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in the process, method, article, or apparatus that comprises the element.
The above description is only a preferred embodiment of the present application and is not intended to limit the present application, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (9)

1. A data processing method is applied to a server, the server is in communication connection with industrial equipment, first detection time of offline detection of the industrial equipment last time is stored in the server, and the data processing method comprises the following steps:
acquiring the online time of the industrial equipment, wherein the online time represents the time point of uploading the working condition data by the industrial equipment in real time;
calculating to obtain the predicted off-line time of the industrial equipment according to the on-line time and a preset off-line detection period;
according to the preset offline detection period and the expected offline time, the offline detection of the industrial equipment comprises the following steps:
calculating to obtain current detection time according to the first detection time and a preset offline detection period; judging whether the predicted offline time of the industrial equipment is between the first detection time and the current detection time; and if so, setting the state of the industrial equipment between the first detection time and the current detection time as an offline state.
2. The data processing method of claim 1, wherein the data processing method further comprises:
and updating the first detection time to the current detection time.
3. The data processing method of claim 1, wherein the step of performing offline inspection of the industrial equipment according to the preset offline inspection period and the expected offline time comprises:
detecting whether the industrial equipment uploads new working condition data before the predicted offline time or not in the preset offline detection period;
if not, setting the state of the industrial equipment before the predicted offline time in the preset offline detection period as an offline state.
4. The data processing method of claim 3, wherein the data processing method further comprises:
when the industrial equipment uploads new working condition data, determining new predicted offline time according to new online time and the preset offline detection period;
and carrying out off-line detection on the industrial equipment according to the preset off-line detection period and the new predicted off-line time.
5. The data processing method of claim 1, wherein the server comprises a micro service unit and an EMQ unit which are in communication connection, the EMQ unit is in communication connection with the industrial equipment, and the step of acquiring the online time of the industrial equipment comprises:
and monitoring the EMQ unit through the micro-service unit to obtain the online time from the industrial equipment to report the working condition data to the EMQ unit.
6. The data processing method of any one of claims 1 to 5, further comprising the step of obtaining a preset offline detection period, the step comprising:
and acquiring a corresponding preset offline detection period according to the type of the industrial equipment.
7. A data processing apparatus, applied to a server, the server being in communication connection with an industrial device, the server storing therein a first detection time for last offline detection of the industrial device, the data processing apparatus comprising:
the online time acquisition module is used for acquiring online time of the industrial equipment, wherein the online time represents a time point of real-time uploading of working condition data by the industrial equipment;
the estimated offline time calculation module is used for calculating and obtaining the estimated offline time of the industrial equipment according to the online time and a preset offline detection period;
the off-line detection module is used for carrying out off-line detection on the industrial equipment according to the preset off-line detection period and the predicted off-line time, and comprises: calculating to obtain current detection time according to the first detection time and a preset offline detection period; judging whether the predicted offline time of the industrial equipment is between the first detection time and the current detection time; and if so, setting the state of the industrial equipment between the first detection time and the current detection time as an offline state.
8. A server, comprising a memory and a processor for executing an executable computer program stored in the memory to implement the data processing method of any one of claims 1 to 6.
9. A storage medium, characterized in that a computer program is stored thereon, which when executed performs the steps of the data processing method of any one of claims 1-6.
CN202011540388.6A 2020-12-23 2020-12-23 Data processing method and device, server and storage medium Active CN112666906B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011540388.6A CN112666906B (en) 2020-12-23 2020-12-23 Data processing method and device, server and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011540388.6A CN112666906B (en) 2020-12-23 2020-12-23 Data processing method and device, server and storage medium

Publications (2)

Publication Number Publication Date
CN112666906A CN112666906A (en) 2021-04-16
CN112666906B true CN112666906B (en) 2022-09-30

Family

ID=75409076

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011540388.6A Active CN112666906B (en) 2020-12-23 2020-12-23 Data processing method and device, server and storage medium

Country Status (1)

Country Link
CN (1) CN112666906B (en)

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104656531A (en) * 2015-01-16 2015-05-27 张泽 Monitoring method and device for intelligent equipment
CN107197031A (en) * 2017-06-19 2017-09-22 深圳市盛路物联通讯技术有限公司 A kind of terminal unit status detection method and system applied to Internet of Things
CN107800589A (en) * 2017-10-31 2018-03-13 普天东方通信集团有限公司 To the monitoring method of cloud platform access device, device and its cloud platform used
CN109450734A (en) * 2018-11-27 2019-03-08 四川长虹电器股份有限公司 Zigbee coordinator heartbeat management method
CN111031565B (en) * 2019-11-25 2023-01-24 青岛海信智慧生活科技股份有限公司 Method and device for identifying off-line state of ZigBee device
CN111064634B (en) * 2019-12-06 2021-03-16 中盈优创资讯科技有限公司 Method and device for monitoring mass Internet of things terminal online state
CN111181804B (en) * 2019-12-20 2022-01-28 中移(杭州)信息技术有限公司 Intelligent device offline state automatic detection method and device, electronic device and medium
CN111130951B (en) * 2019-12-31 2022-08-23 中消云(北京)物联网科技研究院有限公司 Equipment state detection method, device and storage medium
CN111586118A (en) * 2020-04-26 2020-08-25 珠海格力电器股份有限公司 Data processing method and device and computer equipment

Also Published As

Publication number Publication date
CN112666906A (en) 2021-04-16

Similar Documents

Publication Publication Date Title
CN110430260B (en) Robot cloud platform based on big data cloud computing support and working method
US11067973B2 (en) Data collection system, abnormality detection method, and gateway device
US7409316B1 (en) Method for performance monitoring and modeling
CN109934356B (en) Machine room inspection method based on big data and related equipment
US7082381B1 (en) Method for performance monitoring and modeling
CN107241229B (en) Service monitoring method and device based on interface testing tool
CN109143094B (en) Abnormal data detection method and device for power battery
US7197428B1 (en) Method for performance monitoring and modeling
US7369967B1 (en) System and method for monitoring and modeling system performance
US7617313B1 (en) Metric transport and database load
Mart et al. Observability in kubernetes cluster: Automatic anomalies detection using prometheus
CN114356577A (en) System capacity estimation method and device
CN112666906B (en) Data processing method and device, server and storage medium
CN113067802B (en) User identification method, device, equipment and computer readable storage medium
KR20200138565A (en) Method and apparatus for managing a plurality of remote radio heads in a communication network
EP3093770A2 (en) System and method for the creation and detection of process fingerprints for monitoring in a process plant
CN113342625A (en) Data monitoring method and system
CN112686406A (en) Data processing method and device, server and storage medium
CN112380140A (en) Intelligent cabin data testing method and system
CN112561097A (en) Bearing monitoring method and system based on cloud and fog edge cooperation
CN109033446B (en) Corrosion type judging method and device
CN116634493A (en) Alarm information processing method and device, equipment and computer readable storage medium
WO2023200597A1 (en) Automated positive train control event data extraction and analysis engine for performing root cause analysis of unstructured data
CN113726808A (en) Website monitoring method, device, equipment and storage medium
GB2382263A (en) Network/system modelling using node discovery and node associated data

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
CB02 Change of applicant information

Address after: Room 303-309, No.3, Pazhou Avenue East Road, Haizhu District, Guangzhou City, Guangdong Province 510000

Applicant after: Shugen Internet Co.,Ltd.

Address before: Unit 12-30, 4th floor, Xigang office building, Guangzhou international media port, 218 and 220 Yuejiang West Road, Haizhu District, Guangzhou City, Guangdong Province 510000

Applicant before: IROOTECH TECHNOLOGY Co.,Ltd.

CB02 Change of applicant information
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant