CN116800835A - Monitoring data acquisition method, device, equipment and medium - Google Patents
Monitoring data acquisition method, device, equipment and medium Download PDFInfo
- Publication number
- CN116800835A CN116800835A CN202310778441.3A CN202310778441A CN116800835A CN 116800835 A CN116800835 A CN 116800835A CN 202310778441 A CN202310778441 A CN 202310778441A CN 116800835 A CN116800835 A CN 116800835A
- Authority
- CN
- China
- Prior art keywords
- target edge
- preset
- target
- monitoring data
- cloud
- 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.)
- Pending
Links
- 238000012544 monitoring process Methods 0.000 title claims abstract description 145
- 238000000034 method Methods 0.000 title claims abstract description 56
- 230000006854 communication Effects 0.000 claims abstract description 67
- 238000004891 communication Methods 0.000 claims abstract description 67
- 238000013480 data collection Methods 0.000 claims description 26
- 238000012806 monitoring device Methods 0.000 claims description 22
- 238000013500 data storage Methods 0.000 claims description 20
- 238000004590 computer program Methods 0.000 claims description 15
- 238000010586 diagram Methods 0.000 description 6
- 238000012545 processing Methods 0.000 description 4
- 230000007175 bidirectional communication Effects 0.000 description 3
- 230000005540 biological transmission Effects 0.000 description 3
- 230000006978 adaptation Effects 0.000 description 2
- 238000004422 calculation algorithm Methods 0.000 description 2
- 230000002457 bidirectional effect Effects 0.000 description 1
- 238000004364 calculation method Methods 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000006870 function Effects 0.000 description 1
- 230000010354 integration Effects 0.000 description 1
- 238000007726 management method Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/50—Network services
- H04L67/56—Provisioning of proxy services
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L12/00—Data switching networks
- H04L12/28—Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
- H04L12/46—Interconnection of networks
- H04L12/4633—Interconnection of networks using encapsulation techniques, e.g. tunneling
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/12—Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/14—Session management
- H04L67/141—Setup of application sessions
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Health & Medical Sciences (AREA)
- Computing Systems (AREA)
- General Health & Medical Sciences (AREA)
- Medical Informatics (AREA)
- Computer And Data Communications (AREA)
Abstract
The application discloses a monitoring data acquisition method, a device, equipment and a medium, which are applied to cloud communication devices pre-configured at cloud nodes, and relate to the field of computers, wherein the method comprises the following steps: when target equipment information sent by a preset cloud data acquisition and storage device is received through a preset first port, determining a target edge proxy device in target edge equipment which is uniquely corresponding to the target equipment information, and sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link which is established with the target edge proxy device in advance; and receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through a preset first port. According to the method and the device, the network tunnels of the edge and the cloud can be opened, so that the cloud can directly communicate with the edge, and the high efficiency of the cloud node in pulling the edge monitoring data is improved.
Description
Technical Field
The present application relates to the field of computers, and in particular, to a method, apparatus, device, and medium for monitoring data acquisition.
Background
With the development of computer technology, computer systems are becoming larger and larger, and the integration of various devices from the original stand-alone processing to the current cluster processing is required, so that great challenges are brought to the management and operation of the systems. The advent of Kubernetes (i.e., K8 s) eases the difficulty of deployment upgrades, making service deployment easy to operate and manage. In the kubernates cluster, the cluster is divided into master nodes and node nodes, all nodes are on the same network plane, communication can be carried out between the nodes, prometaus can also easily communicate with each node, monitoring data of the nodes are pulled, but along with expansion of a distributed system, a large amount of calculation needs to be completed at a near-side end, a cloud-side-end network architecture limits communication between a cloud component prometaus and edge equipment, the edge equipment can directly request cloud service, the cloud component cannot know a specific address of the side end, the prometaus acquires data of the monitored equipment in a pulling mode, and equipment monitoring data of the side end cannot be acquired in an http direct connection mode.
Currently, promethaus supports a cascading mode and a pushgateway mode. The cascading mode is that a prometaheus is deployed at the edge, edge data are collected, and then the prometaheus at the edge report the data to cloud prometaheus service. However, since the components of promethaus are relatively large, the overhead of the edge device running the cascaded promethaus is too large. Or the side reports the self data to the pushgateway of the promethause server, and the monitoring component of the edge equipment needs to be modified in the mode, so that the component is greatly modified.
From the above, how to improve the efficiency of the cloud node to pull the edge monitoring data in the process of acquiring the monitoring data of the edge node by the cloud node is a problem to be solved in the field.
Disclosure of Invention
Accordingly, the present application is directed to a method, apparatus, device and medium for collecting monitoring data, which can open a network tunnel between a side and a cloud end, so that the cloud end can directly communicate with the side to improve the efficiency of pulling monitoring data of the side by a cloud node. The specific scheme is as follows:
in a first aspect, the application discloses a monitoring data acquisition method applied to a cloud communication device pre-configured at a cloud node, comprising:
when target equipment information sent by a preset cloud data acquisition and storage device is received through a preset first port, determining a target edge proxy device in target edge equipment which is uniquely corresponding to the target equipment information, and sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link which is established with the target edge proxy device in advance;
and receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port.
Optionally, before determining the target edge proxy device in the target edge device uniquely corresponding to the target device information when the target device information sent by the preset cloud data acquisition storage device is received through the preset first port, the method further includes:
receiving a first long connection request which is sent by a target edge proxy device and contains equipment information of target edge equipment, and establishing a long connection link between the target edge proxy devices which uniquely corresponds to the target edge equipment;
or, receiving a second long connection request which is sent by the target edge proxy device when the target edge proxy device detects that the original long link with the cloud communication device is disconnected, is used for reconnecting with the cloud communication device and comprises equipment information of target edge equipment, and establishing a long connection link between the target edge proxy devices which uniquely correspond to the target edge equipment.
Optionally, after receiving the long connection request including the device information of the target edge device sent by the target edge proxy device, the method further includes:
registering a unique identifier for the target edge device based on the device information of the target edge device, and updating the unique identifier of the target edge device into a preset registration device list.
Optionally, when the target device information sent by the preset cloud data acquisition and storage device is received through the preset first port, determining a target edge proxy device in the target edge device uniquely corresponding to the target device information includes:
when a preset cloud data acquisition and storage device is received through a preset first port, accessing the preset registration equipment list through the preset first port, determining and sending a unique identifier of target edge equipment from the preset registration equipment list, and determining a target edge proxy device in the target edge equipment based on the unique identifier of the target edge equipment.
Optionally, the monitoring data acquisition method further includes:
and configuring the Prometaus server as the preset cloud data acquisition and storage device.
Optionally, the receiving the monitoring data returned by the target edge proxy device and returning the monitoring data to the preset cloud data collection and storage device through the preset first port includes:
and receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port so that the preset cloud data acquisition and storage device can store the monitoring data to a preset storage position.
Optionally, the sending, to the target edge proxy device, a data request for obtaining monitoring data of the target edge device based on a long connection link previously established with the target edge proxy device, and receiving the monitoring data returned by the target edge proxy device includes:
and sending a data request for acquiring the monitoring data of the target edge equipment to the target edge proxy device based on a long connection link established with the target edge proxy device in advance, so that the target edge proxy device forwards the data request to a target edge monitoring device uniquely corresponding to the target edge proxy device based on a preset second port on the target edge proxy device, and then receiving the monitoring data returned by the target edge monitoring device through the preset second port.
In a second aspect, the present application discloses a monitoring data acquisition device, applied to a cloud communication device preconfigured at a cloud node, comprising:
the data request module is used for determining a target edge proxy device in target edge equipment which is uniquely corresponding to target equipment information when target equipment information sent by a preset cloud data acquisition storage device is received through a preset first port, and sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link which is established with the target edge proxy device in advance;
The data receiving module is used for receiving the monitoring data returned by the target edge proxy device and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port.
In a third aspect, the present application discloses an electronic device, comprising:
a memory for storing a computer program;
and the processor is used for executing the computer program to realize the monitoring data acquisition method.
In a fourth aspect, the present application discloses a computer storage medium for storing a computer program; wherein the computer program when executed by a processor implements the steps of the disclosed monitoring data acquisition method.
When the cloud communication device receives target equipment information sent by a preset cloud data acquisition and storage device through a preset first port, determining a target edge proxy device in target edge equipment uniquely corresponding to the target equipment information, sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link established with the target edge proxy device in advance, then receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port. In this way, when the edge and the cloud can only access in one direction, the application communicates through the long connection link between the cloud communication device of the cloud node and the edge proxy device in the edge equipment, and in such a way, the data access is opened by establishing the long-chain tunnel, the problem of monitoring data acquisition under the condition that the cloud and the edge network are not opened is solved, the data can be directly acquired by opening the network tunnel under the condition that the component realization mode is not changed, only simple configuration is needed, and the utilization of the resources of the edge is saved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings that are required to be used in the embodiments or the description of the prior art will be briefly described below, and it is obvious that the drawings in the following description are only embodiments of the present application, and that other drawings can be obtained according to the provided drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a method for monitoring data acquisition provided by the application;
FIG. 2 is a flowchart of a specific method for monitoring data collection provided by the present application;
FIG. 3 is a schematic view of an overall structure according to the present application;
FIG. 4 is a schematic diagram of a monitoring data acquisition device according to the present application;
fig. 5 is a block diagram of an electronic device according to the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present application, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
In the prior art, promethaus supports a cascade mode and a pushgateway mode. The cascading mode is that a prometaheus is deployed at the edge, edge data are collected, and then the prometaheus at the edge report the data to cloud prometaheus service. However, since the components of promethaus are relatively large, the overhead of the edge device running the cascaded promethaus is too large. Or the side reports the self data to the pushgateway of the promethause server, and the monitoring component of the edge equipment needs to be modified in the mode, so that the component is greatly modified. Therefore, in the prior art, in the process of acquiring the monitoring data of the edge node by the cloud node, an efficient method is needed to improve the efficiency of the monitoring data of the pulling edge end of the cloud node. According to the method and the device for the cloud node to draw the edge monitoring data, the network tunnels of the edge and the cloud can be opened, so that the cloud can directly communicate with the edge, and the high efficiency of the cloud node to draw the edge monitoring data is improved.
The embodiment of the application discloses a monitoring data acquisition method applied to a cloud communication device pre-configured at a cloud node, as shown in fig. 1, comprising the following steps:
step S11: when target equipment information sent by a preset cloud data acquisition and storage device is received through a preset first port, determining a target edge proxy device in target edge equipment which is uniquely corresponding to the target equipment information, and sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link which is established with the target edge proxy device in advance.
In this embodiment, the cloud communication device is located on a cloud node, and the target edge proxy device is located on an edge node. In a preferred embodiment, the preset cloud data collection and storage device and the cloud communication device are both located on the cloud node. In this embodiment, the cloud data acquisition and storage device is preset to be capable of pulling and storing the monitoring data, and the cloud data acquisition and storage device cannot acquire the monitoring data of the side device in a direct pulling mode, and pulls the monitoring data of the side by calling the cloud communication device. The cloud communication device is responsible for registering the edge proxy device and establishing a long link with the edge device, and when the cloud data acquisition device requests the data of the edge device, the cloud communication device can forward a specific request to the proxy device of the corresponding edge.
Specifically, in this embodiment, the preset cloud data collection and storage device may pull the monitoring data from the cloud communication device through pull, that is, by means of information pull. The cloud communication device is configured with a preset first port, and the preset cloud data acquisition and storage device can acquire monitoring data in a port calling mode. The method for collecting the monitoring data can also comprise the following steps: and configuring the Prometaus server as the preset cloud data acquisition and storage device. That is, the preset cloud data collection and storage device may be a server of promethaus.
In this embodiment, the preset cloud data collection and storage device may send target device information to the cloud communication device through a preset first interface, where the preset first interface is located on the cloud communication device, and the target device information is used for specifying a target device that the preset cloud data collection and storage device wants to pull the monitoring data. When the cloud communication device receives the target equipment information, determining a target edge proxy device in target edge equipment uniquely corresponding to the target equipment information, and sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link established with the target edge proxy device in advance. It can be understood that the target device information uniquely corresponds to the target edge device, and the target edge device is preconfigured with the target edge proxy device. The cloud communication device has established a long connection link with the target edge proxy device in advance, and when the cloud communication device communicates with the target edge proxy device, communication is completed based on the long connection link. It should be noted that the long connection link in the present invention is preferably a bi-directional communication link established by means of a TCP (i.e. Transmission Control Protocol, transmission control protocol) long link.
In this embodiment, when the target device information sent by the preset cloud data collection and storage device is received through the preset first port, before determining the target edge proxy device in the target edge device uniquely corresponding to the target device information, the method may further include: receiving a first long connection request which is sent by a target edge proxy device and contains equipment information of target edge equipment, and establishing a long connection link between the target edge proxy devices which uniquely corresponds to the target edge equipment; or, receiving a second long connection request which is sent by the target edge proxy device when the target edge proxy device detects that the original long link with the cloud communication device is disconnected, is used for reconnecting with the cloud communication device and comprises equipment information of target edge equipment, and establishing a long connection link between the target edge proxy devices which uniquely correspond to the target edge equipment.
It may be appreciated that in this embodiment, the target edge proxy device is located in an edge node, deployed on each side device, and is responsible for actively connecting to the cloud communication device, establishing a long link after connection, and reporting basic information of the edge device to the cloud communication device. If the long link is broken, it is responsible for reconnecting.
In this embodiment, after receiving the long connection request including the device information of the target edge device sent by the target edge proxy apparatus, the method may further include: registering a unique identifier for the target edge device based on the device information of the target edge device, and updating the unique identifier of the target edge device into a preset registration device list.
In this embodiment, when receiving, through a preset first port, target device information sent by a preset cloud data acquisition and storage device, determining a target edge proxy device in a target edge device that uniquely corresponds to the target device information may include: when a preset cloud data acquisition and storage device is received through a preset first port, accessing the preset registration equipment list through the preset first port, determining and sending a unique identifier of target edge equipment from the preset registration equipment list, and determining a target edge proxy device in the target edge equipment based on the unique identifier of the target edge equipment.
That is, in the present invention, each edge proxy device sends a long connection request to the cloud communication device to establish a bidirectional communication link with the cloud communication device. After receiving the request of the edge proxy device, the cloud communication device registers a unique id (Identity document, unique identifier) for the edge device according to the information of the edge device in the request, can identify each edge device, establishes a long TCP link, and receives the sending data through the link. Specifically, the cloud communication device records the registered edge devices to a preset registration device list, and unique ids corresponding to the devices of each registered edge device are stored in the preset registration device list. The preset cloud data collection and storage device can access a preset registration device list of all registration devices through the preset first port, after determining which registered devices exist currently, the cloud communication device is sent with the target device information to pull the monitoring data of the calling device, at this time, the collection and storage device is not used for directly calling the service of the device, because the network is not connected, but an interface of the cloud communication device is called, the device information, in a preferred embodiment, the device id can be used as the target device information to be transmitted into the cloud communication device.
In addition, in the invention, the edge proxy device also sends the information of the edge proxy device to the cloud communication device when initializing.
Step S12: and receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port.
In this embodiment, the receiving the monitoring data returned by the target edge proxy device and returning the monitoring data to the preset cloud data collection and storage device through the preset first port may include: and receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port so that the preset cloud data acquisition and storage device can store the monitoring data to a preset storage position.
That is, in the present invention, the preset cloud data collection and storage device further has a function of monitoring data storage, and when the monitoring data is pulled from the cloud communication device, the monitoring data can be stored. It can be understood that when the method of the invention is applied to Prometheus, the cloud node in Prometheus can efficiently acquire the monitoring data of the side, and only simple configuration is needed in the whole process, thereby saving the utilization of the resources of the side.
In this embodiment, when the cloud communication device receives, through a preset first port, target device information sent by a preset cloud data acquisition and storage device, a target edge proxy device in a target edge device uniquely corresponding to the target device information is determined, and based on a long connection link established with the target edge proxy device in advance, a data request for acquiring monitoring data of the target edge device is sent to the target edge proxy device, then the monitoring data returned by the target edge proxy device is received, and the monitoring data is returned to the preset cloud data acquisition and storage device through the preset first port. In this way, when the edge and the cloud can only access in one direction, the invention communicates through the long connection link between the cloud communication device of the cloud node and the edge proxy device in the edge equipment, and in such a way, the data access is opened by establishing the long-chain tunnel, the problem of monitoring data acquisition under the condition that the cloud and the edge network are not opened is solved, the data can be directly acquired by opening the network tunnel under the condition that the component realization mode is not changed, only simple configuration is needed, and the utilization of the resources of the edge is saved.
Fig. 2 is a flowchart of a specific monitoring data collection method according to an embodiment of the present application. Referring to fig. 2, the method includes:
step S21: when target equipment information sent by a preset cloud data acquisition and storage device is received through a preset first port, determining a target edge proxy device in target edge equipment which is uniquely corresponding to the target equipment information.
For more specific processing in step S21, reference may be made to the corresponding content disclosed in the foregoing embodiment, and a detailed description is omitted herein.
Step S22: and sending a data request for acquiring the monitoring data of the target edge equipment to the target edge proxy device based on a long connection link established with the target edge proxy device in advance, so that the target edge proxy device forwards the data request to a target edge monitoring device uniquely corresponding to the target edge proxy device based on a preset second port on the target edge proxy device, and then receiving the monitoring data returned by the target edge monitoring device through the preset second port.
It should be noted that, in the specific embodiment of the present application, each edge node is disposed with an edge proxy device and an edge monitoring device, where the edge monitoring device is responsible for collecting monitoring data of an edge device, and provides the collected data to the corresponding edge proxy device through a port. In addition, in this embodiment, the preset cloud data collection and storage device may pull the monitoring data from the cloud communication device in a pull, i.e. information pull, manner, and the edge proxy device may also pull the monitoring data from the edge monitoring device in a pull monitoring data manner. The edge proxy device is connected with the edge monitoring device through a port, and the edge monitoring device transmits monitoring data to the edge proxy device through a preset second port.
In a specific embodiment, the preset cloud data collection and storage device pulls the monitoring data from the cloud communication device by using the information pulling mode through the preset first interface, when the cloud communication device acquires the monitoring data pulled from the edge monitoring device by the edge proxy device through the pull monitoring data mode through the long connection link, the information is returned to the cloud communication device, so that the whole process of pulling the monitoring data through the preset cloud data collection and storage device is completed, and the preset cloud data collection and storage device acquires the monitoring data of the side end.
Fig. 3 is a schematic diagram of an overall structure of the present invention, in which a cloud end data acquisition and storage device and a cloud end communication device are located on a cloud end node, and an edge proxy device and an edge monitoring device are deployed in each edge node. And a bidirectional link tunnel is established between the cloud communication device and each edge proxy device, and each edge proxy device is respectively and uniquely connected with an edge monitoring device. The cloud data acquisition and storage device pulls the monitoring data from the cloud communication device in a pull mode, and the edge proxy device pulls the monitoring data monitored in the edge monitoring device from the edge monitoring device in a pull mode.
Step S23: and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port.
For more specific processing in step S23, reference may be made to the corresponding content disclosed in the foregoing embodiment, and a detailed description is omitted herein.
It should be noted that, the preset cloud data collection and storage device may be a server of Prometaus, in a specific embodiment, the edge device actively connects with the cloud to establish a long connection link so as to establish a bidirectional communication tunnel, the cloud collection service obtains data through the tunnel, the edge device deploys the agent based on the edge agent device, actively registers on the cloud communication device, the cloud communication device is responsible for maintaining a list of the agent agents, establishes a two-wire communication channel, the cloud data collection and storage device does not directly access the edge service, but accesses the cloud communication device of the adaptation layer, the adaptation layer is responsible for sending requests to each agent, the agent is responsible for invoking the monitoring service, the collected data is returned to the cloud communication device in an original path, and the cloud communication device returns the data to the cloud data collection and storage device. When the method is applied to Prometheus, the cloud node in Prometheus can acquire the monitoring data of the side, and only simple configuration is needed in the whole process, so that the utilization of the resources of the side is saved.
In this embodiment, when target device information sent by a preset cloud data acquisition and storage device is received through a preset first port, a target edge proxy device in target edge devices uniquely corresponding to the target device information is determined. And sending a data request for acquiring the monitoring data of the target edge equipment to the target edge proxy device based on a long connection link established with the target edge proxy device in advance, so that the target edge proxy device forwards the data request to a target edge monitoring device uniquely corresponding to the target edge proxy device based on a preset second port on the target edge proxy device, and then receiving the monitoring data returned by the target edge monitoring device through the preset second port. And returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port. In this way, when the edge and the cloud can only access in one direction, the invention communicates through the long connection link between the cloud communication device of the cloud node and the edge proxy device in the edge equipment, and in such a way, the data access is opened by establishing the long-chain tunnel, the problem of monitoring data acquisition under the condition that the cloud and the edge network are not opened is solved, the data can be directly acquired by opening the network tunnel under the condition that the component realization mode is not changed, only simple configuration is needed, and the utilization of the resources of the edge is saved. The preset cloud data acquisition and storage device is connected with the cloud communication device through a port, and the edge proxy device is connected with the edge monitoring device through the port, so that the monitoring acquisition efficiency is improved.
Referring to fig. 4, an embodiment of the present application discloses a monitoring data acquisition device, which is applied to a cloud communication device pre-configured at a cloud node, and specifically may include:
the data request module 11 is configured to determine a target edge proxy device in a target edge device that uniquely corresponds to target device information when target device information sent by a preset cloud data acquisition and storage device is received through a preset first port, and send a data request for acquiring monitoring data of the target edge device to the target edge proxy device based on a long connection link that is established with the target edge proxy device in advance;
the data receiving module 12 is configured to receive the monitoring data returned by the target edge proxy device, and return the monitoring data to the preset cloud data collection and storage device through the preset first port.
When the cloud communication device receives target equipment information sent by a preset cloud data acquisition and storage device through a preset first port, determining a target edge proxy device in target edge equipment uniquely corresponding to the target equipment information, sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link established with the target edge proxy device in advance, then receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port. In this way, when the edge and the cloud can only access in one direction, the application communicates through the long connection link between the cloud communication device of the cloud node and the edge proxy device in the edge equipment, and in such a way, the data access is opened by establishing the long-chain tunnel, the problem of monitoring data acquisition under the condition that the cloud and the edge network are not opened is solved, the data can be directly acquired by opening the network tunnel under the condition that the component realization mode is not changed, only simple configuration is needed, and the utilization of the resources of the edge is saved.
In some specific embodiments, the monitoring data acquisition device further includes:
a first request receiving unit, configured to receive a first long connection request including device information of a target edge device sent by a target edge proxy device, and establish a long connection link between target edge proxy devices that uniquely corresponds to the target edge device;
or, a second request receiving unit, configured to receive a second long connection request that is sent when the target edge proxy device detects that the original long link with the cloud communication device is disconnected, and is used for reconnecting with the cloud communication device and includes device information of the target edge device, and establish a long connection link between the target edge proxy devices that uniquely corresponds to the target edge device.
In some specific embodiments, the monitoring data acquisition device further includes:
and the list updating unit is used for registering the unique identifier for the target edge equipment based on the equipment information of the target edge equipment and updating the unique identifier of the target edge equipment into a preset registration equipment list.
In some embodiments, the data request module 11 specifically includes:
The device determining unit is used for determining a target edge proxy device in the target edge device based on the unique identifier of the target edge device when the preset cloud data acquisition storage device is received through the preset first port, accesses the preset registration device list through the preset first port, and determines and sends the unique identifier of the target edge device from the preset registration device list.
In some embodiments, the monitoring data acquisition device further includes:
and the device configuration unit is used for configuring the Prometaus server as the preset cloud data acquisition and storage device.
In some embodiments, the data receiving module 12 includes:
the data receiving unit is used for receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port so that the preset cloud data acquisition and storage device can store the monitoring data to a preset storage position.
In some embodiments, the data request module 11 includes:
and the monitoring device application unit is used for sending a data request for acquiring the monitoring data of the target edge equipment to the target edge proxy device based on a long connection link which is established with the target edge proxy device in advance, so that the target edge proxy device forwards the data request to the target edge monitoring device which is uniquely corresponding to the target edge proxy device based on a preset second port on the target edge proxy device, and then receives the monitoring data returned by the target edge monitoring device through the preset second port.
Further, the embodiment of the present application further discloses an electronic device, and fig. 5 is a block diagram of an electronic device 20 according to an exemplary embodiment, where the content of the diagram is not to be considered as any limitation on the scope of use of the present application.
Fig. 5 is a schematic structural diagram of an electronic device 20 according to an embodiment of the present application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, a display screen 24, an input-output interface 25, a communication interface 26, and a communication bus 27. Wherein the memory 22 is used for storing a computer program, and the computer program is loaded and executed by the processor 21 to implement the following monitoring data acquisition method:
when target equipment information sent by a preset cloud data acquisition and storage device is received through a preset first port, determining a target edge proxy device in target edge equipment which is uniquely corresponding to the target equipment information, and sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link which is established with the target edge proxy device in advance;
and receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port.
In addition, the electronic device 20 in this embodiment may be specifically an electronic computer, and the power supply 23 is configured to provide an operating voltage for each hardware device on the electronic device 20; the communication interface 26 can create a data transmission channel between the electronic device 20 and an external device, and the communication protocol to be followed is any communication protocol applicable to the technical solution of the present application, which is not limited herein in detail; the input/output interface 25 is used for acquiring external input data or outputting external output data, and the specific interface type thereof may be selected according to the specific application requirement, which is not limited herein.
The memory 22 may be a carrier for storing resources, such as a read-only memory, a random access memory, a magnetic disk, or an optical disk, and the resources stored thereon may include an operating system 221, a computer program 222, virtual machine data 223, and the virtual machine data 223 may include various data. The storage means may be a temporary storage or a permanent storage.
The operating system 221 is used for managing and controlling various hardware devices on the electronic device 20 and computer programs 222, which may be Windows Server, netware, unix, linux, etc. The computer program 222 may further include a computer program that can be used to perform other specific tasks in addition to the computer program that can be used to perform the method of monitoring data acquisition performed by the electronic device 20 as disclosed in any of the previous embodiments.
Further, the present application also discloses a computer readable storage medium, where the computer readable storage medium includes a random access Memory (Random Access Memory, RAM), a Memory, a Read-Only Memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a magnetic disk, or any other form of storage medium known in the art. Wherein the computer program when executed by the processor implements the following method of monitoring data acquisition:
when target equipment information sent by a preset cloud data acquisition and storage device is received through a preset first port, determining a target edge proxy device in target edge equipment which is uniquely corresponding to the target equipment information, and sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link which is established with the target edge proxy device in advance;
and receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port.
For specific steps of the method, reference may be made to the corresponding contents disclosed in the foregoing embodiments, and no further description is given here.
In this specification, each embodiment is described in a progressive manner, and each embodiment is mainly described in a different point from other embodiments, so that the same or similar parts between the embodiments are referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant points refer to the description of the method section. Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative elements and steps are described above generally in terms of functionality in order to clearly illustrate the interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. The software modules may be disposed in Random Access Memory (RAM), memory, read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
Finally, it is further noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, 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 one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The method, the device, the equipment and the storage medium for collecting the monitoring data provided by the invention are described in detail, and specific examples are applied to the description of the principle and the implementation mode of the invention, and the description of the examples is only used for helping to understand the method and the core idea of the invention; meanwhile, as those skilled in the art will have variations in the specific embodiments and application scope in accordance with the ideas of the present invention, the present description should not be construed as limiting the present invention in view of the above.
Claims (10)
1. The monitoring data acquisition method is characterized by being applied to a cloud communication device pre-configured at a cloud node and comprising the following steps:
when target equipment information sent by a preset cloud data acquisition and storage device is received through a preset first port, determining a target edge proxy device in target edge equipment which is uniquely corresponding to the target equipment information, and sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link which is established with the target edge proxy device in advance;
and receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port.
2. The method for monitoring data collection according to claim 1, wherein, when the target device information sent by the preset cloud data collection and storage device is received through the preset first port, before determining the target edge proxy device in the target edge device uniquely corresponding to the target device information, the method further comprises:
receiving a first long connection request which is sent by a target edge proxy device and contains equipment information of target edge equipment, and establishing a long connection link between the target edge proxy devices which uniquely corresponds to the target edge equipment;
or, receiving a second long connection request which is sent by the target edge proxy device when the target edge proxy device detects that the original long link with the cloud communication device is disconnected, is used for reconnecting with the cloud communication device and comprises equipment information of target edge equipment, and establishing a long connection link between the target edge proxy devices which uniquely correspond to the target edge equipment.
3. The method for monitoring data collection according to claim 2, wherein after receiving the long connection request including the device information of the target edge device sent by the target edge proxy device, the method further comprises:
Registering a unique identifier for the target edge device based on the device information of the target edge device, and updating the unique identifier of the target edge device into a preset registration device list.
4. The method for collecting monitoring data according to claim 3, wherein when receiving the target device information sent by the preset cloud data collecting and storing device through the preset first port, determining a target edge proxy device in the target edge device uniquely corresponding to the target device information includes:
when a preset cloud data acquisition and storage device is received through a preset first port, accessing the preset registration equipment list through the preset first port, determining and sending a unique identifier of target edge equipment from the preset registration equipment list, and determining a target edge proxy device in the target edge equipment based on the unique identifier of the target edge equipment.
5. The method of monitoring data collection according to claim 1, further comprising:
and configuring the Prometaus server as the preset cloud data acquisition and storage device.
6. The method for collecting monitoring data according to claim 1, wherein the receiving the monitoring data returned by the target edge proxy device and returning the monitoring data to the preset cloud data collecting and storing device through the preset first port includes:
And receiving the monitoring data returned by the target edge proxy device, and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port so that the preset cloud data acquisition and storage device can store the monitoring data to a preset storage position.
7. The method according to any one of claims 1 to 6, wherein the sending a data request for acquiring monitoring data of the target edge device to the target edge proxy device based on a long connection link previously established with the target edge proxy device, receiving the monitoring data returned by the target edge proxy device, includes:
and sending a data request for acquiring the monitoring data of the target edge equipment to the target edge proxy device based on a long connection link established with the target edge proxy device in advance, so that the target edge proxy device forwards the data request to a target edge monitoring device uniquely corresponding to the target edge proxy device based on a preset second port on the target edge proxy device, and then receiving the monitoring data returned by the target edge monitoring device through the preset second port.
8. The utility model provides a control data collection system which characterized in that is applied to the high in the clouds communication device of configuration in advance in high in the clouds node, includes:
the data request module is used for determining a target edge proxy device in target edge equipment which is uniquely corresponding to target equipment information when target equipment information sent by a preset cloud data acquisition storage device is received through a preset first port, and sending a data request for acquiring monitoring data of the target edge equipment to the target edge proxy device based on a long connection link which is established with the target edge proxy device in advance;
the data receiving module is used for receiving the monitoring data returned by the target edge proxy device and returning the monitoring data to the preset cloud data acquisition and storage device through the preset first port.
9. An electronic device comprising a processor and a memory; wherein the processor, when executing the computer program stored in the memory, implements the method for monitoring data collection according to any one of claims 1 to 7.
10. A computer-readable storage medium storing a computer program; wherein the computer program, when executed by a processor, implements the method of monitoring data acquisition according to any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310778441.3A CN116800835A (en) | 2023-06-29 | 2023-06-29 | Monitoring data acquisition method, device, equipment and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310778441.3A CN116800835A (en) | 2023-06-29 | 2023-06-29 | Monitoring data acquisition method, device, equipment and medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN116800835A true CN116800835A (en) | 2023-09-22 |
Family
ID=88039933
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202310778441.3A Pending CN116800835A (en) | 2023-06-29 | 2023-06-29 | Monitoring data acquisition method, device, equipment and medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN116800835A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117938617A (en) * | 2024-03-19 | 2024-04-26 | 济南浪潮数据技术有限公司 | Device management method, device, computer device and storage medium |
-
2023
- 2023-06-29 CN CN202310778441.3A patent/CN116800835A/en active Pending
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117938617A (en) * | 2024-03-19 | 2024-04-26 | 济南浪潮数据技术有限公司 | Device management method, device, computer device and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US20130031236A1 (en) | Method and System for Platform Level Data Model for Indications Based Event Control and Data Transfer | |
US20210092073A1 (en) | Resource trees by management controller | |
CN114328618B (en) | Cache data synchronization method, device, equipment and storage medium | |
CN111258627A (en) | Interface document generation method and device | |
CN111064626B (en) | Configuration updating method, device, server and readable storage medium | |
CN110493028A (en) | A kind of clustered deploy(ment) method, system, device and computer readable storage medium | |
CN113742031A (en) | Node state information acquisition method and device, electronic equipment and readable storage medium | |
CN113709810B (en) | Method, equipment and medium for configuring network service quality | |
CN106357442A (en) | Server cluster monitoring method and system | |
CN116800835A (en) | Monitoring data acquisition method, device, equipment and medium | |
CN210804735U (en) | Intelligent electric meter | |
CN112019650B (en) | IP address recommendation method, device and server | |
US9686149B2 (en) | Information processing system, relay device, and information processing method | |
CN113079098A (en) | Method, device, equipment and computer readable medium for updating route | |
CN113965571B (en) | Management method, device, equipment and medium of distributed embedded equipment | |
CN109274715A (en) | The platform resource management system of vehicle-mounted multi-channel communication systems | |
CN105959427B (en) | DNS server automatic expansion method | |
Cisco | Configuring IE2100 CNS Agents | |
JP5782393B2 (en) | Network resource distributed management method and program | |
CN114466011B (en) | Metadata service request method, device, equipment and medium | |
TWI778771B (en) | Monitoring method, monitoring system and monitoring device of virtual machine operation | |
CN112003731B (en) | Configuration method and device | |
CN115987748A (en) | Smart television control method and device, storage medium and electronic equipment | |
CN117097545A (en) | Method, device, equipment and storage medium for protecting real-time application cluster | |
CN117271006A (en) | Extension point configuration updating and calling method, device, equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |