WO2023216042A1 - Event management method and apparatus, device, storage medium, and program product - Google Patents

Event management method and apparatus, device, storage medium, and program product Download PDF

Info

Publication number
WO2023216042A1
WO2023216042A1 PCT/CN2022/091579 CN2022091579W WO2023216042A1 WO 2023216042 A1 WO2023216042 A1 WO 2023216042A1 CN 2022091579 W CN2022091579 W CN 2022091579W WO 2023216042 A1 WO2023216042 A1 WO 2023216042A1
Authority
WO
WIPO (PCT)
Prior art keywords
event
priority
target
events
request
Prior art date
Application number
PCT/CN2022/091579
Other languages
French (fr)
Chinese (zh)
Inventor
包永明
Original Assignee
Oppo广东移动通信有限公司
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 Oppo广东移动通信有限公司 filed Critical Oppo广东移动通信有限公司
Priority to PCT/CN2022/091579 priority Critical patent/WO2023216042A1/en
Publication of WO2023216042A1 publication Critical patent/WO2023216042A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types

Definitions

  • This application relates to the technical field of the Internet of Things, and in particular to an event management method, device, equipment, storage medium and program product.
  • IoT Internet of Things
  • an IoT device may need to obtain an event on another IoT device.
  • a client device needs to obtain an event related to a certain cluster on the client device in order to trigger a reminder. Wait for operations.
  • Embodiments of the present application provide an event management method, device, equipment, storage medium and program product.
  • the technical solutions are as follows:
  • inventions of the present application provide an event management method, which is executed by a first device.
  • the method includes:
  • the event acquisition request includes the first target event priority
  • inventions of the present application provide an event management method, which is executed by a second device.
  • the method includes:
  • the event acquisition request includes the first target event priority
  • At least one target event matching the priority of the first target event is sent to the first device.
  • inventions of the present application provide an event management method, which is executed by the first device.
  • the method includes:
  • the event priority setting request includes a second target event priority; the event priority setting request is used to instruct the second device to record the event related to the second target event. At least one target event whose priority matches.
  • embodiments of the present application provide an event management method, which is executed by a second device.
  • the method includes:
  • the event priority setting request includes the second target event priority
  • At least one target event matching the second target event priority is recorded.
  • an event management device which includes:
  • a sending module configured to send an event acquisition request to the second device; the event acquisition request includes the first target event priority;
  • a receiving module configured to receive at least one target event sent by the second device that matches the priority of the first target event.
  • an event management device which includes:
  • a receiving module configured to receive an event acquisition request sent by the first device; the event acquisition request includes the first target event priority;
  • a sending module configured to send at least one target event matching the priority of the first target event to the first device.
  • an event management device which includes:
  • a sending module configured to send an event priority setting request to the second device; the event priority setting request includes a second target event priority; the event priority setting request is used to instruct the second device to record the At least one target event whose priority matches the second target event.
  • an event management device which includes:
  • a receiving module configured to receive an event priority setting request sent by the first device; the event priority setting request includes the second target event priority;
  • a recording module configured to record at least one target event matching the second target event priority according to the event priority setting information.
  • embodiments of the present application provide a computer device, which includes a processor, a memory, and a transceiver.
  • the memory stores a computer program, and the computer program is configured to be executed by the processor, so as to Implement the above event management methods.
  • embodiments of the present application also provide a computer-readable storage medium, in which a computer program is stored, and the computer program is loaded and executed by a processor to implement the above event management method.
  • the present application also provides a chip, which is used to run in a computer device, so that the computer device executes the above event management method.
  • the present application provides a computer program product including computer instructions stored in a computer-readable storage medium.
  • the processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the above event management method.
  • the present application provides a computer program, which is executed by a processor of a computer device to implement the above event management method.
  • the first device When the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request.
  • the second device can send the event with matching priority to the first device, thereby achieving event processing.
  • the acquired events are filtered by priority, which improves the flexibility of event acquisition in the Internet of Things system.
  • Figure 1 is a schematic diagram of the network architecture of the Internet of Things provided by an embodiment of the present application.
  • FIG 2 is a schematic diagram of the Matter device data model involved in the embodiment shown in Figure 1;
  • Figure 3 is a flow chart of an event management method provided by an embodiment of the present application.
  • Figure 4 is a flow chart of an event management method provided by an embodiment of the present application.
  • Figure 5 is a framework diagram of event management provided by an exemplary embodiment of the present application.
  • Figure 6 is a flow chart of an event management method provided by an embodiment of the present application.
  • Figure 7 is a flow chart of event acquisition involved in the embodiment shown in Figure 6;
  • Figure 8 is a flow chart of an event management method provided by an embodiment of the present application.
  • Figure 9 is a flow chart of an event management method provided by an embodiment of the present application.
  • Figure 10 is a framework diagram of event management provided by an exemplary embodiment of the present application.
  • Figure 11 is a flow chart of an event management method provided by an embodiment of the present application.
  • Figure 12 is a flow chart of event recording settings related to the embodiment shown in Figure 11;
  • Figure 13 is a block diagram of an event management device provided by an embodiment of the present application.
  • Figure 14 is a block diagram of an event management device provided by an embodiment of the present application.
  • Figure 15 is a block diagram of an event management device provided by an embodiment of the present application.
  • Figure 16 is a block diagram of an event management device provided by an embodiment of the present application.
  • Figure 17 is a schematic structural diagram of a computer device provided by an embodiment of the present application.
  • the network architecture of the Internet of Things may include: Internet of Things devices 110 and Internet of Things devices 120;
  • the Internet of Things device 110 and the Internet of Things device 120 may be devices used to provide server functions and/or client functions corresponding to the Internet of Things protocol in the Internet of Things.
  • the IoT device 110 or the IoT device 120 may be a smart home device, such as smart lamps, smart TVs, smart air conditioners, smart refrigerators, smart microwave ovens, smart rice cookers, sweeping robots, smart speakers, smart switches, and so on.
  • a smart home device such as smart lamps, smart TVs, smart air conditioners, smart refrigerators, smart microwave ovens, smart rice cookers, sweeping robots, smart speakers, smart switches, and so on.
  • the Internet of Things device 110 or the Internet of Things device 120 may be an industrial production equipment, such as a lathe, an industrial robot, a solar panel, a wind turbine, or the like.
  • the Internet of Things device 110 or the Internet of Things device 120 may be a commercial service device, such as an unmanned vending machine or the like.
  • the Internet of Things device 110 or the Internet of Things device 120 may be an intelligent monitoring device, such as a surveillance camera, an infrared sensor, a sound sensor, a temperature sensor, etc.
  • the Internet of Things device 110 or the Internet of Things device 120 may also be a user-side terminal device.
  • the IoT device 110 or the IoT device 120 can be a smart controller, a smart remote control, a smart phone, a tablet, a smart watch, a smart TV, a gateway, etc.; or, the IoT device 110 or the IoT device 120 can also be Is a personal computer, such as a desktop computer, laptop computer, personal workstation, etc.
  • the above-mentioned IoT device 110 and IoT device 120 may be electronic devices that meet the same or different IoT protocols.
  • they may be electronic devices that meet the Connectivity Standards Alliance (CSA) (or Zigbee).
  • CSA Connectivity Standards Alliance
  • Matter protocol or Connected Home over IP Working Group (CHIP) project via IP (Internet Protocol, Internet Protocol) under the Alliance).
  • CHIP Connected Home over IP Working Group
  • Matter is an IP-based IoT connection standard that solves the compatibility, security and connectivity issues existing in the current smart home market. Please refer to Figure 2, which shows a schematic diagram of the Matter device data model involved in the embodiment of the present application.
  • the Matter device data model has the following characteristics:
  • the Matter device node contains one or more Endpoints, represented by Endpoint Number;
  • Clusters Clusters
  • Cluster ID Cluster identification
  • the same Cluster is divided into two roles: Server (server) and Client (client). Data or commands are sent to the Server by the Client. ;
  • Each Cluster contains multiple Attributes, Events, and Commands, which are represented by Attribute ID, Event ID, and Command ID respectively. Attribute is used to represent data, Event is used to represent events, and Command is used to represent operations.
  • Event represents a record of something that happened in the past and can be thought of as a log entry.
  • the event stream provides a time-series view of the state evolution on the device node.
  • DEBUG debugging
  • INFO (information) drives the user's understanding of the device, such as software update events, key events, etc.;
  • CRITICAL (important) events that affect the user's physical security such as switch equipment events and security alarm events.
  • Event is defined in Cluster and represented by Event ID.
  • Event records can be shown in Table 1 below:
  • the Read Request message is shown in Table 2 below, where Table 2 lists the data related to the Event operation.
  • EventRequests list[EventPathIB] List O event request 0x02
  • EventFilters list[EventFilterIB] List O event filtering
  • the Subscribe Request message is shown in Table 3 below.
  • Table 3 lists the data related to the Event operation.
  • EventPathIB The composition of the event path information block is shown in Table 4 below.
  • Event id Uint16 2bytes O
  • Event ID value 0x04 IsUrgent Boolean O Whether it is an emergency event
  • IsUrgent mainly performs emergency reporting for the Event ID event specified in EventPathIB.
  • the device receives an event reading or subscription request with an Event ID with the word “IsUrgent” from the control end, it will urgently report the corresponding Event ID event.
  • EventFilterIB Event filtering information is shown in Table 5 below:
  • Cluster's global attribute information there will be Global Elements (Cluster's global attribute information) in the Cluster.
  • the global attribute information is shown in Table 6 below:
  • the above solution does not consider the user's filtering operations for events of different priorities, nor does it consider whether the user can set the priority of device events so that the device only stores certain events in its event queue according to the user's intention. priority events and then report them. This results in less flexibility in incident reporting.
  • Figure 3 shows a flow chart of an event management method provided by an embodiment of the present application.
  • the method can be executed by a first device.
  • the first device can be an object in the network architecture shown in Figure 1.
  • One of the networking device 110 or the Internet of Things device 120; the method may include the following steps:
  • Step 301 Send an event acquisition request to the second device; the event acquisition request includes the first target event priority.
  • first target event priority may be used to indicate the priority of the event that the first device needs to obtain.
  • the above-mentioned second device may be the Internet of Things device 110 of the system shown in Figure 1 or another Internet of Things device 120 among the Internet of Things devices except the first device.
  • Step 302 Receive at least one target event sent by the second device that matches the priority of the first target event.
  • the second device after receiving the above-mentioned event acquisition request, can send an event matching the priority to the first device (i.e., the above-mentioned target event) according to the priority of the first target event in the event acquisition request. .
  • the first device when the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request.
  • the second device can prioritize Events matching the level are sent to the first device, thereby filtering the acquired events by priority during the event acquisition process, and improving the flexibility of event acquisition in the Internet of Things system.
  • Figure 4 shows a flow chart of an event management method provided by an embodiment of the present application.
  • the method can be executed by a second device.
  • the second device can be an object in the network architecture shown in Figure 1.
  • One of the networking device 110 or the Internet of Things device 120; the method may include the following steps:
  • Step 401 Receive an event acquisition request sent by the first device; the event acquisition request includes the first target event priority.
  • the first device may be the IoT device 110 of the system shown in FIG. 1 or another IoT device among the IoT devices 120 except the second device.
  • Step 402 Send at least one target event matching the priority of the first target event to the first device.
  • the first device when the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request.
  • the second device can prioritize Events matching the level are sent to the first device, thereby filtering the acquired events by priority during the event acquisition process, and improving the flexibility of event acquisition in the Internet of Things system.
  • Figure 5 shows a framework diagram of event management provided by an exemplary embodiment of the present application.
  • the first device 51 when it needs to obtain certain cluster-related events in the second device 52 , it may send an event acquisition request indicating the priority of the event to the second device 52 .
  • the second device 52 After receiving the event acquisition request, the second device 52 queries the relevant cluster for events with matching priorities according to the priority indicated by the event acquisition request, and sends the queried events to the first device 51 .
  • the priority of the first target event may be set by the user corresponding to the first device.
  • Figure 6 shows a flow chart of an event management method provided by an embodiment of the present application.
  • This method can be interactively executed by a first device and a second device; for example, the above-mentioned first device and second device can be as shown in Figure 6.
  • the method may include the following steps.
  • Step 601 The first device receives a priority setting instruction.
  • the first device Before sending the event acquisition request, the first device may first display a priority setting interface, and the user sets the priority of the event to be obtained in the priority setting interface.
  • the user when the user sets the priority of the events to be obtained through the priority setting interface, the user can set the above priority corresponding to the specified target. For example, the user can select the set priority to take effect in the priority setting interface.
  • cluster ID 1 corresponds to cluster a
  • endpoint ID 2 corresponds to endpoint b
  • node ID 3 corresponds to node c
  • the above priority setting interface can also be an interface corresponding to the target cluster in the target endpoint on the target node. After the user sets the priority in the priority setting interface, the set priority is the one corresponding to the target cluster on the target node. The priority of the target cluster in the target endpoint.
  • users can set global priorities, which means that the priorities they set are not limited to specific clusters, endpoints, or nodes.
  • Step 602 The first device sets the first target event priority according to the priority setting instruction.
  • the first device may set the above-mentioned first target event priority in the event acquisition request when generating the event acquisition request according to the priority setting instruction.
  • the first device can also set the first target event priority according to the priority setting instruction and store it in a designated location before generating the event acquisition request.
  • the pre-stored first target event priority is added to the event acquisition request.
  • Step 603 The first device sends an event acquisition request to the second device, and the second device receives the event acquisition request; the event acquisition request includes the first target event priority.
  • the first device when the first device needs to obtain an event in the second device, it can send an event acquisition request to the second device.
  • the above event acquisition request may also include relevant information indicating the event to be acquired.
  • relevant information indicating the event to be acquired may include the node identification information of the second device, the endpoint identification information for the target endpoint, cluster identification information for the target cluster in the second node, and so on.
  • the above event acquisition request includes an event subscription request or an event reading request.
  • the event acquisition request sent by the first device to the second device may be a Read Request for reading events.
  • the event acquisition request sent by the first device to the second device may be a Subscribe Request for subscribing to events.
  • the above-mentioned first target event priority may be set in the event filtering information block of the event acquisition request.
  • a connection can be established between the first device and the second device based on the Matter protocol
  • the priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
  • the events recorded by the second device correspond to events recorded by the target cluster in the second device.
  • the above-mentioned first target event priority can be set in the EventFilterIB (Information Blocks, information block) of Read Request or Subscribe Request.
  • EventFilterIB Information Blocks, information block
  • the permission filtering identifier can be added to EventFilterIB, as shown in the following Table 7:
  • EventFilterIB the 1-byte Priority attribute is used to indicate the priority that the currently requested/subscribed event must satisfy.
  • Step 604 The second device sends at least one target event that matches the priority of the first target event to the first device; the first device receives the at least one target event.
  • the second device after receiving the event acquisition request sent by the first device, determines the cluster to which the event that the first device wants to acquire belongs to based on the endpoint identification information and cluster identification information in the event acquisition request, and then Query events corresponding to the cluster that match the priority of the first target event, filter out events that do not match the priority of the first target event, and send the queried events (i.e., at least one of the above target events) to the first equipment.
  • At least one target event includes an event with a priority higher than or equal to the priority of the first target event.
  • the first target event priority carried in the event acquisition request can indicate a single priority.
  • the second device returns an event to the first device, it will return events in the corresponding cluster that are not lower than this priority to the first device.
  • the priority of events is divided into three categories: DEBUG, INFO, and CRITICAL.
  • the priority order from high to low is CRITICAL>INFO>DEBUG.
  • the second device returns event messages with three priorities: DEBUG, INFO, and CRITICAL; if the first device sets the Priority in EventFilterIB when it sends a Read&Subscribe request. is INFO, the second device returns event messages with two priorities, INFO and CRITICAL; if the first device sets the Priority in EventFilterIB to CRITICAL when issuing a Read&Subscribe request, the second device returns event messages with one priority, CRITICAL.
  • At least one target event includes an event with a priority equal to the priority of the first target event.
  • the first target event priority carried in the event acquisition request can indicate a single or multiple priorities.
  • the single or multiple priorities in the corresponding cluster will be Events of any priority in the level are returned to the first device.
  • the second device returns an event message with DEBUG priority; if the first device sets the Priority in EventFilterIB to INFO when sending a Read&Subscribe request, the second device returns an event message with DEBUG priority. The second device returns an event message with INFO priority; if the first device sets the Priority in EventFilterIB to CRITICAL when issuing a Read&Subscribe request, the second device returns an event message with CRITICAL priority.
  • FIG. 7 shows a flow chart of event acquisition related to an embodiment of the present application.
  • the process may include the following steps:
  • the user sets the Priority field of EventFileterIB in the Read Request or Subscribe Request message in the control terminal to filter the priority events that the user cares about.
  • control terminal can be a user terminal such as a smartphone.
  • the user views the device-side information in the smartphone's APP (Application), and clicks the event priority setting option on the device-side to read or subscribe to the device-side information. The priority of the event.
  • APP Application
  • S72 The user sends a request to the control terminal to read or subscribe to one or more events in the cluster on the device terminal.
  • the user can click the event reading/subscription option on the device side in the APP to issue a request to read or subscribe to one or more events in one or more clusters on the device side.
  • the control end sends an event read/subscribe request to the device end, and the event read/subscribe request carries information indicating priority.
  • the Priority in the EventFilterIB of the event read/subscription request is set to the value corresponding to the priority set by the user.
  • S74 The device side returns events matching the priority indicated by the event reading/subscription request to the control side.
  • the device after the device receives the event reading/subscription request sent by the control, it can filter out the events that meet the priority set by the user in the corresponding cluster, and return the filtered events to the control. end.
  • S75 The control terminal displays the event returned by the device terminal to the user.
  • the first device when the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request.
  • the second device can prioritize Events matching the level are sent to the first device, where the above-mentioned priority can be set by the user, thereby achieving filtering of the acquired events through the user-specified priority during the event acquisition process, improving the efficiency of the Internet of Things system. Flexibility in event acquisition.
  • Figure 8 shows a flow chart of an event management method provided by an embodiment of the present application.
  • the method can be executed by a first device.
  • the first device can be an object in the network architecture shown in Figure 1.
  • One of the networking device 110 or the Internet of Things device 120; the method may include the following steps:
  • Step 801 Send an event priority setting request to the second device; the event priority setting request contains the second target event priority; the event priority setting request is used to instruct the second device to record at least one event that matches the second target event priority. A target event.
  • the first device can instruct the second device to record events that meet the specified priority when recording events. Subsequently, when the first device reads events from the second device, it reads The retrieved events are those that meet the above-specified priority. This enables filtering of generated events by priority during the event recording process, improving the flexibility of event recording and acquisition in the Internet of Things system.
  • Figure 9 shows a flow chart of an event management method provided by an embodiment of the present application.
  • the method can be executed by a second device.
  • the second device can be an object in the network architecture shown in Figure 1.
  • One of the networking device 110 or the Internet of Things device 120; the method may include the following steps:
  • Step 901 Receive an event priority setting request sent by the first device; the event priority setting request includes the second target event priority.
  • Step 902 Record at least one target event that matches the second target event priority according to the event priority setting information.
  • the first device can instruct the second device to record events that meet the specified priority when recording events. Subsequently, when the first device reads events from the second device, it reads The retrieved events are those that meet the above-specified priority. This enables filtering of generated events by priority during the event recording process, improving the flexibility of event recording and acquisition in the Internet of Things system.
  • FIG. 10 shows a framework diagram of event management provided by an exemplary embodiment of the present application.
  • the first device 1001 may send a setting request indicating the priority of events in a certain cluster to the second device 1002 .
  • the second device 1002 receives the setting request, when subsequently generating an event related to the cluster, if the generated event meets the above priority, the event will be recorded; otherwise, the event will be discarded.
  • the acquired events are all events that satisfy the above priority.
  • the second target event priority may be set by the user corresponding to the first device.
  • Figure 11 shows a flow chart of an event management method provided by an embodiment of the present application.
  • This method can be interactively executed by a first device and a second device; for example, the above-mentioned first device and second device can be as shown in Figure 11.
  • the method may include the following steps.
  • Step 1101 The first device receives a priority setting instruction.
  • Step 1102 The first device sets the second target event priority according to the priority setting instruction.
  • the first device may set the above-mentioned second target event priority in the event priority setting request when generating the event priority setting request according to the priority setting instruction.
  • the first device can also set the second target event priority according to the priority setting instruction and store it in a designated location before generating the event priority setting request.
  • the first device can also set the second target event priority according to the priority setting instruction and store it in a designated location before generating the event priority setting request.
  • Step 1103 The first device sends an event priority setting request to the second device, and the second device receives the event priority setting request; the event priority setting request includes the second target event priority.
  • the first device when the user needs to control the second device to record events that meet specific priority requirements in a certain cluster, the first device can be triggered to send an event priority setting request to the second device.
  • the request carries the value previously set by the user.
  • the priority of the second target event corresponding to the priority.
  • the above-mentioned event priority setting request may also include relevant information used to indicate the event to be set for priority filtering.
  • relevant information used to indicate the event to be set for priority filtering.
  • it may include the node identifier of the second device. information, endpoint identification information for the target endpoint in the second node, cluster identification information for the target cluster in the second node, and so on.
  • Step 1104 The second device records at least one target event that matches the priority of the second target event according to the event priority setting information.
  • the second device after it receives the event priority setting request, when it subsequently generates an event in the corresponding cluster, it can compare the priority of the newly generated event with the priority corresponding to the event priority setting information. If the priority of the newly generated event matches the priority corresponding to the event priority setting information, the event will be recorded; otherwise, the event will not be recorded.
  • the second device when the second device receives an event priority setting request, if there are existing events in the cluster corresponding to the event priority setting request, the second device can also filter the above existing events. For example, when the event priority setting request When the priority of an existing event matches the priority corresponding to the event priority setting information, the existing event is retained; otherwise, the existing event is deleted.
  • the above-mentioned second target event priority includes a write attribute instruction; the write attribute instruction is used to instruct the second device to write the event priority attribute corresponding to the second target event priority in the target cluster.
  • the second device may write the event priority attribute corresponding to the second target event priority in the target cluster;
  • the process of the second device recording at least one target event that matches the priority of the second target event according to the event priority setting information may include:
  • the target cluster When the target cluster generates the first event and the first event matches the event priority attribute, the first event is recorded as a target event of the target cluster.
  • a connection can be established between the first device and the second device based on the Matter protocol
  • the priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
  • the events recorded by the second device correspond to events recorded by the target cluster in the second device.
  • a writable attribute (event priority attribute) can be added to the global attributes (Global Elements) in the cluster of Internet of Things devices to indicate the priority of events recorded in the cluster.
  • the writable attribute can be shown in Table 8 below:
  • At least one target event includes an event with a priority higher than or equal to the priority of the second target event.
  • the user can set the priority of the event recorded by the second device through the event priority attribute: for example, the attribute priority is divided into three categories: DEBUG, INFO, CRITICAL, CRITICAL>INFO>DEBUG, then
  • the setting scheme can be as follows:
  • the second device will generate (ie generate and record) events with three priorities: DEBUG, INFO, and CRITICAL; if the first device sets the corresponding Cluster in the second device to If the Cluster's EventPriority is set to INFO, the second device will generate event messages with two priorities, INFO and CRITICAL (DEBUG priority messages can be generated and not recorded, or not generated); if the first device sets the second device to the Cluster The EventPriority is set to CRITICAL, and the device will generate event messages with CRITICAL priority (DEBUG and INFO priority messages can be generated and not recorded, or not generated).
  • At least one target event includes an event with a priority equal to the priority of the second target event.
  • the setting plan can be as follows:
  • the second device will generate event messages with DEBUG priority (the other two priority event messages can be generated and not recorded, or not generated); if the second device If one device sets the EventPriority of the second device corresponding to the Cluster to INFO, the second device will generate event messages with INFO priority; if the first device sets the EventPriority of the second device corresponding to the Cluster to CRITICAL, the second device will have CRITICAL priority. Level event messages are generated.
  • Figure 12 shows a flow chart of an event recording setting related to an embodiment of the present application.
  • the process may include the following steps:
  • the user sets the EventPriority attribute of a certain cluster in the control terminal.
  • control terminal can be a user terminal such as a smartphone.
  • the user views device-side information in the smartphone APP and clicks the event priority setting option on the device to set the priority of events generated by the device.
  • the user triggers the control terminal to issue a write attribute instruction.
  • the user can click the event priority setting option on the device side in the APP to issue an instruction to write the event priority attribute in a cluster on the device side.
  • the control end sends a write attribute instruction to the device end.
  • the write attribute instruction may carry the above-mentioned event priority attribute, or carry priority indication information corresponding to the above-mentioned event priority attribute.
  • S1204 The device records the event message of the corresponding priority according to the EventPriority attribute set by the user.
  • the device side After the device side receives the above write attribute instruction, it can write the event priority attribute into the global attribute of the corresponding cluster.
  • the device When subsequent events related to the cluster occur on the device, if the priority of the event meets the priority requirements corresponding to the above event priority attributes, the device will record the event, otherwise the event will not be recorded.
  • control end later obtains events related to the cluster recorded by the device end, it can be guaranteed that the events obtained are events that meet the priority set by the user.
  • the first device can instruct the second device to record events that meet the priority specified by the user when recording events. Subsequently, when the first device reads events from the second device, The events read are those that meet the above specified priorities, thus enabling filtering of generated events through the priorities set by the user during the event recording process, improving event recording and acquisition in the Internet of Things system flexibility.
  • the user can make the device record the priority events that the user cares about according to his own intention.
  • the above two solutions can be used independently, or the above two solutions can also be used in combination.
  • the user first uses the solutions shown in Figures 8 to 12 of the present application to cause the device to record priority events that the user is concerned about, such as, Through the above-mentioned scheme shown in Figure 8 to Figure 12, the device records two priority events, CRITICAL and INFO; when subsequent users obtain the event message, they can read it from the device through the above-mentioned scheme shown in Figure 3 to Figure 7. Events with specified priority, for example, reading CRITICAL or INFO priority events from the device.
  • FIG. 13 shows a block diagram of an event management device provided by an embodiment of the present application.
  • the event management device 1300 has the function of being executed by the first device in implementing the method shown in FIG. 3 or FIG. 6 .
  • the event management device 1300 may include:
  • Sending module 1301, configured to send an event acquisition request to the second device; the event acquisition request includes the first target event priority;
  • the receiving module 1302 is configured to receive at least one target event sent by the second device that matches the priority of the first target event.
  • the first target event priority is set in the event filtering information block of the event acquisition request.
  • At least one of the target events includes an event with a priority higher than or equal to the priority of the first target event
  • At least one of the target events includes an event with a priority equal to the priority of the first target event.
  • the device further includes:
  • An instruction receiving module configured to receive a priority setting instruction before the sending module 1301 sends an event acquisition request to the second device
  • a setting module configured to set the first target event priority according to the priority setting instruction.
  • the event acquisition request includes an event subscription request or an event reading request.
  • a connection can be established between the first device and the second device based on the Matter protocol
  • the priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
  • the events recorded by the second device correspond to events recorded by the target cluster in the second device.
  • the first device when the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request.
  • the second device can prioritize Events matching the level are sent to the first device, thereby filtering the acquired events by priority during the event acquisition process, and improving the flexibility of event acquisition in the Internet of Things system.
  • FIG. 14 shows a block diagram of an event management device provided by an embodiment of the present application.
  • the event management device 1400 has the function of being executed by the second device in implementing the method shown in FIG. 4 or FIG. 6 .
  • the event management device 1400 may include:
  • the receiving module 1401 is configured to receive an event acquisition request sent by the first device; the event acquisition request includes the first target event priority;
  • the sending module 1402 is configured to send at least one target event matching the priority of the first target event to the first device.
  • the first target event priority is set in the event filtering information block of the event acquisition request.
  • At least one of the target events includes an event with a priority higher than or equal to the priority of the first target event
  • At least one of the target events includes an event with a priority equal to the priority of the first target event.
  • the event acquisition request includes an event subscription request or an event reading request.
  • a connection can be established between the first device and the second device based on the Matter protocol
  • the priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
  • the events recorded by the second device correspond to events recorded by the target cluster in the second device.
  • the first device when the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request.
  • the second device can prioritize Events matching the level are sent to the first device, thereby filtering the acquired events by priority during the event acquisition process, and improving the flexibility of event acquisition in the Internet of Things system.
  • FIG. 15 shows a block diagram of an event management device provided by an embodiment of the present application.
  • the event management device 1500 has the function of being executed by the first device in implementing the method shown in FIG. 8 or FIG. 11 .
  • the event management device 1500 may include:
  • the sending module 1501 is used to send an event priority setting request to the second device; the event priority setting request includes the second target event priority; the event priority setting request is used to instruct the second device to record and At least one target event whose priority matches the second target event.
  • the second target event priority includes a write attribute instruction; the write attribute instruction is used to instruct the second device to write in the target cluster the same as the second target event priority.
  • the corresponding event priority attribute is used to instruct the second device to write in the target cluster the same as the second target event priority.
  • At least one of the target events includes an event with a priority higher than or equal to the priority of the second target event
  • At least one of the target events includes an event with a priority equal to the priority of the second target event.
  • the device further includes:
  • An instruction receiving module configured to receive a priority setting instruction before the sending module 1501 sends an event priority setting request to the second device;
  • a setting module configured to set the second target event priority according to the priority setting instruction.
  • a connection can be established between the first device and the second device based on the Matter protocol
  • the priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
  • the events recorded by the second device correspond to events recorded by the target cluster in the second device.
  • the first device can instruct the second device to record events that meet the specified priority when recording events. Subsequently, when the first device reads events from the second device, it reads The retrieved events are those that meet the above-specified priority. This enables filtering of generated events by priority during the event recording process, improving the flexibility of event recording and acquisition in the Internet of Things system.
  • FIG. 16 shows a block diagram of an event management device provided by an embodiment of the present application.
  • the event management device 1600 has the function of being executed by the second device in implementing the method shown in FIG. 9 or FIG. 11 .
  • the event management device 1600 may include:
  • the receiving module 1601 is configured to receive an event priority setting request sent by the first device; the event priority setting request includes the second target event priority;
  • the recording module 1602 is configured to record at least one target event that matches the second target event priority according to the event priority setting information.
  • the second target event priority includes a write attribute instruction
  • the device also includes:
  • An attribute writing module configured to write the content of the first target event in the target cluster before the recording module 1602 records at least one target event matching the priority of the second target event according to the event priority setting information.
  • the event priority attribute corresponding to the priority of the second target event;
  • the recording module 1602 is configured to record the first event as an item of the target cluster when the target cluster generates a first event and the first event matches the event priority attribute. target event.
  • At least one of the target events includes an event with a priority higher than or equal to the priority of the second target event
  • At least one of the target events includes an event with a priority equal to the priority of the second target event.
  • a connection can be established between the first device and the second device based on the Matter protocol
  • the priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
  • the events recorded by the second device correspond to events recorded by the target cluster in the second device.
  • the first device can instruct the second device to record events that meet the specified priority when recording events. Subsequently, when the first device reads events from the second device, it reads The retrieved events are those that meet the above-specified priority. This enables filtering of generated events by priority during the event recording process, improving the flexibility of event recording and acquisition in the Internet of Things system.
  • FIG 17 shows a schematic structural diagram of a computer device 1700 provided by an embodiment of the present application.
  • the computer device 1700 may include a processor 1701, a receiver 1702, a transmitter 1703, a memory 1704, and a bus 1705.
  • the processor 1701 includes one or more processing cores.
  • the processor 1701 executes various functional applications and information processing by running software programs and modules.
  • the receiver 1702 and the transmitter 1703 can be implemented as a communication component, and the communication component can be a communication chip.
  • This communication chip can also be called a transceiver.
  • Memory 1704 is connected to processor 1701 through bus 1705.
  • the memory 1704 can be used to store a computer program, and the processor 1701 is used to execute the computer program to implement various steps in the above method embodiments.
  • memory 1704 may be implemented by any type of volatile or non-volatile storage device, or combination thereof, including but not limited to: magnetic or optical disks, electrically erasable programmable Read-only memory, erasable programmable read-only memory, static ready-access memory, read-only memory, magnetic memory, flash memory, programmable read-only memory.
  • the process performed by the processor and/or transceiver in the computer device 1700 may refer to the method shown in any one of the above-mentioned FIG. 3, FIG. 4, FIG. 6, FIG. 8, FIG. 9 or FIG. 11, by the first device. or individual steps performed by the second device.
  • Embodiments of the present application also provide a computer-readable storage medium.
  • a computer program is stored in the storage medium.
  • the computer program is loaded and executed by a processor to implement the above-mentioned Figures 3, 4, 6, and 8.
  • each step is performed by the first device or the second device.
  • This application also provides a chip, which is used to run in a computer device, so that the computer device executes the method shown in any one of the above-mentioned Figure 3, Figure 4, Figure 6, Figure 8, Figure 9 or Figure 11, Various steps performed by the first device or the second device.
  • the application also provides a computer program product, which computer program product or computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium.
  • the processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, causing the computer device to execute any one of the above figures 3, 4, 6, 8, 9 or 11.
  • each step is performed by the first device or the second device.
  • This application also provides a computer program, which is executed by the processor of the computer device to implement the method shown in any one of the above-mentioned Figure 3, Figure 4, Figure 6, Figure 8, Figure 9 or Figure 11, by Various steps performed by the first device or the second device.

Abstract

An event management method and apparatus, a device, a storage medium, and a program product, relating to the technical field of Internet of things. The method comprises: sending an event acquisition request to a second device (301), the event acquisition request comprising a first target event priority; and receiving at least one target event sent by the second device and matching the first target event priority (302). The solution can improve the flexibility of event acquisition in an Internet of things system.

Description

事件管理方法、装置、设备、存储介质及程序产品Event management methods, devices, equipment, storage media and program products 技术领域Technical field
本申请涉及物联网技术领域,特别涉及一种事件管理方法、装置、设备、存储介质及程序产品。This application relates to the technical field of the Internet of Things, and in particular to an event management method, device, equipment, storage medium and program product.
背景技术Background technique
随着物联网(Internet of Things,IoT)技术的不断发展,越来越多的物联网设备在智能家居、工业生产等诸多领域给用户的生产生活带来了极大的便利性。With the continuous development of Internet of Things (IoT) technology, more and more IoT devices have brought great convenience to users' production and life in many fields such as smart homes and industrial production.
在物联网系统中,一个物联网设备可能需要获取另一个物联网设备上的事件(Event),比如,客户端设备需要获取客户端设备上的某个群集(Cluster)相关的事件,以便触发提醒等操作。In an IoT system, an IoT device may need to obtain an event on another IoT device. For example, a client device needs to obtain an event related to a certain cluster on the client device in order to trigger a reminder. Wait for operations.
发明内容Contents of the invention
本申请实施例提供了一种事件管理方法、装置、设备、存储介质及程序产品。所述技术方案如下:Embodiments of the present application provide an event management method, device, equipment, storage medium and program product. The technical solutions are as follows:
一方面,本申请实施例提供了一种事件管理方法,所述方法由第一设备执行,所述方法包括:On the one hand, embodiments of the present application provide an event management method, which is executed by a first device. The method includes:
向第二设备发送事件获取请求;所述事件获取请求中包含第一目标事件优先级;Send an event acquisition request to the second device; the event acquisition request includes the first target event priority;
接收所述第二设备发送的,与所述第一目标事件优先级匹配的至少一个目标事件。Receive at least one target event sent by the second device that matches the priority of the first target event.
一方面,本申请实施例提供了一种事件管理方法,所述方法由第二设备执行,所述方法包括:On the one hand, embodiments of the present application provide an event management method, which is executed by a second device. The method includes:
接收第一设备发送的事件获取请求;所述事件获取请求中包含第一目标事件优先级;Receive an event acquisition request sent by the first device; the event acquisition request includes the first target event priority;
向所述第一设备发送与所述第一目标事件优先级匹配的至少一个目标事件。At least one target event matching the priority of the first target event is sent to the first device.
另一方面,本申请实施例提供了一种事件管理方法,所述方法由第一设备执行,所述方法包括:On the other hand, embodiments of the present application provide an event management method, which is executed by the first device. The method includes:
向第二设备发送事件优先级设置请求;所述事件优先级设置请求中包含第二目标事件优先级;所述事件优先级设置请求用于指示所述第二设备记录与所述第二目标事件优先级匹配的至少一个目标事件。Send an event priority setting request to the second device; the event priority setting request includes a second target event priority; the event priority setting request is used to instruct the second device to record the event related to the second target event. At least one target event whose priority matches.
另一方面,本申请实施例提供了一种事件管理方法,所述方法由第二设备执行,所述方法包括:On the other hand, embodiments of the present application provide an event management method, which is executed by a second device. The method includes:
接收第一设备发送的事件优先级设置请求;所述事件优先级设置请求中包含第二目标事件优先级;Receive an event priority setting request sent by the first device; the event priority setting request includes the second target event priority;
根据所述事件优先级设置信息,记录与所述第二目标事件优先级匹配的至少一个目标事件。According to the event priority setting information, at least one target event matching the second target event priority is recorded.
另一方面,本申请实施例提供了一种事件管理装置,所述装置包括:On the other hand, an embodiment of the present application provides an event management device, which includes:
发送模块,用于向第二设备发送事件获取请求;所述事件获取请求中包含第一目标事件优先级;A sending module, configured to send an event acquisition request to the second device; the event acquisition request includes the first target event priority;
接收模块,用于接收所述第二设备发送的,与所述第一目标事件优先级匹配的至少一个目标事件。A receiving module configured to receive at least one target event sent by the second device that matches the priority of the first target event.
另一方面,本申请实施例提供了一种事件管理装置,所述装置包括:On the other hand, an embodiment of the present application provides an event management device, which includes:
接收模块,用于接收第一设备发送的事件获取请求;所述事件获取请求中包含第一目标事件优先级;A receiving module, configured to receive an event acquisition request sent by the first device; the event acquisition request includes the first target event priority;
发送模块,用于向所述第一设备发送与所述第一目标事件优先级匹配的至少一个目标事件。A sending module configured to send at least one target event matching the priority of the first target event to the first device.
另一方面,本申请实施例提供了一种事件管理装置,所述装置包括:On the other hand, an embodiment of the present application provides an event management device, which includes:
发送模块,用于向第二设备发送事件优先级设置请求;所述事件优先级设置请求中包含第二目标事件优先级;所述事件优先级设置请求用于指示所述第二设备记录与所述第二目标事件优先级匹配的至少一个目标事件。A sending module, configured to send an event priority setting request to the second device; the event priority setting request includes a second target event priority; the event priority setting request is used to instruct the second device to record the At least one target event whose priority matches the second target event.
另一方面,本申请实施例提供了一种事件管理装置,所述装置包括:On the other hand, an embodiment of the present application provides an event management device, which includes:
接收模块,用于接收第一设备发送的事件优先级设置请求;所述事件优先级设置请求中包含第二目标事件优先级;A receiving module configured to receive an event priority setting request sent by the first device; the event priority setting request includes the second target event priority;
记录模块,用于根据所述事件优先级设置信息,记录与所述第二目标事件优先级匹配的至少一个目标事件。A recording module configured to record at least one target event matching the second target event priority according to the event priority setting information.
再一方面,本申请实施例提供了一种计算机设备,所述计算机设备包括处理器、存储器和收发器,所述存储器存储有计算机程序,所述计算机程序用于被所述处理器执行,以实现上述事件管理方法。In yet another aspect, embodiments of the present application provide a computer device, which includes a processor, a memory, and a transceiver. The memory stores a computer program, and the computer program is configured to be executed by the processor, so as to Implement the above event management methods.
又一方面,本申请实施例还提供了一种计算机可读存储介质,所述存储介质中存储有计算机程序,所述计算机程序由处理器加载并执行以实现上述事件管理方法。On another aspect, embodiments of the present application also provide a computer-readable storage medium, in which a computer program is stored, and the computer program is loaded and executed by a processor to implement the above event management method.
又一方面,本申请还提供了一种芯片,所述芯片用于在计算机设备中运行,以使得所述计算机设备执行上述事件管理方法。In another aspect, the present application also provides a chip, which is used to run in a computer device, so that the computer device executes the above event management method.
又一方面,本申请提供了一种计算机程序产品,该计算机程序产品包括计算机指令,该计算机指令存储在计算机可读存储介质中。计算机设备的处理器从计算机可读存储介质读取该计算机指令,处理器执行该计算机指令,使得该计算机设备执行上述事件管理方法。In yet another aspect, the present application provides a computer program product including computer instructions stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the above event management method.
又一方面,本申请提供了一种计算机程序,该计算机程序由计算机设备的处理器执行,以实现上述事件管理方法。In another aspect, the present application provides a computer program, which is executed by a processor of a computer device to implement the above event management method.
本申请实施例提供的技术方案可以带来如下有益效果:The technical solutions provided by the embodiments of this application can bring the following beneficial effects:
第一设备请求获取第二设备中的事件时,可以在请求中指示需要获取的事件的优先级,相应的,第二设备可以将优先级匹配的事件发送给第一设备,从而实现了在事件获取过程中,通过优先级对获取的事件进行过滤,提高了物联网系统中的事件获取的灵活性。When the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request. Correspondingly, the second device can send the event with matching priority to the first device, thereby achieving event processing. During the acquisition process, the acquired events are filtered by priority, which improves the flexibility of event acquisition in the Internet of Things system.
附图说明Description of the drawings
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can also be obtained based on these drawings without exerting creative efforts.
图1是本申请一个实施例提供的物联网的网络架构的示意图;Figure 1 is a schematic diagram of the network architecture of the Internet of Things provided by an embodiment of the present application;
图2是图1所示实施例涉及的Matter设备数据模型的示意图;Figure 2 is a schematic diagram of the Matter device data model involved in the embodiment shown in Figure 1;
图3是本申请一个实施例提供的事件管理方法的流程图;Figure 3 is a flow chart of an event management method provided by an embodiment of the present application;
图4是本申请一个实施例提供的事件管理方法的流程图;Figure 4 is a flow chart of an event management method provided by an embodiment of the present application;
图5是本申请一个示例性的实施例提供的事件管理的框架图;Figure 5 is a framework diagram of event management provided by an exemplary embodiment of the present application;
图6是本申请一个实施例提供的事件管理方法的流程图;Figure 6 is a flow chart of an event management method provided by an embodiment of the present application;
图7是图6所示实施例涉及的事件获取的流程图;Figure 7 is a flow chart of event acquisition involved in the embodiment shown in Figure 6;
图8是本申请一个实施例提供的事件管理方法的流程图;Figure 8 is a flow chart of an event management method provided by an embodiment of the present application;
图9是本申请一个实施例提供的事件管理方法的流程图;Figure 9 is a flow chart of an event management method provided by an embodiment of the present application;
图10是本申请一个示例性的实施例提供的事件管理的框架图;Figure 10 is a framework diagram of event management provided by an exemplary embodiment of the present application;
图11是本申请一个实施例提供的事件管理方法的流程图;Figure 11 is a flow chart of an event management method provided by an embodiment of the present application;
图12是图11所示实施例涉及的事件记录设置的流程图;Figure 12 is a flow chart of event recording settings related to the embodiment shown in Figure 11;
图13是本申请一个实施例提供的事件管理装置的框图;Figure 13 is a block diagram of an event management device provided by an embodiment of the present application;
图14是本申请一个实施例提供的事件管理装置的框图;Figure 14 is a block diagram of an event management device provided by an embodiment of the present application;
图15是本申请一个实施例提供的事件管理装置的框图;Figure 15 is a block diagram of an event management device provided by an embodiment of the present application;
图16是本申请一个实施例提供的事件管理装置的框图;Figure 16 is a block diagram of an event management device provided by an embodiment of the present application;
图17是本申请一个实施例提供的计算机设备的结构示意图。Figure 17 is a schematic structural diagram of a computer device provided by an embodiment of the present application.
具体实施方式Detailed ways
为使本申请的目的、技术方案和优点更加清楚,下面将结合附图对本申请实施方式作进一步地详细描述。In order to make the purpose, technical solutions and advantages of the present application clearer, the embodiments of the present application will be further described in detail below with reference to the accompanying drawings.
本申请实施例描述的网络架构以及业务场景是为了更加清楚地说明本申请实施例的技术方案,并不构成对本申请实施例提供的技术方案的限定,本领域普通技术人员可知,随着网络架构的演变和新业务场景的出现,本申请实施例提供的技术方案对于类似的技术问题,同样适用。The network architecture and business scenarios described in the embodiments of this application are to more clearly explain the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided by the embodiments of this application. Those of ordinary skill in the art will know that with the network architecture evolution and the emergence of new business scenarios, the technical solutions provided in the embodiments of this application are also applicable to similar technical problems.
请参考图1,其示出了本申请一个实施例提供的物联网的网络架构的示意图。该物联网的网络架构可以包括:物联网设备110以及物联网设备120;Please refer to Figure 1, which shows a schematic diagram of the network architecture of the Internet of Things provided by an embodiment of the present application. The network architecture of the Internet of Things may include: Internet of Things devices 110 and Internet of Things devices 120;
物联网设备110和物联网设备120可以是在物联网中,用于提供物联网协议对应的服务端功能和/或客户端功能的设备。The Internet of Things device 110 and the Internet of Things device 120 may be devices used to provide server functions and/or client functions corresponding to the Internet of Things protocol in the Internet of Things.
比如,物联网设备110或者物联网设备120可以是智能家居设备,例如,智能灯具、智能电视、智能空调、智能冰箱、智能微波炉、智能电饭煲、扫地机器人、智能音箱、智能开关等等。For example, the IoT device 110 or the IoT device 120 may be a smart home device, such as smart lamps, smart TVs, smart air conditioners, smart refrigerators, smart microwave ovens, smart rice cookers, sweeping robots, smart speakers, smart switches, and so on.
或者,物联网设备110或者物联网设备120可以是工业生产设备,例如,车床、工业机器人、太阳能面板、风力发电机等等。Alternatively, the Internet of Things device 110 or the Internet of Things device 120 may be an industrial production equipment, such as a lathe, an industrial robot, a solar panel, a wind turbine, or the like.
或者,物联网设备110或者物联网设备120可以是商业服务设备,例如,无人售货机等等。Alternatively, the Internet of Things device 110 or the Internet of Things device 120 may be a commercial service device, such as an unmanned vending machine or the like.
或者,物联网设备110或者物联网设备120可以是智能监控设备,例如,监控摄像头、红外传感器、声音传感器、温度传感器等等。Alternatively, the Internet of Things device 110 or the Internet of Things device 120 may be an intelligent monitoring device, such as a surveillance camera, an infrared sensor, a sound sensor, a temperature sensor, etc.
在一种可能的实现方式中,物联网设备110或者物联网设备120也可以是用户侧的终端设备。比如,物联网设备110或者物联网设备120可以是智能控制器、智能遥控器、智能手机、平板电脑、智能手表、智能电视、网关等等;或者,物联网设备110或者物联网设备120也可以是个人电脑,比如台式电脑、便携式计算机、个人工作站等等。In a possible implementation, the Internet of Things device 110 or the Internet of Things device 120 may also be a user-side terminal device. For example, the IoT device 110 or the IoT device 120 can be a smart controller, a smart remote control, a smart phone, a tablet, a smart watch, a smart TV, a gateway, etc.; or, the IoT device 110 or the IoT device 120 can also be Is a personal computer, such as a desktop computer, laptop computer, personal workstation, etc.
在本申请实施例中,上述物联网设备110和物联网设备120可以是满足相同或者不同的物联网协议的电子设备,比如,可以是满足连接标准联盟(Connectivity Standards Alliance,CSA)(或称Zigbee联盟)下的Matter协议(或称通过IP(Internet Protocol,网际互联协议)连接家庭工作组(Connected Home over IP Working Group,CHIP)项目)的电子设备。In the embodiment of the present application, the above-mentioned IoT device 110 and IoT device 120 may be electronic devices that meet the same or different IoT protocols. For example, they may be electronic devices that meet the Connectivity Standards Alliance (CSA) (or Zigbee). Electronic devices under the Matter protocol (or Connected Home over IP Working Group (CHIP) project via IP (Internet Protocol, Internet Protocol)) under the Alliance).
Matter是一种基于IP的物联网连接标准,解决当下智能家居市场存在的兼容性、安全性和连接性等问题。请参考图2,其示出了本申请实施例涉及的Matter设备数据模型的示意图。Matter is an IP-based IoT connection standard that solves the compatibility, security and connectivity issues existing in the current smart home market. Please refer to Figure 2, which shows a schematic diagram of the Matter device data model involved in the embodiment of the present application.
如图2所示,Matter设备数据模型具有以下特点:As shown in Figure 2, the Matter device data model has the following characteristics:
1)Matter设备节点包含一个或多个Endpoint(端点),使用Endpoint Number(端点号)表示;1) The Matter device node contains one or more Endpoints, represented by Endpoint Number;
2)每个Endpoint包含多种Cluster(群集),使用Cluster ID(群集标识)表示,相同Cluster又分为Server(服务端)和Client(客户端)两种角色,数据或命令由Client发送给Server;2) Each Endpoint contains multiple Clusters (clusters), represented by Cluster ID (cluster identification). The same Cluster is divided into two roles: Server (server) and Client (client). Data or commands are sent to the Server by the Client. ;
3)每个Cluster包含多个Attribute(属性)、Event和Command(命令),分别使用Attribute ID、Event ID、Command ID表示,Attribute用于表示数据、Event用于表示事件、Command用于表示操作。3) Each Cluster contains multiple Attributes, Events, and Commands, which are represented by Attribute ID, Event ID, and Command ID respectively. Attribute is used to represent data, Event is used to represent events, and Command is used to represent operations.
Matter Event介绍:Matter Event introduction:
Event代表过去发生的一些事情的记录,可以认为是日志条目,事件流提供设备节点上状态演化的时序视图。Event represents a record of something that happened in the past and can be thought of as a log entry. The event stream provides a time-series view of the state evolution on the device node.
Event有3个优先级:Events have 3 priorities:
DEBUG(调试)用于工程师调试使用;DEBUG (debugging) is used for debugging by engineers;
INFO(信息)驱动用户对设备的理解,如软件更新事件按键事件等;INFO (information) drives the user's understanding of the device, such as software update events, key events, etc.;
CRITICAL(重要)影响用户物理安全的事件,如开关设备事件,安全告警事件。CRITICAL (important) events that affect the user's physical security, such as switch equipment events and security alarm events.
Event定义在Cluster中,通过Event ID表示。Event is defined in Cluster and represented by Event ID.
Event的记录可以如下表1所示:Event records can be shown in Table 1 below:
表1Table 1
Figure PCTCN2022091579-appb-000001
Figure PCTCN2022091579-appb-000001
事件可以通过Read Request读取或者Subscribe Request请求订阅。Events can be read through Read Request or subscribed through Subscribe Request.
Read Request消息如下表2所示,其中,表2中列出和Event操作相关的数据。The Read Request message is shown in Table 2 below, where Table 2 lists the data related to the Event operation.
表2Table 2
IDID FieldField TypeType ConstraintConstraint ConformanceConformance DescriptionDescription
0x010x01 EventRequestsEventRequests list[EventPathIB]list[EventPathIB] ListList OO 事件请求event request
0x020x02 EventFiltersEventFilters list[EventFilterIB]list[EventFilterIB] ListList OO 事件过滤event filtering
Subscribe Request消息如下表3所示,表3中列出和Event操作相关的数据。The Subscribe Request message is shown in Table 3 below. Table 3 lists the data related to the Event operation.
表3table 3
Figure PCTCN2022091579-appb-000002
Figure PCTCN2022091579-appb-000002
EventPathIB:事件路径信息块组成如下表4所示。EventPathIB: The composition of the event path information block is shown in Table 4 below.
表4Table 4
IDID FieldField TypeType ConstraintConstraint ConformanceConformance DescriptionDescription
0x000x00 Node idNode id Uint16Uint16 2bytes2bytes OO Node idNode id
0x010x01 Endpoint noEndpoint no Uint16Uint16 2bytes2bytes OO Endpoint值Endpoint value
0x020x02 Cluster idCluster id Uint16Uint16 2bytes2bytes OO Cluster ID值Cluster ID value
0x030x03 Event idEvent id Uint16Uint16 2bytes2bytes OO Event ID值Event ID value
0x040x04 IsUrgentIsUrgent BooleanBoolean   OO 是否为紧急EventWhether it is an emergency event
“IsUrgent”主要针对EventPathIB中指定的Event ID事件进行紧急上报。设备端收到控制端带有“IsUrgent”字样的Event ID的事件读取或订阅请求时,对对应的Event ID事件进行紧急上报处理。"IsUrgent" mainly performs emergency reporting for the Event ID event specified in EventPathIB. When the device receives an event reading or subscription request with an Event ID with the word "IsUrgent" from the control end, it will urgently report the corresponding Event ID event.
EventFilterIB:事件过滤信息如下表5所示:EventFilterIB: Event filtering information is shown in Table 5 below:
表5table 5
Figure PCTCN2022091579-appb-000003
Figure PCTCN2022091579-appb-000003
在一种方案中,Cluster中会存在Global Elements(Cluster的全局属性信息),该全局属性信息如下述表6所示:In one solution, there will be Global Elements (Cluster's global attribute information) in the Cluster. The global attribute information is shown in Table 6 below:
表6Table 6
Attribute IDAttribute ID NameName TypeType
0xFFFA0xFFFA EventListEventList list[event-id]list[event-id]
在上述方案中表6中的属性为只读。In the above scenario, the properties in Table 6 are read-only.
在实际的用户操作中,上述方案没有考虑用户对不同优先级事件的过滤操作,也没有考虑用户能否可以设置设备事件的优先级,使设备按照用户的意图只在其事件队列中存放某个优先级的事件,然后进行上报。从而导致事件上报的灵活性较差。In actual user operations, the above solution does not consider the user's filtering operations for events of different priorities, nor does it consider whether the user can set the priority of device events so that the device only stores certain events in its event queue according to the user's intention. priority events and then report them. This results in less flexibility in incident reporting.
请参考图3,其示出了本申请一个实施例提供的事件管理方法的流程图,该方法可以由第一设备执行,比如,该第一设备可以是图1所示的网络架构中的物联网设备110或者物联网设备120中的一个;该方法可以包括如下步骤:Please refer to Figure 3, which shows a flow chart of an event management method provided by an embodiment of the present application. The method can be executed by a first device. For example, the first device can be an object in the network architecture shown in Figure 1. One of the networking device 110 or the Internet of Things device 120; the method may include the following steps:
步骤301,向第二设备发送事件获取请求;事件获取请求中包含第一目标事件优先级。Step 301: Send an event acquisition request to the second device; the event acquisition request includes the first target event priority.
其中,上述第一目标事件优先级可以用于指示第一设备需要获取的事件的优先级。Wherein, the above-mentioned first target event priority may be used to indicate the priority of the event that the first device needs to obtain.
其中,上述第二设备可以是图1所示系统的物联网设备110或者物联网设备120中,除了第一设备之外的另一个物联网设备。The above-mentioned second device may be the Internet of Things device 110 of the system shown in Figure 1 or another Internet of Things device 120 among the Internet of Things devices except the first device.
步骤302,接收第二设备发送的,与第一目标事件优先级匹配的至少一个目标事件。Step 302: Receive at least one target event sent by the second device that matches the priority of the first target event.
在本申请实施例中,第二设备接收到上述事件获取请求后,可以根据事件获取请求中的第一目标事件优先级,向第一设备发送与该优先级匹配的事件(即上述目标事件)。In this embodiment of the present application, after receiving the above-mentioned event acquisition request, the second device can send an event matching the priority to the first device (i.e., the above-mentioned target event) according to the priority of the first target event in the event acquisition request. .
综上所述,本申请实施例所示的方案中,第一设备请求获取第二设备中的事件时,可以在请求中指示需要获取的事件的优先级,相应的,第二设备可以将优先级匹配的事件发送给第一设备,从而实现了在事件获取过程中,通过优先级对获取的事件进行过滤,提高了物联网系统中的事件获取的灵活性。To sum up, in the solution shown in the embodiment of the present application, when the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request. Correspondingly, the second device can prioritize Events matching the level are sent to the first device, thereby filtering the acquired events by priority during the event acquisition process, and improving the flexibility of event acquisition in the Internet of Things system.
请参考图4,其示出了本申请一个实施例提供的事件管理方法的流程图,该方法可以由第二设备执行,比如,该第二设备可以是图1所示的网络架构中的物联网设备110或者物联网设备120中的一个;该方法可以包括如下步骤:Please refer to Figure 4, which shows a flow chart of an event management method provided by an embodiment of the present application. The method can be executed by a second device. For example, the second device can be an object in the network architecture shown in Figure 1. One of the networking device 110 or the Internet of Things device 120; the method may include the following steps:
步骤401,接收第一设备发送的事件获取请求;事件获取请求中包含第一目标事件优先级。Step 401: Receive an event acquisition request sent by the first device; the event acquisition request includes the first target event priority.
其中,第一设备可以是图1所示系统的物联网设备110或者物联网设备120中,除了第二设备之外的另一个物联网设备。The first device may be the IoT device 110 of the system shown in FIG. 1 or another IoT device among the IoT devices 120 except the second device.
步骤402,向第一设备发送与第一目标事件优先级匹配的至少一个目标事件。Step 402: Send at least one target event matching the priority of the first target event to the first device.
综上所述,本申请实施例所示的方案中,第一设备请求获取第二设备中的事件时,可以 在请求中指示需要获取的事件的优先级,相应的,第二设备可以将优先级匹配的事件发送给第一设备,从而实现了在事件获取过程中,通过优先级对获取的事件进行过滤,提高了物联网系统中的事件获取的灵活性。To sum up, in the solution shown in the embodiment of the present application, when the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request. Correspondingly, the second device can prioritize Events matching the level are sent to the first device, thereby filtering the acquired events by priority during the event acquisition process, and improving the flexibility of event acquisition in the Internet of Things system.
基于上述图3和图4所示的方案,请参考图5,其示出了本申请一个示例性的实施例提供的事件管理的框架图。如图5所示,第一设备51需要获取第二设备52中某些群集相关的事件时,可以向第二设备52发送指示事件的优先级的事件获取请求。Based on the solutions shown in Figures 3 and 4 above, please refer to Figure 5 , which shows a framework diagram of event management provided by an exemplary embodiment of the present application. As shown in FIG. 5 , when the first device 51 needs to obtain certain cluster-related events in the second device 52 , it may send an event acquisition request indicating the priority of the event to the second device 52 .
第二设备52接收到事件获取请求后,根据事件获取请求指示的优先级,在相关群集中查询优先级匹配的事件,并将查询到的事件发送给第一设备51。After receiving the event acquisition request, the second device 52 queries the relevant cluster for events with matching priorities according to the priority indicated by the event acquisition request, and sends the queried events to the first device 51 .
基于上述图3至图5所示的方案,在一种可能的情况下,上述第一目标事件优先级可以由第一设备对应的用户进行设置。Based on the solutions shown in FIGS. 3 to 5 , in one possible case, the priority of the first target event may be set by the user corresponding to the first device.
请参考图6,其示出了本申请一个实施例提供的事件管理方法的流程图,该方法可以由第一设备、第二设备交互执行;比如,上述第一设备、第二设备可以是图1所示网络架构中的物联网设备110和物联网设备120。该方法可以包括以下步骤。Please refer to Figure 6, which shows a flow chart of an event management method provided by an embodiment of the present application. This method can be interactively executed by a first device and a second device; for example, the above-mentioned first device and second device can be as shown in Figure 6. The IoT device 110 and the IoT device 120 in the network architecture shown in 1. The method may include the following steps.
步骤601,第一设备接收优先级设置指令。Step 601: The first device receives a priority setting instruction.
其中,第一设备在发送事件获取请求之前,可以先显示一个优先级设置界面,由用户在该优先级设置界面中设置需要获取的事件的优先级。Before sending the event acquisition request, the first device may first display a priority setting interface, and the user sets the priority of the event to be obtained in the priority setting interface.
可选的,用户在通过优先级设置界面设置需要获取的事件的优先级时,可以对应指定的目标来设置上述优先级,比如,用户可以在优先级设置界面中,选择设置的优先级生效的目标群集、目标端点、目标节点等等。也就是说,用户在该优先级设置界面中设置的优先级适用于用户选择的上述目标群集、目标端点和/或目标节点。例如,用户在优先级设置界面中选择优先级生效的群集标识1、端点标识2以及节点标识3时,其中,群集标识1对应群集a,端点标识2对应端点b,节点标识3对应节点c;后续该优先级将节点c上的端点b中的群集a生效。Optionally, when the user sets the priority of the events to be obtained through the priority setting interface, the user can set the above priority corresponding to the specified target. For example, the user can select the set priority to take effect in the priority setting interface. Target cluster, target endpoint, target node, etc. That is to say, the priority set by the user in this priority setting interface is applicable to the above-mentioned target cluster, target endpoint and/or target node selected by the user. For example, when the user selects cluster ID 1, endpoint ID 2, and node ID 3 with valid priorities in the priority setting interface, cluster ID 1 corresponds to cluster a, endpoint ID 2 corresponds to endpoint b, and node ID 3 corresponds to node c; Subsequently, this priority will take effect in cluster a in endpoint b on node c.
或者,上述优先级设置界面也可以是与目标节点上的目标端点中的目标群集固定对应的界面,用户在该优先级设置界面中设置优先级后,设置的优先级即为对应上述目标节点上的目标端点中的目标群集的优先级。Alternatively, the above priority setting interface can also be an interface corresponding to the target cluster in the target endpoint on the target node. After the user sets the priority in the priority setting interface, the set priority is the one corresponding to the target cluster on the target node. The priority of the target cluster in the target endpoint.
或者,用户也可以设置全局的优先级,也就是说,用户设置的优先级不限制在特定的群集、端点或者节点上。Alternatively, users can set global priorities, which means that the priorities they set are not limited to specific clusters, endpoints, or nodes.
步骤602,第一设备根据优先级设置指令设置第一目标事件优先级。Step 602: The first device sets the first target event priority according to the priority setting instruction.
在本申请实施例的一个可能的实现方案中,第一设备可以根据优先级设置指令,在生成事件获取请求时,在事件获取请求中设置上述第一目标事件优先级。In a possible implementation solution of the embodiment of the present application, the first device may set the above-mentioned first target event priority in the event acquisition request when generating the event acquisition request according to the priority setting instruction.
在本申请实施例的另一种可能的实现方案中,第一设备也可以在生成事件获取请求之前,根据优先级设置指令设置第一目标事件优先级并存储在指定位置,在生成事件获取请求时,将预先存储的第一目标事件优先级添加至事件获取请求中。In another possible implementation of the embodiment of this application, the first device can also set the first target event priority according to the priority setting instruction and store it in a designated location before generating the event acquisition request. When, the pre-stored first target event priority is added to the event acquisition request.
步骤603,第一设备向第二设备发送事件获取请求,第二设备接收该事件获取请求;该事件获取请求中包含第一目标事件优先级。Step 603: The first device sends an event acquisition request to the second device, and the second device receives the event acquisition request; the event acquisition request includes the first target event priority.
在本申请实施例中,第一设备需要获取第二设备中的事件时,可以向第二设备发送事件获取请求。In this embodiment of the present application, when the first device needs to obtain an event in the second device, it can send an event acquisition request to the second device.
可选的,上述事件获取请求中除了包含第一目标事件优先级之外,还可以包含用于指示要获取的事件的相关信息,比如,可以包含第二设备的节点标识信息、第二节点中的目标端点的端点标识信息、第二节点中的目标群集的群集标识信息等等。Optionally, in addition to the priority of the first target event, the above event acquisition request may also include relevant information indicating the event to be acquired. For example, it may include the node identification information of the second device, the endpoint identification information for the target endpoint, cluster identification information for the target cluster in the second node, and so on.
在一种可能的实现方式中,上述事件获取请求包括事件订阅请求或者事件读取请求。In a possible implementation, the above event acquisition request includes an event subscription request or an event reading request.
比如,上述第一设备发送给第二设备的事件获取请求可以是用于读取事件的读请求Read Request。For example, the event acquisition request sent by the first device to the second device may be a Read Request for reading events.
或者,上述第一设备发送给第二设备的事件获取请求,可以是用于订阅事件的订阅请求Subscribe Request。Alternatively, the event acquisition request sent by the first device to the second device may be a Subscribe Request for subscribing to events.
在一种可能的实现方式中,上述第一目标事件优先级可以设置在事件获取请求的事件过滤信息块中。In a possible implementation manner, the above-mentioned first target event priority may be set in the event filtering information block of the event acquisition request.
在本申请实施例所示的方案中,第一设备和第二设备之间可以基于Matter协议建立连接;In the solution shown in the embodiment of this application, a connection can be established between the first device and the second device based on the Matter protocol;
第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
第二设备记录的事件是对应第二设备中的目标群集记录的事件。The events recorded by the second device correspond to events recorded by the target cluster in the second device.
在本申请实施例中,上述第一目标事件优先级可以设置在Read Request或者Subscribe Request的EventFilterIB(Information Blocks,信息块)中。In the embodiment of this application, the above-mentioned first target event priority can be set in the EventFilterIB (Information Blocks, information block) of Read Request or Subscribe Request.
比如,在本申请实施例中,可以在EventFilterIB中添加权限过滤的标识,如下述表7所示:For example, in the embodiment of this application, the permission filtering identifier can be added to EventFilterIB, as shown in the following Table 7:
表7Table 7
Figure PCTCN2022091579-appb-000004
Figure PCTCN2022091579-appb-000004
如表7所示,在EventFilterIB中,通过1字节的Priority属性来表示当前请求/订阅的事件所要满足的优先级。As shown in Table 7, in EventFilterIB, the 1-byte Priority attribute is used to indicate the priority that the currently requested/subscribed event must satisfy.
步骤604,第二设备向第一设备发送与第一目标事件优先级匹配的至少一个目标事件;第一设备接收该至少一个目标事件。Step 604: The second device sends at least one target event that matches the priority of the first target event to the first device; the first device receives the at least one target event.
在本申请实施例中,第二设备接收到第一设备发送的事件获取请求后,根据事件获取请求中的端点标识信息以及群集标识信息确定第一设备想要获取的事件所属的群集,然后在该群集对应的事件中查询与第一目标事件优先级匹配的事件,过滤掉与第一目标事件优先级不匹配的事件,并将查询得到的事件(即上述至少一个目标事件)发送给第一设备。In this embodiment of the present application, after receiving the event acquisition request sent by the first device, the second device determines the cluster to which the event that the first device wants to acquire belongs to based on the endpoint identification information and cluster identification information in the event acquisition request, and then Query events corresponding to the cluster that match the priority of the first target event, filter out events that do not match the priority of the first target event, and send the queried events (i.e., at least one of the above target events) to the first equipment.
在一种可能的实现方式中,至少一个目标事件包括优先级高于或者等于第一目标事件优先级的事件。In a possible implementation manner, at least one target event includes an event with a priority higher than or equal to the priority of the first target event.
在本申请实施例中,事件获取请求中携带的第一目标事件优先级可以指示单个优先级,第二设备向第一设备返回事件时,将对应群集中不低于该优先级的事件返回给第一设备。In this embodiment of the present application, the first target event priority carried in the event acquisition request can indicate a single priority. When the second device returns an event to the first device, it will return events in the corresponding cluster that are not lower than this priority to the first device. First device.
例如,事件的优先级分为3类DEBUG、INFO、CRITICAL,其中优先级从高到低的顺序为CRITICAL>INFO>DEBUG。For example, the priority of events is divided into three categories: DEBUG, INFO, and CRITICAL. The priority order from high to low is CRITICAL>INFO>DEBUG.
如果第一设备下发Read&Subscribe请求时将EventFilterIB中的Priority设置为DEBUG,第二设备返回DEBUG、INFO、CRITICAL三种优先级的事件消息;如果第一设备下发Read&Subscribe请求时将EventFilterIB中的Priority设置为INFO,第二设备返回INFO、CRITICAL两种优先级的事件消息;如果第一设备下发Read&Subscribe请求时将EventFilterIB中的Priority设置为CRITICAL,第二设备返回CRITICAL一种优先级的事件消息。If the first device sets the Priority in EventFilterIB to DEBUG when it sends a Read&Subscribe request, the second device returns event messages with three priorities: DEBUG, INFO, and CRITICAL; if the first device sets the Priority in EventFilterIB when it sends a Read&Subscribe request. is INFO, the second device returns event messages with two priorities, INFO and CRITICAL; if the first device sets the Priority in EventFilterIB to CRITICAL when issuing a Read&Subscribe request, the second device returns event messages with one priority, CRITICAL.
在一种可能的实现方式中,至少一个目标事件包括优先级等于第一目标事件优先级的事件。In a possible implementation manner, at least one target event includes an event with a priority equal to the priority of the first target event.
在本申请实施例中,事件获取请求中携带的第一目标事件优先级可以指示单个或者多个优先级,第二设备向第一设备返回事件时,将对应群集中对应该单个或者多个优先级中的任 意优先级的事件返回给第一设备。In this embodiment of the present application, the first target event priority carried in the event acquisition request can indicate a single or multiple priorities. When the second device returns an event to the first device, the single or multiple priorities in the corresponding cluster will be Events of any priority in the level are returned to the first device.
例如,如果第一设备下发Read&Subscribe请求时将EventFilterIB中的Priority设置为DEBUG,第二设备返回DEBUG优先级的事件消息;如果第一设备下发Read&Subscribe请求时将EventFilterIB中的Priority设置为INFO,第二设备返回INFO优先级的事件消息;如果第一设备下发Read&Subscribe请求时将EventFilterIB中的Priority设置为CRITICAL,第二设备返回CRITICAL优先级的事件消息。For example, if the first device sets the Priority in EventFilterIB to DEBUG when sending a Read&Subscribe request, the second device returns an event message with DEBUG priority; if the first device sets the Priority in EventFilterIB to INFO when sending a Read&Subscribe request, the second device returns an event message with DEBUG priority. The second device returns an event message with INFO priority; if the first device sets the Priority in EventFilterIB to CRITICAL when issuing a Read&Subscribe request, the second device returns an event message with CRITICAL priority.
比如,请参考图7,其示出了本申请实施例涉及的一种事件获取的流程图。以上述第一设备是物联网中的控制端,第二设备是物联网中的设备端为例,如图7所示,该流程可以包括以下步骤:For example, please refer to FIG. 7 , which shows a flow chart of event acquisition related to an embodiment of the present application. Taking the above-mentioned first device as the control terminal in the Internet of Things and the second device as the device terminal in the Internet of Things as an example, as shown in Figure 7, the process may include the following steps:
S71,用户在控制端中设置Read Request或者Subscribe Request消息中EventFileterIB的Priority字段,筛选用户关心的优先级事件。S71, the user sets the Priority field of EventFileterIB in the Read Request or Subscribe Request message in the control terminal to filter the priority events that the user cares about.
比如,控制端可以是智能手机等用户终端,用户在智能手机的APP(Application,应用程序)中查看设备端的信息,点击该设备端的事件优先级设置选项可以设置读取或者订阅该设备端中的事件的优先级。For example, the control terminal can be a user terminal such as a smartphone. The user views the device-side information in the smartphone's APP (Application), and clicks the event priority setting option on the device-side to read or subscribe to the device-side information. The priority of the event.
S72,用户向控制端发出读取或者订阅设备端中某一项或者多项群集中的事件的请求。S72: The user sends a request to the control terminal to read or subscribe to one or more events in the cluster on the device terminal.
比如,用户可以在APP中点击设备端的事件读取/订阅选项,以发出读取或者订阅设备端中某一项或者多项群集中的事件的请求。For example, the user can click the event reading/subscription option on the device side in the APP to issue a request to read or subscribe to one or more events in one or more clusters on the device side.
S73,控制端向设备端发送事件读取/订阅请求,该事件读取/订阅请求中携带有指示优先级的信息。S73: The control end sends an event read/subscribe request to the device end, and the event read/subscribe request carries information indicating priority.
比如,该事件读取/订阅请求的EventFilterIB中的Priority被设置为用户设置的优先级对应的值。For example, the Priority in the EventFilterIB of the event read/subscription request is set to the value corresponding to the priority set by the user.
S74,设备端向控制端返回与事件读取/订阅请求所指示的优先级匹配的事件。S74: The device side returns events matching the priority indicated by the event reading/subscription request to the control side.
在本申请实施例中,设备端接收到控制端发送的事件读取/订阅请求后,即可以在对应的群集中筛选出满足用户设置的优先级的事件,并将筛选出的事件返回给控制端。In the embodiment of this application, after the device receives the event reading/subscription request sent by the control, it can filter out the events that meet the priority set by the user in the corresponding cluster, and return the filtered events to the control. end.
S75,控制端将设备端返回的事件显示给用户。S75: The control terminal displays the event returned by the device terminal to the user.
综上所述,本申请实施例所示的方案中,第一设备请求获取第二设备中的事件时,可以在请求中指示需要获取的事件的优先级,相应的,第二设备可以将优先级匹配的事件发送给第一设备,其中,上述优先级可以由用户进行设置,从而实现了在事件获取过程中,通过用户指定的优先级对获取的事件进行过滤,提高了物联网系统中的事件获取的灵活性。To sum up, in the solution shown in the embodiment of the present application, when the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request. Correspondingly, the second device can prioritize Events matching the level are sent to the first device, where the above-mentioned priority can be set by the user, thereby achieving filtering of the acquired events through the user-specified priority during the event acquisition process, improving the efficiency of the Internet of Things system. Flexibility in event acquisition.
请参考图8,其示出了本申请一个实施例提供的事件管理方法的流程图,该方法可以由第一设备执行,比如,该第一设备可以是图1所示的网络架构中的物联网设备110或者物联网设备120中的一个;该方法可以包括如下步骤:Please refer to Figure 8, which shows a flow chart of an event management method provided by an embodiment of the present application. The method can be executed by a first device. For example, the first device can be an object in the network architecture shown in Figure 1. One of the networking device 110 or the Internet of Things device 120; the method may include the following steps:
步骤801,向第二设备发送事件优先级设置请求;事件优先级设置请求中包含第二目标事件优先级;事件优先级设置请求用于指示第二设备记录与第二目标事件优先级匹配的至少一个目标事件。Step 801: Send an event priority setting request to the second device; the event priority setting request contains the second target event priority; the event priority setting request is used to instruct the second device to record at least one event that matches the second target event priority. A target event.
综上所述,本申请实施例所示的方案,第一设备可以指示第二设备在记录事件时,记录满足指定的优先级的事件,后续第一设备向第二设备读取事件时,读取到的事件即为满足上述指定的优先级的事件,从而实现了在事件记录的过程中,通过优先级对产生的事件进行过滤,提高了物联网系统中的事件记录以及获取的灵活性。To sum up, according to the solution shown in the embodiment of the present application, the first device can instruct the second device to record events that meet the specified priority when recording events. Subsequently, when the first device reads events from the second device, it reads The retrieved events are those that meet the above-specified priority. This enables filtering of generated events by priority during the event recording process, improving the flexibility of event recording and acquisition in the Internet of Things system.
请参考图9,其示出了本申请一个实施例提供的事件管理方法的流程图,该方法可以由第二设备执行,比如,该第二设备可以是图1所示的网络架构中的物联网设备110或者物联网设备120中的一个;该方法可以包括如下步骤:Please refer to Figure 9, which shows a flow chart of an event management method provided by an embodiment of the present application. The method can be executed by a second device. For example, the second device can be an object in the network architecture shown in Figure 1. One of the networking device 110 or the Internet of Things device 120; the method may include the following steps:
步骤901,接收第一设备发送的事件优先级设置请求;事件优先级设置请求中包含第二目标事件优先级。Step 901: Receive an event priority setting request sent by the first device; the event priority setting request includes the second target event priority.
步骤902,根据事件优先级设置信息,记录与第二目标事件优先级匹配的至少一个目标事件。Step 902: Record at least one target event that matches the second target event priority according to the event priority setting information.
综上所述,本申请实施例所示的方案,第一设备可以指示第二设备在记录事件时,记录满足指定的优先级的事件,后续第一设备向第二设备读取事件时,读取到的事件即为满足上述指定的优先级的事件,从而实现了在事件记录的过程中,通过优先级对产生的事件进行过滤,提高了物联网系统中的事件记录以及获取的灵活性。To sum up, according to the solution shown in the embodiment of the present application, the first device can instruct the second device to record events that meet the specified priority when recording events. Subsequently, when the first device reads events from the second device, it reads The retrieved events are those that meet the above-specified priority. This enables filtering of generated events by priority during the event recording process, improving the flexibility of event recording and acquisition in the Internet of Things system.
基于上述图8和图9所示的方案,请参考图10,其示出了本申请一个示例性的实施例提供的一种事件管理的框架图。如图10所示,第一设备1001可以向第二设备1002发送指示某个群集中的事件的优先级的设置请求。第二设备1002接收到该设置请求之后,后续在生成该群集相关的事件时,若生成的事件满足上述优先级,则将事件进行记录,否则该将事件丢弃。Based on the solutions shown in FIGS. 8 and 9 above, please refer to FIG. 10 , which shows a framework diagram of event management provided by an exemplary embodiment of the present application. As shown in FIG. 10 , the first device 1001 may send a setting request indicating the priority of events in a certain cluster to the second device 1002 . After the second device 1002 receives the setting request, when subsequently generating an event related to the cluster, if the generated event meets the above priority, the event will be recorded; otherwise, the event will be discarded.
后续第一设备1001向第二设备1002获取该群集相关的事件时,获取到的事件均为满足上述优先级的事件。When the first device 1001 subsequently acquires events related to the cluster from the second device 1002, the acquired events are all events that satisfy the above priority.
基于上述图8至图10所示的方案,在一种可能的情况下,上述第二目标事件优先级可以由第一设备对应的用户进行设置。Based on the solutions shown in FIGS. 8 to 10 , in one possible case, the second target event priority may be set by the user corresponding to the first device.
请参考图11,其示出了本申请一个实施例提供的事件管理方法的流程图,该方法可以由第一设备、第二设备交互执行;比如,上述第一设备、第二设备可以是图1所示网络架构中的物联网设备110和物联网设备120。该方法可以包括以下步骤。Please refer to Figure 11, which shows a flow chart of an event management method provided by an embodiment of the present application. This method can be interactively executed by a first device and a second device; for example, the above-mentioned first device and second device can be as shown in Figure 11. The IoT device 110 and the IoT device 120 in the network architecture shown in 1. The method may include the following steps.
步骤1101,第一设备接收优先级设置指令。Step 1101: The first device receives a priority setting instruction.
步骤1102,第一设备根据优先级设置指令设置第二目标事件优先级。Step 1102: The first device sets the second target event priority according to the priority setting instruction.
在本申请实施例的一个可能的实现方案中,第一设备可以根据优先级设置指令,在生成事件优先级设置请求时,在事件优先级设置请求中设置上述第二目标事件优先级。In a possible implementation solution of the embodiment of the present application, the first device may set the above-mentioned second target event priority in the event priority setting request when generating the event priority setting request according to the priority setting instruction.
在本申请实施例的另一种可能的实现方案中,第一设备也可以在生成事件优先级设置请求之前,根据优先级设置指令设置第二目标事件优先级并存储在指定位置,在生成事件优先级设置请求时,将预先存储的事件优先级设置请求添加至事件获取请求中。In another possible implementation of the embodiment of this application, the first device can also set the second target event priority according to the priority setting instruction and store it in a designated location before generating the event priority setting request. When making a priority setting request, add the pre-stored event priority setting request to the event acquisition request.
步骤1103,第一设备向第二设备发送事件优先级设置请求,第二设备接收该事件优先级设置请求;事件优先级设置请求中包含第二目标事件优先级。Step 1103: The first device sends an event priority setting request to the second device, and the second device receives the event priority setting request; the event priority setting request includes the second target event priority.
在本申请实施例中,用户需要控制第二设备记录某个群集中满足特定优先级要求的事件时,可以触发第一设备向第二设备发送事件优先级设置请求,请求中携带用户之前设置的优先级对应的第二目标事件优先级。In the embodiment of this application, when the user needs to control the second device to record events that meet specific priority requirements in a certain cluster, the first device can be triggered to send an event priority setting request to the second device. The request carries the value previously set by the user. The priority of the second target event corresponding to the priority.
可选的,上述事件优先级设置请求中除了包含第二目标事件优先级之外,还可以包含用于指示要进行优先级过滤设置的事件的相关信息,比如,可以包含第二设备的节点标识信息、第二节点中的目标端点的端点标识信息、第二节点中的目标群集的群集标识信息等等。Optionally, in addition to the second target event priority, the above-mentioned event priority setting request may also include relevant information used to indicate the event to be set for priority filtering. For example, it may include the node identifier of the second device. information, endpoint identification information for the target endpoint in the second node, cluster identification information for the target cluster in the second node, and so on.
步骤1104,第二设备根据事件优先级设置信息,记录与第二目标事件优先级匹配的至少一个目标事件。Step 1104: The second device records at least one target event that matches the priority of the second target event according to the event priority setting information.
在本申请实施例中,第二设备接收到事件优先级设置请求后,后续再生成对应的群集中的事件时,可以比较新生成的事件的优先级与事件优先级设置信息对应的优先级,若新生成的事件的优先级与事件优先级设置信息对应的优先级匹配,则对该事件进行记录,否则不对该事件进行记录。In this embodiment of the present application, after the second device receives the event priority setting request, when it subsequently generates an event in the corresponding cluster, it can compare the priority of the newly generated event with the priority corresponding to the event priority setting information. If the priority of the newly generated event matches the priority corresponding to the event priority setting information, the event will be recorded; otherwise, the event will not be recorded.
可选的,第二设备接收到事件优先级设置请求时,若该事件优先级设置请求对应的群集中存在已有事件,则第二设备还可以对上述已有事件进行筛选,比如,当该已有事件的优先级与事件优先级设置信息对应的优先级匹配时,则保留该已有事件,否则删除该已有事件。Optionally, when the second device receives an event priority setting request, if there are existing events in the cluster corresponding to the event priority setting request, the second device can also filter the above existing events. For example, when the event priority setting request When the priority of an existing event matches the priority corresponding to the event priority setting information, the existing event is retained; otherwise, the existing event is deleted.
在一种可能的实现方式中,上述第二目标事件优先级包括写属性指令;写属性指令用于指示第二设备在目标群集中写入与第二目标事件优先级对应的事件优先级属性。In a possible implementation, the above-mentioned second target event priority includes a write attribute instruction; the write attribute instruction is used to instruct the second device to write the event priority attribute corresponding to the second target event priority in the target cluster.
相应的,第二设备根据事件优先级设置信息,记录与第二目标事件优先级匹配的至少一个目标事件之前,可以目标群集中写入与第二目标事件优先级对应的事件优先级属性;第二设备根据事件优先级设置信息,记录与第二目标事件优先级匹配的至少一个目标事件的过程可以包括:Correspondingly, before recording at least one target event matching the second target event priority according to the event priority setting information, the second device may write the event priority attribute corresponding to the second target event priority in the target cluster; The process of the second device recording at least one target event that matches the priority of the second target event according to the event priority setting information may include:
当目标群集产生第一事件,且第一事件与事件优先级属性匹配时,将第一事件记录为目标群集的一条目标事件。When the target cluster generates the first event and the first event matches the event priority attribute, the first event is recorded as a target event of the target cluster.
在本申请实施例所示的方案中,第一设备和第二设备之间可以基于Matter协议建立连接;In the solution shown in the embodiment of this application, a connection can be established between the first device and the second device based on the Matter protocol;
第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
第二设备记录的事件是对应第二设备中的目标群集记录的事件。The events recorded by the second device correspond to events recorded by the target cluster in the second device.
在本申请实施例中,物联网设备的群集中的全局属性(Global Elements)中可以增加一个可写的属性(事件优先级属性),用来指示该群集中记录的事件的优先级。比如,该可写的属性可以如下述表8所示:In this embodiment of the present application, a writable attribute (event priority attribute) can be added to the global attributes (Global Elements) in the cluster of Internet of Things devices to indicate the priority of events recorded in the cluster. For example, the writable attribute can be shown in Table 8 below:
表8Table 8
Attribute IDAttribute ID NameName TypeType
0xFFF70xFFF7 EventPriorityEventPriority EnumEnum
在一种可能的实现方式中,至少一个目标事件包括优先级高于或者等于第二目标事件优先级的事件。In a possible implementation manner, at least one target event includes an event with a priority higher than or equal to the priority of the second target event.
通过本申请实施例所示的方案,用户可以通过事件优先级属性设置第二设备记录的事件的优先级:比如,属性优先级分为3类DEBUG、INFO、CRITICAL,CRITICAL>INFO>DEBUG,则设置方案可以如下:Through the solution shown in the embodiment of this application, the user can set the priority of the event recorded by the second device through the event priority attribute: for example, the attribute priority is divided into three categories: DEBUG, INFO, CRITICAL, CRITICAL>INFO>DEBUG, then The setting scheme can be as follows:
如果第一设备将第二设备中对应Cluster的EventPriority设置为DEBUG,第二设备会有DEBUG、INFO、CRITICAL三种优先级的事件产生(即生成并记录);如果第一设备将第二设备对应Cluster的EventPriority设置为INFO,第二设备会有INFO、CRITICAL两种优先级的事件消息产生(DEBUG优先级的消息可以生成且不记录,或者不生成);如果第一设备将第二设备对应Cluster的EventPriority设置为CRITICAL,第而设备会有CRITICAL一种优先级的事件消息产生(DEBUG和INFO优先级的消息可以生成且不记录,或者不生成)。If the first device sets the EventPriority of the corresponding Cluster in the second device to DEBUG, the second device will generate (ie generate and record) events with three priorities: DEBUG, INFO, and CRITICAL; if the first device sets the corresponding Cluster in the second device to If the Cluster's EventPriority is set to INFO, the second device will generate event messages with two priorities, INFO and CRITICAL (DEBUG priority messages can be generated and not recorded, or not generated); if the first device sets the second device to the Cluster The EventPriority is set to CRITICAL, and the device will generate event messages with CRITICAL priority (DEBUG and INFO priority messages can be generated and not recorded, or not generated).
在一种可能的实现方式中,至少一个目标事件包括优先级等于第二目标事件优先级的事件。In a possible implementation manner, at least one target event includes an event with a priority equal to the priority of the second target event.
比如,属性优先级分为3类DEBUG、INFO、CRITICAL,CRITICAL>INFO>DEBUG,则设置方案可以如下:For example, if the attribute priority is divided into three categories: DEBUG, INFO, and CRITICAL, CRITICAL>INFO>DEBUG, the setting plan can be as follows:
如果第一设备将第二设备对应Cluster的EventPriority设置为DEBUG,第二设备会有DEBUG优先级的事件消息产生(另外两种优先级的事件消息可以生成且不记录,或者不生成);如果第一设备将第二设备对应Cluster的EventPriority设置为INFO,第二设备会有INFO优先级的事件消息产生;如果第一设备将第二设备对应Cluster的EventPriority设置为CRITICAL,第二设备会有CRITICAL优先级的事件消息产生。If the first device sets the EventPriority of the Cluster corresponding to the second device to DEBUG, the second device will generate event messages with DEBUG priority (the other two priority event messages can be generated and not recorded, or not generated); if the second device If one device sets the EventPriority of the second device corresponding to the Cluster to INFO, the second device will generate event messages with INFO priority; if the first device sets the EventPriority of the second device corresponding to the Cluster to CRITICAL, the second device will have CRITICAL priority. Level event messages are generated.
比如,请参考图12,其示出了本申请实施例涉及的一种事件记录设置的流程图。以上述第一设备是物联网中的控制端,第二设备是物联网中的设备端为例,如图12所示,该流程可以包括以下步骤:For example, please refer to Figure 12, which shows a flow chart of an event recording setting related to an embodiment of the present application. Taking the above-mentioned first device as the control terminal in the Internet of Things and the second device as the device terminal in the Internet of Things as an example, as shown in Figure 12, the process may include the following steps:
S1201,用户在控制端中设置某个群集的事件优先级EventPriority属性。S1201, the user sets the EventPriority attribute of a certain cluster in the control terminal.
比如,控制端可以是智能手机等用户终端,用户在智能手机的APP中查看设备端的信息,点击该设备端的事件优先级设置选项可以设置该设备端产生的事件的优先级。For example, the control terminal can be a user terminal such as a smartphone. The user views device-side information in the smartphone APP and clicks the event priority setting option on the device to set the priority of events generated by the device.
S1202,用户触发控制端发出写属性指令。S1202, the user triggers the control terminal to issue a write attribute instruction.
比如,用户可以在APP中点击设备端的事件优先级设置选项,以发出在设备端的某个 群集中写入事件优先级属性的指令。For example, the user can click the event priority setting option on the device side in the APP to issue an instruction to write the event priority attribute in a cluster on the device side.
S1203,控制端向设备端发送写属性指令。S1203. The control end sends a write attribute instruction to the device end.
比如,该写属性指令中可以携带上述事件优先级属性,或者,携带上述事件优先级属性对应的优先级指示信息。For example, the write attribute instruction may carry the above-mentioned event priority attribute, or carry priority indication information corresponding to the above-mentioned event priority attribute.
S1204,设备端根据用户设置EventPriority属性,记录相应优先级的事件消息。S1204: The device records the event message of the corresponding priority according to the EventPriority attribute set by the user.
其中,设备端接收到上述写属性指令后,可以将事件优先级属性写入对应群集的全局属性中。后续设备端发生与该群集相关的事件时,若该事件的优先级满足上述事件优先级属性对应的优先级的要求,则设备端记录该事件,否则不记录该事件。Among them, after the device side receives the above write attribute instruction, it can write the event priority attribute into the global attribute of the corresponding cluster. When subsequent events related to the cluster occur on the device, if the priority of the event meets the priority requirements corresponding to the above event priority attributes, the device will record the event, otherwise the event will not be recorded.
后续控制端获取设备端记录与该群集相关的事件时,可以保证获取到的事件是满足用户设置的优先级的事件。When the control end later obtains events related to the cluster recorded by the device end, it can be guaranteed that the events obtained are events that meet the priority set by the user.
综上所述,本申请实施例所示的方案,第一设备可以指示第二设备在记录事件时,记录满足用户指定的优先级的事件,后续第一设备向第二设备读取事件时,读取到的事件即为满足上述指定的优先级的事件,从而实现了在事件记录的过程中,通过用户设置的优先级对产生的事件进行过滤,提高了物联网系统中的事件记录以及获取的灵活性。To sum up, according to the solution shown in the embodiment of this application, the first device can instruct the second device to record events that meet the priority specified by the user when recording events. Subsequently, when the first device reads events from the second device, The events read are those that meet the above specified priorities, thus enabling filtering of generated events through the priorities set by the user during the event recording process, improving event recording and acquisition in the Internet of Things system flexibility.
其中,通过本申请上述图3至图7所示的方案,用户可以根据自己的意图获取设备上对应优先级的事件消息。Among them, through the solutions shown in Figures 3 to 7 of the present application, users can obtain event messages with corresponding priorities on the device according to their own intentions.
通过本申请上述图8至图12所示的方案,用户可以根据自己意图使设备记录用户关心的优先级的事件。Through the solution shown in FIGS. 8 to 12 of the present application, the user can make the device record the priority events that the user cares about according to his own intention.
上述两种方案可以独立使用,或者,上述两种方案也可以结合使用,比如,用户首先通过本申请上述图8至图12所示的方案,使设备记录用户关心的优先级的事件,比如,通过上述图8至图12所示的方案使设备记录CRITICAL和INFO这两种优先级的事件;后续用户在获取事件消息时,通过上述图3至图7所示的方案,从设备中读取指定的优先级的事件,比如,从设备中读取CRITICAL或者INFO优先级的事件。The above two solutions can be used independently, or the above two solutions can also be used in combination. For example, the user first uses the solutions shown in Figures 8 to 12 of the present application to cause the device to record priority events that the user is concerned about, such as, Through the above-mentioned scheme shown in Figure 8 to Figure 12, the device records two priority events, CRITICAL and INFO; when subsequent users obtain the event message, they can read it from the device through the above-mentioned scheme shown in Figure 3 to Figure 7. Events with specified priority, for example, reading CRITICAL or INFO priority events from the device.
请参考图13,其示出了本申请一个实施例提供的事件管理装置的框图。该事件管理装置1300具有实现上述图3或图6所示的方法中,由第一设备执行的功能。如图13所示,该事件管理装置1300可以包括:Please refer to Figure 13, which shows a block diagram of an event management device provided by an embodiment of the present application. The event management device 1300 has the function of being executed by the first device in implementing the method shown in FIG. 3 or FIG. 6 . As shown in Figure 13, the event management device 1300 may include:
发送模块1301,用于向第二设备发送事件获取请求;所述事件获取请求中包含第一目标事件优先级;Sending module 1301, configured to send an event acquisition request to the second device; the event acquisition request includes the first target event priority;
接收模块1302,用于接收所述第二设备发送的,与所述第一目标事件优先级匹配的至少一个目标事件。The receiving module 1302 is configured to receive at least one target event sent by the second device that matches the priority of the first target event.
在一种可能的实现方式中,所述第一目标事件优先级设置在所述事件获取请求的事件过滤信息块中。In a possible implementation manner, the first target event priority is set in the event filtering information block of the event acquisition request.
在一种可能的实现方式中,至少一个所述目标事件包括优先级高于或者等于所述第一目标事件优先级的事件;In a possible implementation, at least one of the target events includes an event with a priority higher than or equal to the priority of the first target event;
或者,至少一个所述目标事件包括优先级等于所述第一目标事件优先级的事件。Alternatively, at least one of the target events includes an event with a priority equal to the priority of the first target event.
在一种可能的实现方式中,所述装置还包括:In a possible implementation, the device further includes:
指令接收模块,用于在所述发送模块1301向第二设备发送事件获取请求之前,接收优先级设置指令;An instruction receiving module, configured to receive a priority setting instruction before the sending module 1301 sends an event acquisition request to the second device;
设置模块,用于根据所述优先级设置指令设置所述第一目标事件优先级。A setting module configured to set the first target event priority according to the priority setting instruction.
在一种可能的实现方式中,所述事件获取请求包括事件订阅请求或者事件读取请求。In a possible implementation, the event acquisition request includes an event subscription request or an event reading request.
在本申请实施例所示的方案中,第一设备和第二设备之间可以基于Matter协议建立连接;In the solution shown in the embodiment of this application, a connection can be established between the first device and the second device based on the Matter protocol;
第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
第二设备记录的事件是对应第二设备中的目标群集记录的事件。The events recorded by the second device correspond to events recorded by the target cluster in the second device.
综上所述,本申请实施例所示的方案中,第一设备请求获取第二设备中的事件时,可以在请求中指示需要获取的事件的优先级,相应的,第二设备可以将优先级匹配的事件发送给第一设备,从而实现了在事件获取过程中,通过优先级对获取的事件进行过滤,提高了物联网系统中的事件获取的灵活性。To sum up, in the solution shown in the embodiment of the present application, when the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request. Correspondingly, the second device can prioritize Events matching the level are sent to the first device, thereby filtering the acquired events by priority during the event acquisition process, and improving the flexibility of event acquisition in the Internet of Things system.
请参考图14,其示出了本申请一个实施例提供的事件管理装置的框图。该事件管理装置1400具有实现上述图4或图6所示的方法中,由第二设备执行的功能。如图14所示,该事件管理装置1400可以包括:Please refer to Figure 14, which shows a block diagram of an event management device provided by an embodiment of the present application. The event management device 1400 has the function of being executed by the second device in implementing the method shown in FIG. 4 or FIG. 6 . As shown in Figure 14, the event management device 1400 may include:
接收模块1401,用于接收第一设备发送的事件获取请求;所述事件获取请求中包含第一目标事件优先级;The receiving module 1401 is configured to receive an event acquisition request sent by the first device; the event acquisition request includes the first target event priority;
发送模块1402,用于向所述第一设备发送与所述第一目标事件优先级匹配的至少一个目标事件。The sending module 1402 is configured to send at least one target event matching the priority of the first target event to the first device.
在一种可能的实现方式中,所述第一目标事件优先级设置在所述事件获取请求的事件过滤信息块中。In a possible implementation manner, the first target event priority is set in the event filtering information block of the event acquisition request.
在一种可能的实现方式中,至少一个所述目标事件包括优先级高于或者等于所述第一目标事件优先级的事件;In a possible implementation, at least one of the target events includes an event with a priority higher than or equal to the priority of the first target event;
或者,至少一个所述目标事件包括优先级等于所述第一目标事件优先级的事件。Alternatively, at least one of the target events includes an event with a priority equal to the priority of the first target event.
在一种可能的实现方式中,所述事件获取请求包括事件订阅请求或者事件读取请求。In a possible implementation, the event acquisition request includes an event subscription request or an event reading request.
在本申请实施例所示的方案中,第一设备和第二设备之间可以基于Matter协议建立连接;In the solution shown in the embodiment of this application, a connection can be established between the first device and the second device based on the Matter protocol;
第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
第二设备记录的事件是对应第二设备中的目标群集记录的事件。The events recorded by the second device correspond to events recorded by the target cluster in the second device.
综上所述,本申请实施例所示的方案中,第一设备请求获取第二设备中的事件时,可以在请求中指示需要获取的事件的优先级,相应的,第二设备可以将优先级匹配的事件发送给第一设备,从而实现了在事件获取过程中,通过优先级对获取的事件进行过滤,提高了物联网系统中的事件获取的灵活性。To sum up, in the solution shown in the embodiment of the present application, when the first device requests to obtain events in the second device, it can indicate the priority of the event that needs to be obtained in the request. Correspondingly, the second device can prioritize Events matching the level are sent to the first device, thereby filtering the acquired events by priority during the event acquisition process, and improving the flexibility of event acquisition in the Internet of Things system.
请参考图15,其示出了本申请一个实施例提供的事件管理装置的框图。该事件管理装置1500具有实现上述图8或图11所示的方法中,由第一设备执行的功能。如图15所示,该事件管理装置1500可以包括:Please refer to Figure 15, which shows a block diagram of an event management device provided by an embodiment of the present application. The event management device 1500 has the function of being executed by the first device in implementing the method shown in FIG. 8 or FIG. 11 . As shown in Figure 15, the event management device 1500 may include:
发送模块1501,用于向第二设备发送事件优先级设置请求;所述事件优先级设置请求中包含第二目标事件优先级;所述事件优先级设置请求用于指示所述第二设备记录与所述第二目标事件优先级匹配的至少一个目标事件。The sending module 1501 is used to send an event priority setting request to the second device; the event priority setting request includes the second target event priority; the event priority setting request is used to instruct the second device to record and At least one target event whose priority matches the second target event.
在一种可能的实现方式中,所述第二目标事件优先级包括写属性指令;所述写属性指令用于指示所述第二设备在目标群集中写入与所述第二目标事件优先级对应的事件优先级属性。In a possible implementation, the second target event priority includes a write attribute instruction; the write attribute instruction is used to instruct the second device to write in the target cluster the same as the second target event priority. The corresponding event priority attribute.
在一种可能的实现方式中,至少一个所述目标事件包括优先级高于或者等于所述第二目标事件优先级的事件;In a possible implementation, at least one of the target events includes an event with a priority higher than or equal to the priority of the second target event;
或者,至少一个所述目标事件包括优先级等于所述第二目标事件优先级的事件。Alternatively, at least one of the target events includes an event with a priority equal to the priority of the second target event.
在一种可能的实现方式中,所述装置还包括:In a possible implementation, the device further includes:
指令接收模块,用于在所述发送模块1501向第二设备发送事件优先级设置请求之前,接收优先级设置指令;An instruction receiving module, configured to receive a priority setting instruction before the sending module 1501 sends an event priority setting request to the second device;
设置模块,用于根据所述优先级设置指令设置所述第二目标事件优先级。A setting module configured to set the second target event priority according to the priority setting instruction.
在本申请实施例所示的方案中,第一设备和第二设备之间可以基于Matter协议建立连 接;In the solution shown in the embodiment of this application, a connection can be established between the first device and the second device based on the Matter protocol;
第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
第二设备记录的事件是对应第二设备中的目标群集记录的事件。The events recorded by the second device correspond to events recorded by the target cluster in the second device.
综上所述,本申请实施例所示的方案,第一设备可以指示第二设备在记录事件时,记录满足指定的优先级的事件,后续第一设备向第二设备读取事件时,读取到的事件即为满足上述指定的优先级的事件,从而实现了在事件记录的过程中,通过优先级对产生的事件进行过滤,提高了物联网系统中的事件记录以及获取的灵活性。To sum up, according to the solution shown in the embodiment of the present application, the first device can instruct the second device to record events that meet the specified priority when recording events. Subsequently, when the first device reads events from the second device, it reads The retrieved events are those that meet the above-specified priority. This enables filtering of generated events by priority during the event recording process, improving the flexibility of event recording and acquisition in the Internet of Things system.
请参考图16,其示出了本申请一个实施例提供的事件管理装置的框图。该事件管理装置1600具有实现上述图9或图11所示的方法中,由第二设备执行的功能。如图16所示,该事件管理装置1600可以包括:Please refer to Figure 16, which shows a block diagram of an event management device provided by an embodiment of the present application. The event management device 1600 has the function of being executed by the second device in implementing the method shown in FIG. 9 or FIG. 11 . As shown in Figure 16, the event management device 1600 may include:
接收模块1601,用于接收第一设备发送的事件优先级设置请求;所述事件优先级设置请求中包含第二目标事件优先级;The receiving module 1601 is configured to receive an event priority setting request sent by the first device; the event priority setting request includes the second target event priority;
记录模块1602,用于根据所述事件优先级设置信息,记录与所述第二目标事件优先级匹配的至少一个目标事件。The recording module 1602 is configured to record at least one target event that matches the second target event priority according to the event priority setting information.
在一种可能的实现方式中,所述第二目标事件优先级包括写属性指令;In a possible implementation, the second target event priority includes a write attribute instruction;
所述装置还包括:The device also includes:
属性写入模块,用于在所述记录模块1602根据所述事件优先级设置信息,记录与所述第二目标事件优先级匹配的至少一个目标事件之前,在目标群集中写入与所述第二目标事件优先级对应的事件优先级属性;An attribute writing module, configured to write the content of the first target event in the target cluster before the recording module 1602 records at least one target event matching the priority of the second target event according to the event priority setting information. The event priority attribute corresponding to the priority of the second target event;
所述记录模块1602,用于当所述目标群集产生第一事件,且所述第一事件与所述事件优先级属性匹配时,将所述第一事件记录为所述目标群集的一条所述目标事件。The recording module 1602 is configured to record the first event as an item of the target cluster when the target cluster generates a first event and the first event matches the event priority attribute. target event.
在一种可能的实现方式中,至少一个所述目标事件包括优先级高于或者等于所述第二目标事件优先级的事件;In a possible implementation, at least one of the target events includes an event with a priority higher than or equal to the priority of the second target event;
或者,至少一个所述目标事件包括优先级等于所述第二目标事件优先级的事件。Alternatively, at least one of the target events includes an event with a priority equal to the priority of the second target event.
在本申请实施例所示的方案中,第一设备和第二设备之间可以基于Matter协议建立连接;In the solution shown in the embodiment of this application, a connection can be established between the first device and the second device based on the Matter protocol;
第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
第二设备记录的事件是对应第二设备中的目标群集记录的事件。The events recorded by the second device correspond to events recorded by the target cluster in the second device.
综上所述,本申请实施例所示的方案,第一设备可以指示第二设备在记录事件时,记录满足指定的优先级的事件,后续第一设备向第二设备读取事件时,读取到的事件即为满足上述指定的优先级的事件,从而实现了在事件记录的过程中,通过优先级对产生的事件进行过滤,提高了物联网系统中的事件记录以及获取的灵活性。To sum up, according to the solution shown in the embodiment of the present application, the first device can instruct the second device to record events that meet the specified priority when recording events. Subsequently, when the first device reads events from the second device, it reads The retrieved events are those that meet the above-specified priority. This enables filtering of generated events by priority during the event recording process, improving the flexibility of event recording and acquisition in the Internet of Things system.
请参考图17,其示出了本申请一个实施例提供的计算机设备1700的结构示意图。该计算机设备1700可以包括:处理器1701、接收器1702、发射器1703、存储器1704和总线1705。Please refer to Figure 17, which shows a schematic structural diagram of a computer device 1700 provided by an embodiment of the present application. The computer device 1700 may include a processor 1701, a receiver 1702, a transmitter 1703, a memory 1704, and a bus 1705.
处理器1701包括一个或者一个以上处理核心,处理器1701通过运行软件程序以及模块,从而执行各种功能应用以及信息处理。The processor 1701 includes one or more processing cores. The processor 1701 executes various functional applications and information processing by running software programs and modules.
接收器1702和发射器1703可以实现为一个通信组件,该通信组件可以是一块通信芯片。该通信芯片也可以称为收发器。The receiver 1702 and the transmitter 1703 can be implemented as a communication component, and the communication component can be a communication chip. This communication chip can also be called a transceiver.
存储器1704通过总线1705与处理器1701相连。 Memory 1704 is connected to processor 1701 through bus 1705.
存储器1704可用于存储计算机程序,处理器1701用于执行该计算机程序,以实现上述方法实施例中的各个步骤。The memory 1704 can be used to store a computer program, and the processor 1701 is used to execute the computer program to implement various steps in the above method embodiments.
此外,存储器1704可以由任何类型的易失性或非易失性存储设备或者它们的组合实现,易失性或非易失性存储设备包括但不限于:磁盘或光盘,电可擦除可编程只读存储器,可擦除可编程只读存储器,静态随时存取存储器,只读存储器,磁存储器,快闪存储器,可编程只读存储器。Additionally, memory 1704 may be implemented by any type of volatile or non-volatile storage device, or combination thereof, including but not limited to: magnetic or optical disks, electrically erasable programmable Read-only memory, erasable programmable read-only memory, static ready-access memory, read-only memory, magnetic memory, flash memory, programmable read-only memory.
其中,上述计算机设备1700中的处理器和/或收发器执行的过程可以参考上述图3、图4、图6、图8、图9或图11任一所示的方法中,由第一设备或者第二设备执行的各个步骤。Wherein, the process performed by the processor and/or transceiver in the computer device 1700 may refer to the method shown in any one of the above-mentioned FIG. 3, FIG. 4, FIG. 6, FIG. 8, FIG. 9 or FIG. 11, by the first device. or individual steps performed by the second device.
本申请实施例还提供了一种计算机可读存储介质,所述存储介质中存储有计算机程序,所述计算机程序由处理器加载并执行以实现上述图3、图4、图6、图8、图9或图11任一所示的方法中,由第一设备或者第二设备执行的各个步骤。Embodiments of the present application also provide a computer-readable storage medium. A computer program is stored in the storage medium. The computer program is loaded and executed by a processor to implement the above-mentioned Figures 3, 4, 6, and 8. In the method shown in either Figure 9 or Figure 11, each step is performed by the first device or the second device.
本申请还提供了一种芯片,该芯片用于在计算机设备中运行,以使得计算机设备执行上述图3、图4、图6、图8、图9或图11任一所示的方法中,由第一设备或者第二设备执行的各个步骤。This application also provides a chip, which is used to run in a computer device, so that the computer device executes the method shown in any one of the above-mentioned Figure 3, Figure 4, Figure 6, Figure 8, Figure 9 or Figure 11, Various steps performed by the first device or the second device.
本申请还提供了一种计算机程序产品,该计算机程序产品或计算机程序包括计算机指令,该计算机指令存储在计算机可读存储介质中。计算机设备的处理器从计算机可读存储介质读取该计算机指令,处理器执行该计算机指令,使得计算机设备执行上述图3、图4、图6、图8、图9或图11任一所示的方法中,由第一设备或者第二设备执行的各个步骤。The application also provides a computer program product, which computer program product or computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, causing the computer device to execute any one of the above figures 3, 4, 6, 8, 9 or 11. In the method, each step is performed by the first device or the second device.
本申请还提供了一种计算机程序,该计算机程序由计算机设备的处理器执行,以实现上述图3、图4、图6、图8、图9或图11任一所示的方法中,由第一设备或者第二设备执行的各个步骤。This application also provides a computer program, which is executed by the processor of the computer device to implement the method shown in any one of the above-mentioned Figure 3, Figure 4, Figure 6, Figure 8, Figure 9 or Figure 11, by Various steps performed by the first device or the second device.

Claims (45)

  1. 一种事件管理方法,其特征在于,所述方法由第一设备执行,所述方法包括:An event management method, characterized in that the method is executed by a first device, and the method includes:
    向第二设备发送事件获取请求;所述事件获取请求中包含第一目标事件优先级;Send an event acquisition request to the second device; the event acquisition request includes the first target event priority;
    接收所述第二设备发送的,与所述第一目标事件优先级匹配的至少一个目标事件。Receive at least one target event sent by the second device that matches the priority of the first target event.
  2. 根据权利要求1所述的方法,其特征在于,所述第一目标事件优先级设置在所述事件获取请求的事件过滤信息块中。The method according to claim 1, characterized in that the first target event priority is set in the event filtering information block of the event acquisition request.
  3. 根据权利要求1或2所述的方法,其特征在于,The method according to claim 1 or 2, characterized in that,
    至少一个所述目标事件包括优先级高于或者等于所述第一目标事件优先级的事件;At least one of the target events includes an event with a priority higher than or equal to the priority of the first target event;
    或者,or,
    至少一个所述目标事件包括优先级等于所述第一目标事件优先级的事件。At least one of the target events includes an event with a priority equal to the priority of the first target event.
  4. 根据权利要求1至3任一所述的方法,其特征在于,所述向第二设备发送事件获取请求之前,还包括:The method according to any one of claims 1 to 3, characterized in that before sending the event acquisition request to the second device, it further includes:
    接收优先级设置指令;Receive priority setting instructions;
    根据所述优先级设置指令设置所述第一目标事件优先级。The first target event priority is set according to the priority setting instruction.
  5. 根据权利要求1至4任一所述的方法,其特征在于,所述事件获取请求包括事件订阅请求或者事件读取请求。The method according to any one of claims 1 to 4, characterized in that the event acquisition request includes an event subscription request or an event reading request.
  6. 根据权利要求1至5任一所述的方法,其特征在于,所述第一设备和所述第二设备之间基于Matter协议建立连接;The method according to any one of claims 1 to 5, characterized in that a connection is established between the first device and the second device based on the Matter protocol;
    所述第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
    所述第二设备记录的事件是对应所述第二设备中的目标群集记录的事件。The events recorded by the second device are events recorded corresponding to the target cluster in the second device.
  7. 一种事件管理方法,其特征在于,所述方法由第二设备执行,所述方法包括:An event management method, characterized in that the method is executed by a second device, and the method includes:
    接收第一设备发送的事件获取请求;所述事件获取请求中包含第一目标事件优先级;Receive an event acquisition request sent by the first device; the event acquisition request includes the first target event priority;
    向所述第一设备发送与所述第一目标事件优先级匹配的至少一个目标事件。At least one target event matching the priority of the first target event is sent to the first device.
  8. 根据权利要求7所述的方法,其特征在于,所述第一目标事件优先级设置在所述事件获取请求的事件过滤信息块中。The method according to claim 7, characterized in that the first target event priority is set in the event filtering information block of the event acquisition request.
  9. 根据权利要求7或8所述的方法,其特征在于,The method according to claim 7 or 8, characterized in that,
    至少一个所述目标事件包括优先级高于或者等于所述第一目标事件优先级的事件;At least one of the target events includes an event with a priority higher than or equal to the priority of the first target event;
    或者,or,
    至少一个所述目标事件包括优先级等于所述第一目标事件优先级的事件。At least one of the target events includes an event with a priority equal to the priority of the first target event.
  10. 根据权利要求7至9任一所述的方法,其特征在于,所述事件获取请求包括事件订阅请求或者事件读取请求。The method according to any one of claims 7 to 9, characterized in that the event acquisition request includes an event subscription request or an event reading request.
  11. 根据权利要求7至10任一所述的方法,其特征在于,所述第一设备和所述第二设备之间基于Matter协议建立连接;The method according to any one of claims 7 to 10, characterized in that a connection is established between the first device and the second device based on the Matter protocol;
    所述第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及 重要CRITICAL优先级中的至少两种;The priority of the event recorded by the second device includes at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
    所述第二设备记录的事件是对应所述第二设备中的目标群集记录的事件。The events recorded by the second device are events recorded corresponding to the target cluster in the second device.
  12. 一种事件管理方法,其特征在于,所述方法由第一设备执行,所述方法包括:An event management method, characterized in that the method is executed by a first device, and the method includes:
    向第二设备发送事件优先级设置请求;所述事件优先级设置请求中包含第二目标事件优先级;所述事件优先级设置请求用于指示所述第二设备记录与所述第二目标事件优先级匹配的至少一个目标事件。Send an event priority setting request to the second device; the event priority setting request includes a second target event priority; the event priority setting request is used to instruct the second device to record the event related to the second target event. At least one target event whose priority matches.
  13. 根据权利要求12所述的方法,其特征在于,所述第二目标事件优先级包括写属性指令;所述写属性指令用于指示所述第二设备在目标群集中写入与所述第二目标事件优先级对应的事件优先级属性。The method of claim 12, wherein the second target event priority includes a write attribute instruction; the write attribute instruction is used to instruct the second device to write the same content as the second device in the target cluster. The event priority attribute corresponding to the target event priority.
  14. 根据权利要求12或13所述的方法,其特征在于,The method according to claim 12 or 13, characterized in that,
    至少一个所述第二目标事件包括优先级高于或者等于所述第二目标事件优先级的事件;At least one of the second target events includes an event with a priority higher than or equal to the priority of the second target event;
    或者,or,
    至少一个所述目标事件包括优先级等于所述第二目标事件优先级的事件。At least one of the target events includes an event with a priority equal to the priority of the second target event.
  15. 根据权利要求12至14任一所述的方法,其特征在于,所述向第二设备发送事件优先级设置请求之前,还包括:The method according to any one of claims 12 to 14, characterized in that before sending the event priority setting request to the second device, it further includes:
    接收优先级设置指令;Receive priority setting instructions;
    根据所述优先级设置指令设置所述第二目标事件优先级。The second target event priority is set according to the priority setting instruction.
  16. 根据权利要求12至15任一所述的方法,其特征在于,所述第一设备和所述第二设备之间基于Matter协议建立连接;The method according to any one of claims 12 to 15, characterized in that a connection is established between the first device and the second device based on the Matter protocol;
    所述第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
    所述第二设备记录的事件是对应所述第二设备中的目标群集记录的事件。The events recorded by the second device are events recorded corresponding to the target cluster in the second device.
  17. 一种事件管理方法,其特征在于,所述方法由第二设备执行,所述方法包括:An event management method, characterized in that the method is executed by a second device, and the method includes:
    接收第一设备发送的事件优先级设置请求;所述事件优先级设置请求中包含第二目标事件优先级;Receive an event priority setting request sent by the first device; the event priority setting request includes the second target event priority;
    根据所述事件优先级设置信息,记录与所述第二目标事件优先级匹配的至少一个目标事件。According to the event priority setting information, at least one target event matching the second target event priority is recorded.
  18. 根据权利要求17所述的方法,其特征在于,所述第二目标事件优先级包括写属性指令;The method of claim 17, wherein the second target event priority includes a write attribute instruction;
    所述根据所述事件优先级设置信息,记录与所述第二目标事件优先级匹配的至少一个目标事件之前,还包括:Before recording at least one target event matching the second target event priority according to the event priority setting information, the method further includes:
    在目标群集中写入与所述第二目标事件优先级对应的事件优先级属性;Write an event priority attribute corresponding to the second target event priority in the target cluster;
    所述根据所述事件优先级设置信息,记录与所述第二目标事件优先级匹配的至少一个目标事件,包括:Recording at least one target event matching the second target event priority according to the event priority setting information includes:
    当所述目标群集产生第一事件,且所述第一事件与所述事件优先级属性匹配时,将所述第一事件记录为所述目标群集的一条所述目标事件。When the target cluster generates a first event and the first event matches the event priority attribute, the first event is recorded as one of the target events of the target cluster.
  19. 根据权利要求17或18所述的方法,其特征在于,The method according to claim 17 or 18, characterized in that,
    至少一个所述目标事件包括优先级高于或者等于所述第二目标事件优先级的事件;At least one of the target events includes an event with a priority higher than or equal to the priority of the second target event;
    或者,or,
    至少一个所述目标事件包括优先级等于所述第二目标事件优先级的事件。At least one of the target events includes an event with a priority equal to the priority of the second target event.
  20. 根据权利要求17至19任一所述的方法,其特征在于,所述第一设备和所述第二设备之间基于Matter协议建立连接;The method according to any one of claims 17 to 19, characterized in that a connection is established between the first device and the second device based on the Matter protocol;
    所述第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
    所述第二设备记录的事件是对应所述第二设备中的目标群集记录的事件。The events recorded by the second device are events recorded corresponding to the target cluster in the second device.
  21. 一种事件管理装置,其特征在于,所述装置包括:An event management device, characterized in that the device includes:
    发送模块,用于向第二设备发送事件获取请求;所述事件获取请求中包含第一目标事件优先级;A sending module, configured to send an event acquisition request to the second device; the event acquisition request includes the first target event priority;
    接收模块,用于接收所述第二设备发送的,与所述第一目标事件优先级匹配的至少一个目标事件。A receiving module configured to receive at least one target event sent by the second device that matches the priority of the first target event.
  22. 根据权利要求21所述的装置,其特征在于,所述第一目标事件优先级设置在所述事件获取请求的事件过滤信息块中。The device according to claim 21, characterized in that the first target event priority is set in the event filtering information block of the event acquisition request.
  23. 根据权利要求21或22所述的装置,其特征在于,The device according to claim 21 or 22, characterized in that:
    至少一个所述目标事件包括优先级高于或者等于所述第一目标事件优先级的事件;At least one of the target events includes an event with a priority higher than or equal to the priority of the first target event;
    或者,or,
    至少一个所述目标事件包括优先级等于所述第一目标事件优先级的事件。At least one of the target events includes an event with a priority equal to the priority of the first target event.
  24. 根据权利要求21至23任一所述的装置,其特征在于,所述装置还包括:The device according to any one of claims 21 to 23, characterized in that the device further includes:
    指令接收模块,用于在所述发送模块向第二设备发送事件获取请求之前,接收优先级设置指令;An instruction receiving module, configured to receive a priority setting instruction before the sending module sends an event acquisition request to the second device;
    设置模块,用于根据所述优先级设置指令设置所述第一目标事件优先级。A setting module configured to set the first target event priority according to the priority setting instruction.
  25. 根据权利要求21至24任一所述的装置,其特征在于,所述事件获取请求包括事件订阅请求或者事件读取请求。The device according to any one of claims 21 to 24, wherein the event acquisition request includes an event subscription request or an event reading request.
  26. 根据权利要求21至25任一所述的方法,其特征在于,所述第一设备和所述第二设备之间基于Matter协议建立连接;The method according to any one of claims 21 to 25, characterized in that a connection is established between the first device and the second device based on the Matter protocol;
    所述第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
    所述第二设备记录的事件是对应所述第二设备中的目标群集记录的事件。The events recorded by the second device are events recorded corresponding to the target cluster in the second device.
  27. 一种事件管理装置,其特征在于,所述装置包括:An event management device, characterized in that the device includes:
    接收模块,用于接收第一设备发送的事件获取请求;所述事件获取请求中包含第一目标事件优先级;A receiving module, configured to receive an event acquisition request sent by the first device; the event acquisition request includes the first target event priority;
    发送模块,用于向所述第一设备发送与所述第一目标事件优先级匹配的至少一个目标事件。A sending module configured to send at least one target event matching the priority of the first target event to the first device.
  28. 根据权利要求27所述的装置,其特征在于,所述第一目标事件优先级设置在所述事件获取请求的事件过滤信息块中。The device according to claim 27, characterized in that the first target event priority is set in an event filtering information block of the event acquisition request.
  29. 根据权利要求27或28所述的装置,其特征在于,The device according to claim 27 or 28, characterized in that:
    至少一个所述目标事件包括优先级高于或者等于所述第一目标事件优先级的事件;At least one of the target events includes an event with a priority higher than or equal to the priority of the first target event;
    或者,or,
    至少一个所述目标事件包括优先级等于所述第一目标事件优先级的事件。At least one of the target events includes an event with a priority equal to the priority of the first target event.
  30. 根据权利要求27至29任一所述的装置,其特征在于,所述事件获取请求包括事件订阅请求或者事件读取请求。The device according to any one of claims 27 to 29, characterized in that the event acquisition request includes an event subscription request or an event reading request.
  31. 根据权利要求27至30任一所述的方法,其特征在于,所述第一设备和所述第二设备之间基于Matter协议建立连接;The method according to any one of claims 27 to 30, characterized in that a connection is established between the first device and the second device based on the Matter protocol;
    所述第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
    所述第二设备记录的事件是对应所述第二设备中的目标群集记录的事件。The events recorded by the second device are events recorded corresponding to the target cluster in the second device.
  32. 一种事件管理装置,其特征在于,所述装置包括:An event management device, characterized in that the device includes:
    发送模块,用于向第二设备发送事件优先级设置请求;所述事件优先级设置请求中包含第二目标事件优先级;所述事件优先级设置请求用于指示所述第二设备记录与所述第二目标事件优先级匹配的至少一个目标事件。A sending module, configured to send an event priority setting request to the second device; the event priority setting request includes a second target event priority; the event priority setting request is used to instruct the second device to record the At least one target event whose priority matches the second target event.
  33. 根据权利要求32所述的装置,其特征在于,所述第二目标事件优先级包括写属性指令;所述写属性指令用于指示所述第二设备在目标群集中写入与所述第二目标事件优先级对应的事件优先级属性。The apparatus of claim 32, wherein the second target event priority includes a write attribute instruction; the write attribute instruction is used to instruct the second device to write the same information as the second device in the target cluster. The event priority attribute corresponding to the target event priority.
  34. 根据权利要求32或33所述的装置,其特征在于,The device according to claim 32 or 33, characterized in that:
    至少一个所述目标事件包括优先级高于或者等于所述第二目标事件优先级的事件;At least one of the target events includes an event with a priority higher than or equal to the priority of the second target event;
    或者,or,
    至少一个所述目标事件包括优先级等于所述第二目标事件优先级的事件。At least one of the target events includes an event with a priority equal to the priority of the second target event.
  35. 根据权利要求32至34任一所述的装置,其特征在于,所述装置还包括:The device according to any one of claims 32 to 34, characterized in that the device further includes:
    指令接收模块,用于在所述发送模块向第二设备发送事件优先级设置请求之前,接收优先级设置指令;An instruction receiving module, configured to receive a priority setting instruction before the sending module sends an event priority setting request to the second device;
    设置模块,用于根据所述优先级设置指令设置所述第二目标事件优先级。A setting module configured to set the second target event priority according to the priority setting instruction.
  36. 根据权利要求32至35任一所述的方法,其特征在于,所述第一设备和所述第二设备之间基于Matter协议建立连接;The method according to any one of claims 32 to 35, characterized in that a connection is established between the first device and the second device based on the Matter protocol;
    所述第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
    所述第二设备记录的事件是对应所述第二设备中的目标群集记录的事件。The events recorded by the second device are events recorded corresponding to the target cluster in the second device.
  37. 一种事件管理装置,其特征在于,所述装置包括:An event management device, characterized in that the device includes:
    接收模块,用于接收第一设备发送的事件优先级设置请求;所述事件优先级设置请求中包含第二目标事件优先级;A receiving module configured to receive an event priority setting request sent by the first device; the event priority setting request includes the second target event priority;
    记录模块,用于根据所述事件优先级设置信息,记录与所述第二目标事件优先级匹配的至少一个目标事件。A recording module configured to record at least one target event matching the second target event priority according to the event priority setting information.
  38. 根据权利要求37所述的装置,其特征在于,所述第二目标事件优先级包括写属性指 令;The device according to claim 37, wherein the second target event priority includes a write attribute instruction;
    所述装置还包括:The device also includes:
    属性写入模块,用于在所述记录模块根据所述事件优先级设置信息,记录与所述第二目标事件优先级匹配的至少一个目标事件之前,在目标群集中写入与所述第二目标事件优先级对应的事件优先级属性;An attribute writing module, configured to write the second target event in the target cluster before the recording module records at least one target event matching the second target event priority according to the event priority setting information. The event priority attribute corresponding to the target event priority;
    所述记录模块,用于当所述目标群集产生第一事件,且所述第一事件与所述事件优先级属性匹配时,将所述第一事件记录为所述目标群集的一条所述目标事件。The recording module is configured to, when the target cluster generates a first event and the first event matches the event priority attribute, record the first event as a target item of the target cluster. event.
  39. 根据权利要求37或38所述的装置,其特征在于,The device according to claim 37 or 38, characterized in that,
    至少一个所述目标事件包括优先级高于或者等于所述第二目标事件优先级的事件;At least one of the target events includes an event with a priority higher than or equal to the priority of the second target event;
    或者,or,
    至少一个所述目标事件包括优先级等于所述第二目标事件优先级的事件。At least one of the target events includes an event with a priority equal to the priority of the second target event.
  40. 根据权利要求37至39任一所述的方法,其特征在于,所述第一设备和所述第二设备之间基于Matter协议建立连接;The method according to any one of claims 37 to 39, characterized in that a connection is established between the first device and the second device based on the Matter protocol;
    所述第二设备记录的事件的优先级包括调试DEBUG优先级、信息INFO优先级、以及重要CRITICAL优先级中的至少两种;The priorities of events recorded by the second device include at least two of debugging DEBUG priority, information INFO priority, and important CRITICAL priority;
    所述第二设备记录的事件是对应所述第二设备中的目标群集记录的事件。The events recorded by the second device are events recorded corresponding to the target cluster in the second device.
  41. 一种计算机设备,其特征在于,所述计算机设备包括处理器、存储器和收发器;A computer device, characterized in that the computer device includes a processor, a memory and a transceiver;
    所述存储器中存储有计算机程序,所述处理器执行所述计算机程序,以使得所述计算机设备实现如上述权利要求1至20任一所述的事件管理方法。A computer program is stored in the memory, and the processor executes the computer program, so that the computer device implements the event management method as described in any one of claims 1 to 20.
  42. 一种计算机可读存储介质,其特征在于,所述存储介质中存储有计算机程序,所述计算机程序用于被处理器执行,以实现如权利要求1至20任一所述的安全域管理方法。A computer-readable storage medium, characterized in that a computer program is stored in the storage medium, and the computer program is used to be executed by a processor to implement the security domain management method as described in any one of claims 1 to 20 .
  43. 一种芯片,其特征在于,所述芯片用于在计算机设备中运行,以使得所述计算机设备执行如权利要求1至20任一所述的事件管理方法。A chip, characterized in that the chip is used to run in a computer device, so that the computer device executes the event management method according to any one of claims 1 to 20.
  44. 一种计算机程序产品,其特征在于,所述计算机程序产品包括计算机指令,所述计算机指令存储在计算机可读存储介质中;计算机设备的处理器从所述计算机可读存储介质读取所述计算机指令,并执行所述计算机指令,使得所述计算机设备执行如权利要求1至20任一所述的事件管理方法。A computer program product, characterized in that the computer program product includes computer instructions, and the computer instructions are stored in a computer-readable storage medium; and a processor of a computer device reads the computer instructions from the computer-readable storage medium. instructions, and execute the computer instructions, so that the computer device executes the event management method according to any one of claims 1 to 20.
  45. 一种计算机程序,其特征在于,所述计算机程序由计算机设备的处理器执行,以实现如权利要求1至20任一所述的事件管理方法。A computer program, characterized in that the computer program is executed by a processor of a computer device to implement the event management method as claimed in any one of claims 1 to 20.
PCT/CN2022/091579 2022-05-08 2022-05-08 Event management method and apparatus, device, storage medium, and program product WO2023216042A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2022/091579 WO2023216042A1 (en) 2022-05-08 2022-05-08 Event management method and apparatus, device, storage medium, and program product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2022/091579 WO2023216042A1 (en) 2022-05-08 2022-05-08 Event management method and apparatus, device, storage medium, and program product

Publications (1)

Publication Number Publication Date
WO2023216042A1 true WO2023216042A1 (en) 2023-11-16

Family

ID=88729446

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/091579 WO2023216042A1 (en) 2022-05-08 2022-05-08 Event management method and apparatus, device, storage medium, and program product

Country Status (1)

Country Link
WO (1) WO2023216042A1 (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090164718A1 (en) * 2007-12-21 2009-06-25 Fujitsu Limited Disk array device control method
JP2009282585A (en) * 2008-05-19 2009-12-03 Fujitsu Ltd Log level change system
CN103793479A (en) * 2014-01-14 2014-05-14 上海上讯信息技术股份有限公司 Log management method and log management system
CN108259241A (en) * 2018-01-11 2018-07-06 上海有云信息技术有限公司 A kind of abnormal localization method and device of cloud platform monitoring system
CN108804295A (en) * 2017-04-28 2018-11-13 北京京东尚科信息技术有限公司 log information recording method and device
CN108846070A (en) * 2018-06-07 2018-11-20 北京京东尚科信息技术有限公司 Log processing method, system, electronic equipment and the storage medium of distributed system
CN109977089A (en) * 2019-03-13 2019-07-05 深圳壹账通智能科技有限公司 Blog management method, device, computer equipment and computer readable storage medium
CN113204533A (en) * 2021-05-28 2021-08-03 平安国际智慧城市科技股份有限公司 Log level adjusting method and device, computer equipment and storage medium

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090164718A1 (en) * 2007-12-21 2009-06-25 Fujitsu Limited Disk array device control method
JP2009282585A (en) * 2008-05-19 2009-12-03 Fujitsu Ltd Log level change system
CN103793479A (en) * 2014-01-14 2014-05-14 上海上讯信息技术股份有限公司 Log management method and log management system
CN108804295A (en) * 2017-04-28 2018-11-13 北京京东尚科信息技术有限公司 log information recording method and device
CN108259241A (en) * 2018-01-11 2018-07-06 上海有云信息技术有限公司 A kind of abnormal localization method and device of cloud platform monitoring system
CN108846070A (en) * 2018-06-07 2018-11-20 北京京东尚科信息技术有限公司 Log processing method, system, electronic equipment and the storage medium of distributed system
CN109977089A (en) * 2019-03-13 2019-07-05 深圳壹账通智能科技有限公司 Blog management method, device, computer equipment and computer readable storage medium
CN113204533A (en) * 2021-05-28 2021-08-03 平安国际智慧城市科技股份有限公司 Log level adjusting method and device, computer equipment and storage medium

Similar Documents

Publication Publication Date Title
US10477158B2 (en) System and method for a security system
US20100023867A1 (en) Systems and methods for filtering network diagnostic statistics
US20180084085A1 (en) Cross platform device virtualization for an iot system
US20080178198A1 (en) Distributed digital media management
CN113508403A (en) System and method for interoperable communication of automation system components with multiple information sources
US9917867B2 (en) Conducting online meetings with intelligent environment configuration
CN109542583B (en) Virtual equipment management method based on double buses
CN112835968A (en) Intelligent equipment linkage method based on Internet of things
US20220030090A1 (en) Selective address space aggregation
CN109361579A (en) A kind of smart machine control method, system and storage medium
WO2023216042A1 (en) Event management method and apparatus, device, storage medium, and program product
CN103198041A (en) Method for establishing IEC61970 GID (general interface definition) interface
WO2018113184A1 (en) Intelligent device control and management method based on forces protocol
CN113076229A (en) Universal enterprise-level information technology monitoring system
US11177977B2 (en) Method and system for GRE tunnel control based on client activity detection
CN103873297A (en) Processing method for reverse inheritance modeling of data acquisition and processing system
US20230045914A1 (en) Method and apparatus for controlling device in internet of things, and gateway device and storage medium
CN108092959B (en) BACnet protocol analysis method based on configuration
CN109116815A (en) One kind is based on MQTT injection molding machine management system, method and storage medium
WO2011131078A1 (en) Data management method and system for field bus instrument management system
CN116743790A (en) Device data acquisition, device data analysis method and device and computer device
WO2023065354A1 (en) Information reporting method and apparatus, and device and storage medium
WO2022041280A1 (en) Method and apparatus for generating file in internet of things, computer device, and storage medium
WO2023201587A1 (en) Device control method and apparatus, device, and storage medium
WO2024065091A1 (en) Method for device capability discovery, server device, and client device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22941011

Country of ref document: EP

Kind code of ref document: A1