WO2012174987A1 - Terminal management method and device - Google Patents
Terminal management method and device Download PDFInfo
- Publication number
- WO2012174987A1 WO2012174987A1 PCT/CN2012/076478 CN2012076478W WO2012174987A1 WO 2012174987 A1 WO2012174987 A1 WO 2012174987A1 CN 2012076478 W CN2012076478 W CN 2012076478W WO 2012174987 A1 WO2012174987 A1 WO 2012174987A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- operation command
- gateway
- execution result
- target terminal
- server
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/12—Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
- H04L67/125—Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks involving control of end-device applications over a network
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/24—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks using dedicated network management hardware
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W4/00—Services specially adapted for wireless communication networks; Facilities therefor
- H04W4/50—Service provisioning or reconfiguring
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/06—Management of faults, events, alarms or notifications
- H04L41/069—Management of faults, events, alarms or notifications using logs of notifications; Post-processing of notifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W4/00—Services specially adapted for wireless communication networks; Facilities therefor
- H04W4/18—Information format or content conversion, e.g. adaptation by the network of the transmitted or received information for the purpose of wireless delivery to users or terminals
Definitions
- the present invention claims the priority of the Chinese Patent Application entitled “Method and Apparatus for Managing Terminals", filed on June 22, 2011 by the Chinese Patent Office, Application No. 201110169708.6 In this application.
- the present invention relates to the field of communications, and in particular, to a method and apparatus for managing a terminal.
- OMA Open Mobile Architecture
- VI.3 Design Management, Device Management
- the DM system provides a low-cost solution for third-party management and setting of environment and configuration information in the terminal device to solve problems encountered during the use of these devices, such as through OTA (over the air) Install and upgrade software and firmware, and provide more personalized and personalized services to enhance the user experience.
- the DM system includes a DM client (DM client) on the terminal device, a device management tree stored on the terminal device, and a DM server; the DM client is used to interpret and execute the management command delivered by the DM server; It is considered as an interface for the DM server to manage the terminal device.
- the DM server communicates with the DM client in the terminal device through the DM protocol to implement management of the terminal device.
- a GW Gateway, Gateway
- the GwMO framework describes the DM management server through the gateway to the intranet.
- the DM server, gateway, and terminal all conform to the specifications of the 0MA DM.
- the protocol defines three working modes of the gateway for different management scenarios and management policies: Transparent Mode, Proxy Mode, and Adaptation Mode.
- the DM Gateway gateway After the introduction of the DM Gateway gateway device, if the gateway works in proxy mode, that is, between the DM server (DMS) and the DM Gateway (DM Gateway), the DM Gateway maintains a DM session with the device, and When sending device management commands to one or more terminals at the same time, you need to use the Fanout (bulk fanout) mechanism. This Fanout M0 management object is saved in the DM network. On the DM Ga teway.
- the inventor finds that at least the following problems exist in the prior art: the number of results returned by the terminal through the gateway is large, and there is no unified representation of each result, and the server needs to process the terminal result one by one, so that The efficiency of the server is very low.
- Embodiments of the present invention provide a method and apparatus for managing a terminal, which improves the efficiency of a server processing terminal to execute an operation command result.
- a method of managing a terminal comprising:
- the gateway Sending, to the gateway, operation information for performing a management operation on the target terminal, where the operation information carries a return form of an operation command execution result of performing a management operation on the target terminal, so that the gateway performs an operation command returned by the target terminal
- the result is returned to the server according to the return form;
- the return form is an indication message indicating how the gateway groups the operation command execution result of the target terminal, and receives an operation command execution result that is sent by the gateway and conforms to the return form.
- a method of managing a terminal comprising:
- An operation command execution result conforming to the return form is transmitted to the server.
- a server comprising:
- a first sending unit configured to send, to the gateway, operation information for performing a management operation on the target terminal, where the operation information carries a return form of an operation command execution result of performing a management operation on the target terminal, so that the gateway The operation command execution result returned by the target terminal is in accordance with the return shape Returning to the server;
- the return form is indication information indicating how the gateway groups the operation command execution result of the target terminal;
- a first receiving unit configured to receive an operation command execution result that is sent by the gateway and meets the return form.
- a gateway including:
- a first receiving unit configured to receive, by the server, operation information for performing a management operation on the target terminal
- a first sending unit configured to send, according to the operation information received by the first receiving unit, a corresponding operation command to the target terminal
- a second receiving unit configured to receive an operation command execution result of the operation command sent by the target terminal
- An operation unit configured to process, according to the returned form of the executed operation command execution result, the execution result of the operation command received by the second receiving unit, when the operation command execution result has an indication of a return form, Comply with the execution result of the return form;
- a second sending unit configured to send, by the operating unit, an operation command execution result that conforms to the return form to the server.
- the method and device for managing a terminal when the operation information of the management operation of the target terminal is sent to the gateway, the operation information carries the operation command execution result of the management operation of the target terminal Returning form; after the gateway receives the operation command execution result sent by the target terminal, when the operation command execution result has an indication of a return form, processing the execution result of the operation command according to the return form, and obtaining the Returning a result of the operation command execution of the form, and transmitting the execution result of the operation command conforming to the return form to the server; enabling the service to process the result of the execution of the operation command according to the return form of the execution result of the operation command
- the execution result of the class is batch processed; compared with the processing result of the server processing the processing result one by one in the prior art, the efficiency of the server processing terminal executing the operation command result is improved.
- FIG. 1 is a flowchart of a method for managing a terminal according to an embodiment of the present invention
- FIG. 2 is a flowchart of another method for managing a terminal according to an embodiment of the present invention.
- FIG. 3 is a schematic structural diagram of an operation command management tree according to an embodiment of the present invention.
- FIG. 4 is a flowchart of another method for managing a terminal according to an embodiment of the present invention.
- FIG. 5 is a schematic structural diagram of another operation command management tree according to an embodiment of the present invention.
- FIG. 6 is a schematic structural diagram of another operation command management tree according to an embodiment of the present invention.
- FIG. 7 is a flowchart of another method for managing a terminal according to an embodiment of the present invention.
- FIG. 8 is a flowchart of another method for managing a terminal according to an embodiment of the present invention.
- FIG. 9 is a block diagram showing the composition of a server according to an embodiment of the present invention.
- FIG. 10 is a block diagram showing the composition of another server in the embodiment of the present invention.
- FIG. 11 is a block diagram showing the composition of another server according to an embodiment of the present invention.
- FIG. 12 is a block diagram showing the composition of another server according to an embodiment of the present invention.
- FIG. 13 is a structural block diagram of another server according to an embodiment of the present invention.
- FIG. 14 is a structural block diagram of a gateway according to an embodiment of the present invention.
- FIG. 15 is a block diagram of another gateway in an embodiment of the present invention.
- 16 is a block diagram of another gateway in an embodiment of the present invention.
- 17 is a block diagram of another gateway in an embodiment of the present invention.
- FIG. 18 is a block diagram of another gateway in an embodiment of the present invention.
- FIG. 19 is a block diagram of another gateway in an embodiment of the present invention.
- 20 is a block diagram of another gateway in an embodiment of the present invention.
- FIG. 21 is a structural block diagram of a system for managing a terminal according to an embodiment of the present invention.
- An embodiment of the present invention provides a method for managing a terminal, where the method is a server-side method, as shown in FIG. 1, the method includes:
- the server sends, to the gateway, operation information for performing a management operation on the target terminal, where the operation information carries a return form of an operation command execution result of performing a management operation on the target terminal, so that the gateway returns the target terminal.
- the operation command execution result is returned to the server according to the return form, and the return form is indication information indicating how the gateway groups the operation command execution result of the target terminal.
- the return form of the operation command execution result includes a type and a quantity limit of the return form:
- the type of the return form includes: a loose grouping mode and a strict matching grouping mode, which can be represented by parameters, and the parameter can be Prof ile
- the parameter, which defines the return form of the execution result of the operation command may specifically be "1" for the loose grouping mode and "2" for the strict matching grouping mode.
- the quantity limit of the return form includes: returning the execution result of one operation command, returning the execution result of the two operation commands, and returning the execution result of the two or more operation commands; it may also be defined by the parameter form, For example, it can be defined by the ResGroup parameter. Specifically, "1" means returning the execution result of an operation command; “2” means returning the execution result of the two operation commands; "3" means calling the operation command of two or more operations. The result of the execution is returned.
- the returning form of the operation command execution result of the management operation on the target terminal may be carried, or may not be carried.
- Return of the operation command execution result of the management operation of the target terminal The form is not limited by the embodiment of the present invention, and is set according to user requirements; however, the completion of the operation command output returned by the target terminal by the gateway is returned to the server according to the return form, and the operation information must be carried in the pair. The return form of the operation command execution result of the management operation of the target terminal.
- the server receives an operation command execution result that is sent by the gateway and conforms to the return form.
- the embodiment of the present invention further provides a method for managing a terminal, where the method is a gateway side method, as shown in FIG. 2, the method includes:
- the gateway receives operation information sent by the server for performing a management operation on the target terminal.
- the operation information may carry a return form of an operation command execution result of performing a management operation on the target terminal, or may not carry a return form of an operation command execution result of performing a management operation on the target terminal, The embodiment of the present invention does not limit this.
- the operation information carries the operation of performing the management operation on the target terminal.
- the return form of the command execution result is not limited to the user.
- the gateway under the GwMO framework works in the proxy mode, that is, between the DMS-GWs, and each GW-Device maintains a DM session, and simultaneously to one or both.
- Fanout M0 is saved on the Gateway.
- the nodes under the Fanout subtree function as follows: FanoutCommands is filled with DMS and is the management command for the terminal; TargetGroupRef corresponds to the group defined under the DevGroup subtree in the Conf ig M0 management object. The id of the group, the gateway finds the target terminal based on this id.
- Star t is an executable node, which is triggered by the DMS to fan out the FanoutCommands commands to the target terminal.
- the gateway expands the Fanout subtree to create a Para node. A return form corresponding to the execution result of the operation command is described in the Para node.
- the gateway sends a corresponding operation command to the target terminal according to the operation information, and receives an operation command execution result of the operation command sent by the target terminal.
- the specific operation of transmitting the corresponding operation command to the target terminal according to the operation information, and receiving the execution result of the operation command sent by the target terminal may be performed according to the description of the prior art, and the implementation of the present invention is implemented. The examples will not be described here.
- the gateway when the gateway sends a corresponding operation command to the target terminal according to the operation information, that is, when the S tar t node is operated, the Target node carries the Para node value.
- the return form used to inform the gateway of the execution result of the operation command.
- the gateway has the following ways to maintain the operation command, the operation command execution result, and the server correspondence, and specifically includes:
- the first type, the setting command table, the command table is as shown in Table 1, including: the server, Target device ID, operation command ID.
- the gateway can use the SourceRef tag to carry the operation command identifier in SynHdr when executing the operation command.
- “1295790618" is an operation command identifier.
- the gateway when the gateway executes the operation command, it can add a correlator to the SynBody to carry the operation command command identifier. For example, "1295790618" is an operation command identifier.
- the specific operations are as follows:
- the gateway processes the execution result of the operation command according to the returned form of the executed operation command execution result, and obtains an operation command that conforms to the return form. Results of the.
- the gateway sends an operation command execution result that meets the return form to the service. To meet the requirement of different users, after the gateway receives the operation command execution result sent by the target terminal, The method also includes:
- determining whether to store the specified operation command execution node in the gate When the gateway returns the form, when the gateway saves the return form specifying the execution result of the operation command in the form of a node, it is determined whether there is a node in the gateway that stores a return form specifying the execution result of the operation command;
- the embodiment of the present invention does not limit this, and other methods for saving the return form specifying the execution result of the operation command are also within the scope of protection of the embodiment of the present invention.
- the method further includes:
- the message may carry a grouping condition for grouping the target terminal corresponding to the execution result of the operation command, or may not carry a grouping condition for grouping the target terminal corresponding to the execution result of the operation command.
- the embodiment of the present invention does not limit this.
- the target device is grouped by the gateway to include 100 terminals, which is recorded as group 1; after the first server operation command is performed on the group 1 through the gateway, only 90 target terminals in the group 1 return the operation successfully. result.
- the gateway classifies the results according to the operation command and returns it to the server, 90 of which are successful; 10 fail. At this point, the server only needs to perform subsequent operations on 90 successful devices; Group 1 is no longer applicable.
- the server notifies the gateway to group the target terminals, and divides the 90 devices into groups 2 for subsequent operations.
- the gateway receives, by the server, a message that is grouped by the target terminal corresponding to the execution result of the operation command.
- the gateway groups, according to the message that the target terminal corresponding to the operation command execution result is grouped, the target terminal corresponding to the operation command execution result.
- the gateway according to the message that the target terminal corresponding to the execution result of the operation command is grouped, grouping the target terminal corresponding to the execution result of the operation command includes:
- the message for grouping the target terminal corresponding to the execution result of the operation command carries a grouping condition for grouping the target terminal corresponding to the execution result of the operation command
- the a message for grouping the target terminals corresponding to the execution result of the operation command, and grouping the target terminals corresponding to the execution result of the operation command into: grouping the target terminals corresponding to the execution result of the operation command according to the grouping condition .
- the operation command according to the pair a message that the target terminal corresponding to the execution result is grouped, and the target terminals corresponding to the execution result of the operation command are grouped into: grouping according to the execution result of the operation command, and each group includes a target terminal corresponding to the execution result of the same operation command .
- the result is sent to the server.
- the execution result includes a success or failure of the group.
- the server receives, by the gateway, an execution result of grouping the target terminal corresponding to the execution result of the operation command, so that the target terminal corresponding to the execution result of the operation command performs subsequent operations. For example, as shown in FIG. 5, the target terminal grouped with the operation command execution result group 2 continues to operate. You can execute Crea teGroup to regenerate new non-grouping information in the Conf i gMO object on the gateway management tree.
- the embodiment of the present invention further includes:
- the server sends, to the gateway, a grouping condition message for grouping the target terminal corresponding to the execution result of the operation command, where the packet conditional message carries the grouping of the target terminals corresponding to the execution result of the operation command. a grouping condition, so that the gateway groups the target terminals corresponding to the execution result of the operation command according to the grouping condition.
- the gateway receives the packet condition message sent by the server, and groups the target terminals corresponding to the execution result of the operation command according to the grouping condition.
- the gateway in the process of asynchronous transmission, if the gateway only receives the message that the target terminal corresponding to the operation command execution result is grouped, but does not receive the grouping condition information, the default is as follows.
- the operation command execution results are grouped, and each group includes the target terminal corresponding to the execution result of the same operation command.
- the server in order to implement asynchronous management, the server establishes and maintains a management operation table, and the management operation table includes at least the following information: an operation command number, an operation command name, a path of the target terminal, and an operation command execution result identifier. For example, as shown in Table 2,
- Operat is the operation command number
- Command is the operation command name
- Via is the path of the target terminal
- SetTime is the operation command execution result identifier
- mode is the mode in which the gateway executes the operation command
- To is the group in which the destination terminal is located.
- SetTime is an operation command execution result identifier, which indicates a unique operation command that is executed, and its representation is not limited to the above numbers.
- the server After the gateway executes the corresponding operation command, the server updates the predefined management operation table according to the operation command execution result.
- the embodiment of the present invention further includes:
- the operation information carries the validity period of the operation command or the validity period of the operation command and the mode in which the gateway executes the operation command, so that the The gateway deletes the expired operation command;
- the mode in which the gateway executes the operation command includes allowing the gateway to automatically execute when the operation command expires and does not allow the gateway to automatically execute when the operation command expires;
- the permission gateway automatically starts when the operation command expires Execution, indicating that when the operation command is executed by the gateway, if the execution instruction information of the operation command is not received by the server when the validity period of the operation command expires, the execution instruction information of the operation command is not required to be automatically
- the expired operation command is sent to the corresponding target terminal; the gateway is not allowed to automatically execute when the operation command expires
- the line indicates that when the operation command is executed by the gateway, if the execution instruction information of the operation command is not received by the server when the validity period of the operation command expires, the execution instruction information of the operation command is
- each gateway has its own MaxFanoutTime, which is used to indicate the time when a Fanout object of the gateway exists.
- MaxFanoutTime When the server configures the Fanout object, it also presents a value, which is called TimeOut, which is used to represent The time at which a Fanout operation command exists. Therefore, the validity period of the operation command may be the minimum value of the MaxFanoutTime and the TimeOut; however, the embodiment of the present invention is not limited thereto, and the validity period may also be set by other means.
- the gateway in the GwMO framework works in the proxy mode
- the operation information carries the validity period of the operation command or the operation.
- the validity period of the command and the mode in which the gateway executes the operation command, so that the gateway deletes the expired operation command which may be expressed as:
- the Fanout object is expanded, and the server specifies the validity period of the operation command or the validity period of the operation command and the mode in which the gateway executes the operation command. For example, as shown in FIG. 6, the corresponding Exp i ry is created in the Fanout object. a node and an ExeFlag node, where the Expiry node is used to carry the validity period of the operation command, which may be a 32-bit int type data, a decrement counter in a minimum unit of seconds, but the embodiment of the present invention does not limit this.
- ExeFlag node is used to carry the operation command of the gateway, which may be an int type, for example, 1 means that the gateway is allowed to automatically execute when the operation command expires, and 0 means not allowed. The gateway is automatically executed when the operation command expires, and 2 indicates that the command has been executed.
- the embodiment of the present invention does not limit this, and may be other data types.
- the gateway deletes the expired operation command according to the validity period of the operation command or the validity period of the operation command and the mode in which the gateway executes the operation command, and specifically includes:
- the gateway deletes the expired operation command according to the validity period of the operation command, as shown in FIG. 7, including:
- step 401 Detect whether the operation command is within the validity period; if the operation command is not in the valid period, execute step 402; if the operation command is within the validity period, perform step 401.
- detecting whether the operation command is within the validity period may be based on a predetermined time period
- the detection of the period period can also be detected in real time.
- the embodiment of the present invention does not limit this; when detecting according to a predetermined time period period, the predetermined time period can be set according to the user's needs, and is modified according to the user's needs. This embodiment of the present invention does not limit this.
- the operation information carries the validity period of the operation command, and does not carry the mode in which the gateway executes the operation command, as long as the operation command is not in the validity period, whether the operation command is Has been executed, will be deleted.
- the gateway deletes the expired operation command according to the validity period of the operation command and the mode in which the gateway executes the operation command.
- the method includes:
- step 501 Detect whether the operation command is within the validity period; if the operation command is not in the valid period, execute step 502; if the operation command is within the validity period, perform step 501.
- step 503 Determine a mode in which the gateway performs an operation command. If the mode in which the gateway executes an operation command is to prevent the gateway from automatically executing when the operation command expires, step 503 is performed; if the mode in which the gateway executes the operation command is allowed When the gateway automatically executes when the operation command expires, step 504 is performed.
- step 504 Determine an execution status of the operation command, where an execution status of the operation command is not executed and has been executed; if an execution status of the operation command is performed, step 503 is performed; If the execution status of the operation command is not executed, step 505 is performed.
- the method further includes: after deleting the operation command, the gateway sends a notification message to the server that the expiration operation command has been deleted.
- the server receives a notification message that the expiration operation command sent by the gateway has been deleted; and updates a predefined operation command execution status table according to the notification message.
- the predefined operation command execution state table includes at least an operation command number of the operation command, an operation command name, and an operation command execution state.
- the operation information for performing the management operation on the target terminal when the operation information for performing the management operation on the target terminal is sent to the gateway, the operation information carries the operation command execution result of the management operation on the target terminal. Returning form; after the gateway receives the operation command execution result sent by the target terminal, when the operation command execution result has an indication of a return form, processing the execution result of the operation command according to the return form, and obtaining the Returning the operation result of the operation command of the form, and transmitting the execution result of the operation command conforming to the return form to the server; enabling the service to process the execution result of the operation command, according to the return form of the execution result, to the same class Execution results are processed in batches; compared with processing results of the servers one by one in the prior art, the efficiency of the server processing terminal executing the operation command results is improved.
- the server may perform an execution result of the operation command on the target terminal according to the management requirement, and instruct the gateway to group the target terminal again, thereby facilitating subsequent operations. Further, in the embodiment of the present invention, the server maintains a management operation table, so that the executed command has a record, thereby facilitating further operations.
- the operation information when the server sends the operation information of the management operation to the target terminal to the gateway, the operation information carries the validity period of the operation command or the validity period of the operation command and the gateway performs an operation.
- the mode of the command enables the gateway to save a large amount of storage space of the gateway according to the operation command for deleting the expiration.
- the embodiment of the present invention provides a server, including: as shown in FIG. 9, the server includes: a first sending unit 61 and a first receiving unit 62.
- the first sending unit 61 is configured to send, to the gateway, operation information for performing a management operation on the target terminal, where the operation information carries a return form of an operation command execution result of performing a management operation on the target terminal, so that the gateway is Returning, to the server, the operation command execution result returned by the target terminal according to the return form; the return form is indication information indicating how the gateway groups the operation command execution result of the target terminal.
- the return form is indication information indicating how the gateway groups the operation command execution result of the target terminal.
- the first receiving unit 62 is configured to receive an operation command execution result that is sent by the gateway and meets the return form.
- the server further includes: a second sending unit 63.
- a second sending unit 63 configured to receive, by the first receiving unit 62, the sent by the gateway After the operation result of the returning operation command is executed, a message for grouping the target terminal corresponding to the execution result of the operation command is sent to the gateway according to the need of the subsequent operation, so that the gateway performs the operation according to the operation.
- the message that the target terminal corresponding to the command execution result is grouped, and the target terminals corresponding to the execution result of the operation command are grouped.
- the second sending unit 63 sends a message to the gateway to group the target terminal corresponding to the execution result of the operation command, the message is grouped in the target terminal corresponding to the execution result of the operation command.
- the message that the target terminal corresponding to the command execution result is grouped may not carry the grouping condition for grouping the target terminal corresponding to the execution result of the operation command, and the gateway may execute the result according to the operation command, and the execution result of the operation command is corresponding.
- the target terminals are grouped. This embodiment of the present invention does not limit this.
- the server further includes a third sending unit 64.
- a third sending unit 64 configured to send, to the gateway, a target corresponding to the execution result of the operation command after the first receiving unit 62 receives the execution result of the operation command with the return form sent by the gateway And a packet condition message that is sent by the terminal, where the packet condition message carries a grouping condition for grouping the target terminal corresponding to the operation result of the operation command, so that the gateway corresponds to the execution result of the operation command according to the grouping condition.
- the target terminals are grouped.
- the server further includes: a first updating unit 65.
- the first update unit 65 is configured to: after the first receiving unit 62 receives the execution result of the operation command that is sent by the gateway and meets the return form, update the predefined management operation table according to the operation command execution result,
- the management operation table includes an operation command number, an operation command name, a path of the target terminal, and an operation command execution result identifier.
- the gateway saves the gateway storage space
- the operation information carries an expiration date of the operation command or a mode of carrying the operation command and a mode in which the gateway executes an operation command, so that the gateway Deleting the expired operation command;
- the mode in which the gateway executes the operation command includes allowing the gateway to automatically execute when the operation command expires and not allowing the gateway to automatically execute when the operation command expires.
- the server further includes: a third receiving unit 66 and a second updating operating unit 67.
- the third receiving unit 66 is configured to receive a notification message that the expiration operation command sent by the gateway has been deleted.
- the second update operation unit 67 updates the predefined operation command execution status table according to the notification message received by the second receiving unit 66.
- the embodiment of the present invention further provides a gateway.
- the gateway includes: a first receiving unit 71, a first sending unit 72, a second receiving unit 73, an operating unit 74, and a second sending unit 75.
- the first receiving unit 71 is configured to receive operation information sent by the server for performing a management operation on the target terminal.
- the first sending unit 72 is configured to send a corresponding operation command to the target terminal according to the operation information received by the first receiving unit 71.
- the second receiving unit 73 is configured to receive an operation command execution result of the operation command sent by the target terminal.
- the operation unit 74 is configured to: when the operation command execution result has an indication of a return form, perform the operation command execution result received by the second receiving unit 73 according to the returned form of the indicated operation command execution result Processing, obtaining an operation command execution result that conforms to the return form.
- the second sending unit 75 is configured to send the operation result of the operation command obtained by the operation unit 74 in accordance with the return form to the server.
- the gateway further includes: a first determining unit 76.
- a first determining unit 76 configured to determine, after the second receiving unit 73 receives an operation command execution result of the operation command sent by the target terminal, whether the operation life is stored in the gateway The return form of the execution result.
- the operation unit 74 is further configured to: when the first determining unit 76 determines that the return form of the operation command execution result is stored in the gateway, perform the operation command execution result according to the stored return form Processing, obtaining an operation command execution result that conforms to the return form.
- the second sending unit 75 is further configured to: when the first determining unit 76 determines that the returning form of the operation command execution result is not stored in the determining gateway, send the operation command execution result to the server.
- the gateway further includes: a third receiving unit 77, a grouping operation unit 78, and a third sending unit 79.
- a third receiving unit 77 configured to receive, after the second sending unit 75 sends an operation command execution result that conforms to the return form to the server, a target corresponding to the execution result of the operation command sent by the server a message that the terminal performs grouping; wherein the message may carry a grouping condition for grouping the target terminal corresponding to the operation result of the operation command, or may not carry the grouping operation unit 78 for the third
- the message received by the receiving unit 77 for grouping the target terminals corresponding to the execution result of the operation command is grouped by the target terminal corresponding to the execution result of the operation command.
- the grouping operation unit 78 according to the message that the target terminal corresponding to the execution result of the operation command is received by the third receiving unit 77, grouping the target terminal corresponding to the execution result of the operation command, specifically includes: When the message received by the third receiving unit 77 for grouping the target terminal corresponding to the execution result of the operation command carries a grouping condition for grouping the target terminal corresponding to the execution result of the operation command, the grouping operation unit 78 The target terminal corresponding to the execution result of the operation command is grouped according to the grouping condition; when the message received by the third receiving unit 77 for grouping the target terminal corresponding to the execution result of the operation command is not carried, When the grouping condition of the target terminal corresponding to the operation command execution result is grouped, the grouping operation unit 78 is configured to group the target terminals corresponding to the operation command execution result according to the operation command execution result, each group Contains the same operation command execution result pair The target terminal should be.
- a third sending unit 79 configured to divide the target terminal corresponding to the execution result of the operation command The execution result of the group is sent to the server.
- the gateway further includes: a fourth receiving unit 710.
- the fourth receiving unit 710 is configured to: after the second sending unit 75 sends an operation command execution result that conforms to the return form to the server, receive the operation sent by the server
- the grouping operation unit 78 is configured to group the target terminals corresponding to the execution result of the operation command according to the grouping condition.
- the gateway in the process of asynchronous transmission, if the gateway only receives the message that the target terminal corresponding to the operation command execution result is grouped, but does not receive the grouping condition information, the default is as follows.
- the operation command execution result is grouped, and each group includes a target terminal corresponding to the execution result of the same operation command.
- the gateway further includes: a detecting unit 711, a deleting unit
- the detecting unit 711 is configured to detect, when the validity period of the operation command is carried in the operation information received by the first receiving unit 71, whether the operation command is within the validity period.
- the deleting unit 712 is configured to delete the operation command when the detecting unit 711 detects that the operation command is not within the validity period.
- the gateway further includes: a second determining unit 71 3, a third determining unit 71 4 , and a fourth sending unit 715.
- the detecting unit 711 is further configured to: in the operation information received by the first receiving unit 71, a validity period of the operation command and a mode in which the gateway executes an operation command, where the gateway executes an operation command
- the mode includes allowing the gateway to automatically execute when the operation command expires and not allowing the gateway to automatically execute when the operation command expires, detecting whether the operation command is within the validity period.
- the second determining unit 71 3 is configured to determine, when the detecting unit 711 detects that the operation command is not within the validity period, determine a mode in which the gateway executes an operation command.
- the deleting unit 712 is further configured to: when the second determining unit 71 determines that the mode in which the gateway executes the operation command is to prevent the gateway from automatically executing when the operation command expires, deleting the operation command.
- the third determining unit 714 is configured to determine, in the second determining unit 71 3, that the mode in which the gateway executes the operation command is to allow the gateway to automatically execute when the operation command expires, determine an execution state of the operation command, The execution status of the operation command is not executed and has been executed.
- the deleting unit 712 is further configured to delete the operation command when the third determining unit 714 determines that the execution state of the operation command is that it has been executed.
- the fourth sending unit 715 is configured to send the operation command to the corresponding target terminal when the third determining unit 714 determines that the execution state of the operation command is not performed.
- the gateway further includes: a fifth sending unit 716.
- the fifth sending unit 716 is configured to send, to the server, a notification message that the expiration operation command has been deleted after the deleting unit 712 deletes the operation command.
- the embodiment of the present invention further provides a system for managing a terminal.
- the system includes: a server 81 and a gateway 82.
- the server 81 is configured to send, to the gateway 82, operation information for performing a management operation on the target terminal, where the operation information carries a return form of an operation command execution result of performing a management operation on the target terminal, so that the gateway 82
- the operation result returned by the target terminal is returned to the server 81 according to the return form, and the return form is indication information indicating how the gateway groups the operation command execution result of the target terminal; and receiving the gateway 82 to send the Returns the form of the operation command execution result.
- the gateway 82 is configured to receive the operation information sent by the server 81, send a corresponding operation command to the target terminal according to the operation information, and receive an operation command execution result of the operation command sent by the target terminal.
- the operation command execution result has an indication of a return form
- the operation command execution result is processed to obtain an operation command execution result that conforms to the return form;
- the return operation command execution result is sent to the server 81.
- the operation information for performing the management operation on the target terminal when the operation information for performing the management operation on the target terminal is sent to the gateway, the operation information carries a return form of the execution result of the operation command for performing the management operation on the target terminal; when the gateway receives After the execution result of the operation command sent by the target terminal, when the operation command execution result has an indication of a return form, the operation result execution result is processed according to the return form, and an operation command execution result conforming to the return form is obtained.
- the server processes the execution result one by one, and improves the efficiency of the server processing terminal executing the operation command result.
- the server may perform an execution result of the operation command on the target terminal according to the management requirement, and instruct the gateway to group the target terminal again, thereby facilitating subsequent operations. Further, in the embodiment of the present invention, the server maintains a management operation table, so that the executed command has a record, thereby facilitating further operations.
- the operation information when the server sends the operation information of the management operation to the target terminal to the gateway, the operation information carries the validity period of the operation command or the validity period of the operation command and the gateway performs an operation.
- the mode of the command enables the gateway to save a large amount of storage space of the gateway according to the operation command for deleting the expiration.
- the present invention can be implemented by means of software plus necessary general hardware, and of course, by hardware, but in the case of more than 4, the former is better.
- Implementation Based on such understanding, the technical solution of the present invention, which is essential or contributes to the prior art, may be embodied in the form of a software product stored in a readable storage medium, such as a floppy disk of a computer.
- a hard disk or optical disk or the like includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform the methods described in various embodiments of the present invention.
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Health & Medical Sciences (AREA)
- Computing Systems (AREA)
- General Health & Medical Sciences (AREA)
- Medical Informatics (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
- Computer And Data Communications (AREA)
- Telephonic Communication Services (AREA)
Abstract
Description
管理终端的方法和装置 本申请要求于 2011年 6月 22日提交中国专利局、 申请号为 201110169708.6 发明名称为"管理终端的方法和装置"的中国专利申请的优先权其全部内容通过 引用结合在本申请中。 The present invention claims the priority of the Chinese Patent Application entitled "Method and Apparatus for Managing Terminals", filed on June 22, 2011 by the Chinese Patent Office, Application No. 201110169708.6 In this application.
技术领域 Technical field
本发明涉及通信领域, 尤其涉及一种管理终端的方法和装置。 The present invention relates to the field of communications, and in particular, to a method and apparatus for managing a terminal.
背景技术 Background technique
OMA ( Open Mobile Architecture, 开放式移动体系结构) DM ( Design Management, 设备管理) VI.3 (以下筒称 DM规范), 是 OMA DM WG制定的设备 管理统一规范。 DM 系统提供了一种低成本方案, 用于第三方管理和设置终端设 备中的环境和配置信息, 解决这些设备在使用过程中遇到的问题, 例如通过 OTA (over the air, 无线网络)方式进行软件和固件的安装、 升级等操作, 并提 供更加人性化和个性化的服务, 提高用户体验。 DM 系统包括终端设备上的 DM Client (DM客户端)、 终端设备上存储的设备管理树、 以及 DM服务器; 该 DM客 户端用于解释和执行 DM服务器下发的管理命令; 该设备管理树可以被认为是一 个 DM服务器对终端设备进行管理的接口, DM服务器通过 DM协议与终端设备中 的 DM客户端进行通信来实现对终端设备的管理。 OMA (Open Mobile Architecture) DM (Design Management, Device Management) VI.3 (hereinafter referred to as the DM Specification) is a unified device management specification developed by the OMA DM WG. The DM system provides a low-cost solution for third-party management and setting of environment and configuration information in the terminal device to solve problems encountered during the use of these devices, such as through OTA (over the air) Install and upgrade software and firmware, and provide more personalized and personalized services to enhance the user experience. The DM system includes a DM client (DM client) on the terminal device, a device management tree stored on the terminal device, and a DM server; the DM client is used to interpret and execute the management command delivered by the DM server; It is considered as an interface for the DM server to manage the terminal device. The DM server communicates with the DM client in the terminal device through the DM protocol to implement management of the terminal device.
为了方便 DM服务器对 DM客户端的管理, 现有技术中在 DM服务器和 DM客 户端之间加入了 GW (Gateway, 网关), 构成了 GwMO构架, 该 GwMO构架描述了 DM管理服务器通过网关对内网终端进行管理的技术。 DM服务器、 网关、 终端均 符合 0MA DM的规范。 协议针对不同管理场景和管理策略, 定义了网关的三种工 作模式: 透明模式(Transparent Mode) , 代理模式(Proxy Mode)和适配模式 (Adaptation Mode)。 在引入 DM Gateway 网关设备以后, 如果网关工作在代理 模式下,即在 DM服务器 (DMS)与 DM网关 (DM Gateway)之间, DM网关 (DM Gateway) 与设备之间各保持一个 DM会话, 且同时向一个或多个终端发送设备管理命令的 时候, 需要使用 Fanout (批量扇出)机制。 此 Fanout M0管理对象保存在 DM网 关(DM Ga teway)上。 In order to facilitate the management of the DM client by the DM server, in the prior art, a GW (Gateway, Gateway) is added between the DM server and the DM client to form a GwMO framework, and the GwMO framework describes the DM management server through the gateway to the intranet. The technology that the terminal manages. The DM server, gateway, and terminal all conform to the specifications of the 0MA DM. The protocol defines three working modes of the gateway for different management scenarios and management policies: Transparent Mode, Proxy Mode, and Adaptation Mode. After the introduction of the DM Gateway gateway device, if the gateway works in proxy mode, that is, between the DM server (DMS) and the DM Gateway (DM Gateway), the DM Gateway maintains a DM session with the device, and When sending device management commands to one or more terminals at the same time, you need to use the Fanout (bulk fanout) mechanism. This Fanout M0 management object is saved in the DM network. On the DM Ga teway.
在实现上述终端管理的过程中, 发明人发现现有技术中至少存在如下问题: 终端通过网关返回的结果数目庞大, 并且每个结果的没有统一的表示形式, 需 要服务器逐个处理该终端结果, 使得服务器的效率很低。 In the process of implementing the foregoing terminal management, the inventor finds that at least the following problems exist in the prior art: the number of results returned by the terminal through the gateway is large, and there is no unified representation of each result, and the server needs to process the terminal result one by one, so that The efficiency of the server is very low.
发明内容 本发明的实施例提供一种管理终端的方法和装置, 提高了服务器处理终端 执行操作命令结果的效率。 SUMMARY OF THE INVENTION Embodiments of the present invention provide a method and apparatus for managing a terminal, which improves the efficiency of a server processing terminal to execute an operation command result.
为达到上述目的, 本发明的实施例采用如下技术方案: In order to achieve the above object, the embodiment of the present invention adopts the following technical solutions:
一种管理终端的方法, 包括: A method of managing a terminal, comprising:
向网关发送对目标终端进行管理操作的操作信息, 所述操作信息中携带对 所述目标终端进行管理操作的操作命令执行结果的返回形式, 以便所述网关将 所述目标终端返回的操作命令执行结果按照所述返回形式返回给服务器; 所述 返回形式为指示网关如何将目标终端的操作命令执行结果进行分组的指示信 接收所述网关发送的符合所述返回形式的操作命令执行结果。 Sending, to the gateway, operation information for performing a management operation on the target terminal, where the operation information carries a return form of an operation command execution result of performing a management operation on the target terminal, so that the gateway performs an operation command returned by the target terminal The result is returned to the server according to the return form; the return form is an indication message indicating how the gateway groups the operation command execution result of the target terminal, and receives an operation command execution result that is sent by the gateway and conforms to the return form.
一种管理终端的方法, 包括: A method of managing a terminal, comprising:
接收服务器发送的对目标终端进行管理操作的操作信息; Receiving operation information sent by the server for performing management operations on the target terminal;
根据所述操作信息向所述目标终端发送对应的操作命令, 并接收所述目标 终端发送的所述操作命令的操作命令执行结果; And transmitting, according to the operation information, a corresponding operation command to the target terminal, and receiving an operation command execution result of the operation command sent by the target terminal;
在所述操作命令执行结果具有返回形式的指示时, 根据所指示的操作命令 执行结果的返回形式, 对所述操作命令执行结果进行处理, 得到符合所述返回 形式的操作命令执行结果; And when the operation command execution result has an indication of a return form, processing the execution result of the operation command according to the returned form of the operation result of the operation command, and obtaining an operation result execution result that conforms to the return form;
将符合所述返回形式的操作命令执行结果发送给所述服务器。 An operation command execution result conforming to the return form is transmitted to the server.
一种服务器, 包括: A server, comprising:
第一发送单元, 用于向网关发送对目标终端进行管理操作的操作信息, 所 述操作信息中携带对所述目标终端进行管理操作的操作命令执行结果的返回形 式, 以使得所述网关将所述目标终端返回的操作命令执行结果按照所述返回形 式返回给所述服务器; 所述返回形式为指示网关如何将目标终端的操作命令执 行结果进行分组的指示信息; a first sending unit, configured to send, to the gateway, operation information for performing a management operation on the target terminal, where the operation information carries a return form of an operation command execution result of performing a management operation on the target terminal, so that the gateway The operation command execution result returned by the target terminal is in accordance with the return shape Returning to the server; the return form is indication information indicating how the gateway groups the operation command execution result of the target terminal;
第一接收单元, 用于接收所述网关发送的符合所述返回形式的操作命令执 行结果。 And a first receiving unit, configured to receive an operation command execution result that is sent by the gateway and meets the return form.
一种网关, 包括: A gateway, including:
第一接收单元, 用于接收服务器发送的对目标终端进行管理操作的操作信 息; a first receiving unit, configured to receive, by the server, operation information for performing a management operation on the target terminal;
第一发送单元, 用于根据所述第一接收单元接收的所述操作信息向所述目 标终端发送对应的操作命令; a first sending unit, configured to send, according to the operation information received by the first receiving unit, a corresponding operation command to the target terminal;
第二接收单元, 用于接收所述目标终端发送的所述操作命令的操作命令执 行结果; a second receiving unit, configured to receive an operation command execution result of the operation command sent by the target terminal;
操作单元, 用于在所述操作命令执行结果具有返回形式的指示时, 根据所 指示的操作命令执行结果的返回形式, 对所述第二接收单元接收的所述操作命 令执行结果进行处理, 得到符合所述返回形式的执行结果; An operation unit, configured to process, according to the returned form of the executed operation command execution result, the execution result of the operation command received by the second receiving unit, when the operation command execution result has an indication of a return form, Comply with the execution result of the return form;
第二发送单元, 用于将所述操作单元得到的符合所述返回形式的操作命令 执行结果发送给所述服务器。 And a second sending unit, configured to send, by the operating unit, an operation command execution result that conforms to the return form to the server.
本发明实施例提供的管理终端的方法和装置, 在向网关发送对目标终端进 行管理操作的操作信息时, 在所述操作信息中携带有对所述目标终端进行管理 操作的操作命令执行结果的返回形式; 当该网关接收到目标终端发送的操作命 令执行结果后, 在所述操作命令执行结果具有返回形式的指示时, 按照该返回 形式对所述操作命令执行结果进行处理, 得到符合所述返回形式的操作命令执 行结果, 并将符合所述返回形式的操作命令执行结果发送给所述服务器; 使服 务在对操作命令执行结果进行处理时, 能够按照操作命令执行结果的返回形式, 对同一类的执行结果进行批量处理; 与现有技术中服务器逐个处理该执行结果 相比, 提高了服务器处理终端执行操作命令结果的效率。 The method and device for managing a terminal provided by the embodiment of the present invention, when the operation information of the management operation of the target terminal is sent to the gateway, the operation information carries the operation command execution result of the management operation of the target terminal Returning form; after the gateway receives the operation command execution result sent by the target terminal, when the operation command execution result has an indication of a return form, processing the execution result of the operation command according to the return form, and obtaining the Returning a result of the operation command execution of the form, and transmitting the execution result of the operation command conforming to the return form to the server; enabling the service to process the result of the execution of the operation command according to the return form of the execution result of the operation command The execution result of the class is batch processed; compared with the processing result of the server processing the processing result one by one in the prior art, the efficiency of the server processing terminal executing the operation command result is improved.
附图说明 为了更清楚地说明本发明实施例或现有技术中的技术方案, 下面将对实施 例或现有技术描述中所需要使用的附图作筒单地介绍, 显而易见地, 下面描述 中的附图仅仅是本发明的一些实施例, 对于本领域普通技术人员来讲, 在不付 出创造性劳动的前提下, 还可以根据这些附图获得其他的附图。 BRIEF DESCRIPTION OF THE DRAWINGS In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following will be implemented. The drawings used in the examples or the description of the prior art are described in a single manner. It is obvious that the drawings in the following description are only some embodiments of the present invention, and are not creative to those skilled in the art. Other drawings can also be obtained from these drawings on the premise of labor.
图 1为本发明实施例中一种管理终端的方法流程图; FIG. 1 is a flowchart of a method for managing a terminal according to an embodiment of the present invention;
图 2为本发明实施例中另一种管理终端的方法流程图; 2 is a flowchart of another method for managing a terminal according to an embodiment of the present invention;
图 3为本发明实施例中一种操作命令管理树的结构示意图; 3 is a schematic structural diagram of an operation command management tree according to an embodiment of the present invention;
图 4为本发明实施例中另一种管理终端的方法流程图; 4 is a flowchart of another method for managing a terminal according to an embodiment of the present invention;
图 5为本发明实施例中另一种操作命令管理树的结构示意图; FIG. 5 is a schematic structural diagram of another operation command management tree according to an embodiment of the present invention;
图 6为本发明实施例中另一种操作命令管理树的结构示意图; 6 is a schematic structural diagram of another operation command management tree according to an embodiment of the present invention;
图 7为本发明实施例中另一种管理终端的方法流程图; FIG. 7 is a flowchart of another method for managing a terminal according to an embodiment of the present invention;
图 8为本发明实施例中另一种管理终端的方法流程图; FIG. 8 is a flowchart of another method for managing a terminal according to an embodiment of the present invention;
图 9为本发明实施例中一种服务器的组成框图; FIG. 9 is a block diagram showing the composition of a server according to an embodiment of the present invention; FIG.
图 1 0为本发明实施例中另一种服务器的组成框图; FIG. 10 is a block diagram showing the composition of another server in the embodiment of the present invention;
图 1 1为本发明实施例中另一种服务器的组成框图; FIG. 11 is a block diagram showing the composition of another server according to an embodiment of the present invention;
图 12为本发明实施例中另一种服务器的组成框图; FIG. 12 is a block diagram showing the composition of another server according to an embodiment of the present invention; FIG.
图 1 3为本发明实施例中另一种服务器的组成框图; FIG. 13 is a structural block diagram of another server according to an embodiment of the present invention;
图 14为本发明实施例中一种网关的组成框图; FIG. 14 is a structural block diagram of a gateway according to an embodiment of the present invention;
图 15为本发明实施例中另一种网关的组成框图 FIG. 15 is a block diagram of another gateway in an embodiment of the present invention;
图 16为本发明实施例中另一种网关的组成框图 16 is a block diagram of another gateway in an embodiment of the present invention.
图 17为本发明实施例中另一种网关的组成框图 17 is a block diagram of another gateway in an embodiment of the present invention.
图 18为本发明实施例中另一种网关的组成框图 18 is a block diagram of another gateway in an embodiment of the present invention.
图 19为本发明实施例中另一种网关的组成框图 FIG. 19 is a block diagram of another gateway in an embodiment of the present invention;
图 20为本发明实施例中另一种网关的组成框图 20 is a block diagram of another gateway in an embodiment of the present invention.
图 21为本发明实施例中一种管理终端的系统组成框图。 FIG. 21 is a structural block diagram of a system for managing a terminal according to an embodiment of the present invention.
具体实施方式 detailed description
下面将结合本发明实施例中的附图, 对本发明实施例中的技术方案进行清 楚、 完整地描述, 显然, 所描述的实施例仅仅是本发明一部分实施例, 而不是 全部的实施例。 基于本发明中的实施例, 本领域普通技术人员在没有作出创造 性劳动前提下所获得的所有其他实施例, 都属于本发明保护的范围。 The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. It is obvious that the described embodiments are only a part of the embodiments of the present invention, instead of All embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative efforts are within the scope of the present invention.
本发明实施例提供了一种管理终端的方法, 该方法为服务器侧的方法, 如 图 1所示, 该方法包括: An embodiment of the present invention provides a method for managing a terminal, where the method is a server-side method, as shown in FIG. 1, the method includes:
101、 服务器向网关发送对目标终端进行管理操作的操作信息, 所述操作信 息中携带有对所述目标终端进行管理操作的操作命令执行结果的返回形式, 以 便所述网关将所述目标终端返回的操作命令执行结果按照所述返回形式返回给 服务器, 所述返回形式为指示网关如何将目标终端的操作命令执行结果进行分 组的指示信息。 The server sends, to the gateway, operation information for performing a management operation on the target terminal, where the operation information carries a return form of an operation command execution result of performing a management operation on the target terminal, so that the gateway returns the target terminal. The operation command execution result is returned to the server according to the return form, and the return form is indication information indicating how the gateway groups the operation command execution result of the target terminal.
其中, 所述操作命令执行结果的返回形式包括返回形式的类型和数量限定: 该返回形式的类型包括: 松散型分组方式和严格匹配型分组方式, 其可以通过 参数表示,该参数可以为 Prof i l e参数,定义所述操作命令执行结果的返回形式 具体可以为 "1" 代表松散型分组方式, "2" 代表严格匹配型分组方式。 返回形 式的数量限定包括: 对一个操作命令的执行结果进行返回、 对两个操作命令的 执行结果进行返回、 对两个以上操作命令的执行结果进行返回; 其也可以通过 参数的形式进行定义, 例如可以通过 ResGroup参数定义, 具体的, "1" 表示对 一个操作命令的执行结果进行返回; "2" 表示对两个操作命令的执行结果进行 返回; "3" 表示对两个以上操作命令的执行结果进行返回。 The return form of the operation command execution result includes a type and a quantity limit of the return form: the type of the return form includes: a loose grouping mode and a strict matching grouping mode, which can be represented by parameters, and the parameter can be Prof ile The parameter, which defines the return form of the execution result of the operation command, may specifically be "1" for the loose grouping mode and "2" for the strict matching grouping mode. The quantity limit of the return form includes: returning the execution result of one operation command, returning the execution result of the two operation commands, and returning the execution result of the two or more operation commands; it may also be defined by the parameter form, For example, it can be defined by the ResGroup parameter. Specifically, "1" means returning the execution result of an operation command; "2" means returning the execution result of the two operation commands; "3" means calling the operation command of two or more operations. The result of the execution is returned.
其中, 所述操作信息中携带有对所述目标终端进行管理操作的操作命令执 行结果的返回形式, 该返回形式可以以参数的形式表示, 但本发明实施例对此 不进行限制, 也可以直接指明对应的返回形式; 当以参数的形式表示时, 例如, 当指示操作命令执行结果的返回形式为按照松散型分组方式将两个操作命令的 执行结果返回时, 其参数可以设置为 Prof i le = 1 AND ResGroup = 1" , 或者: " Prof i le = 2 AND CmdID = 123 AND CmdID=002; 其中, CmdID参数表示, 对 Cmd I D为 n的操作结果返回, 譬如对 CMD I D= 123和 002的操作结果做返回。 The operation information carries a return form of the operation command execution result of the management operation of the target terminal, and the return form may be expressed in the form of a parameter, but the embodiment of the present invention does not limit this, and may directly Indicates the corresponding return form; when expressed in the form of a parameter, for example, when the return form indicating the execution result of the operation command is to return the execution result of the two operation commands in a loose grouping manner, the parameter may be set to Prof i le = 1 AND ResGroup = 1" , or: " Prof i le = 2 AND CmdID = 123 AND CmdID=002; where CmdID parameter indicates that the result of the operation with Cmd ID n is returned, for example, for CMD ID = 123 and 002 The result of the operation is returned.
需要说明的是, 在具体实施向网关发送对目标终端进行管理操作的操作信 息时, 可以携带所述对所述目标终端进行管理操作的操作命令执行结果的返回 形式, 也可以不携带对所述目标终端进行管理操作的操作命令执行结果的返回 形式, 本发明实施例对此不进行限制, 根据用户需求设置; 但是要完成网关将 所述目标终端返回的操作命令执行结果按照所述返回形式返回给服务器, 所述 操作信息中必须要携带对所述目标终端进行管理操作的操作命令执行结果的返 回形式。 It should be noted that when the operation information for performing the management operation on the target terminal is sent to the gateway, the returning form of the operation command execution result of the management operation on the target terminal may be carried, or may not be carried. Return of the operation command execution result of the management operation of the target terminal The form is not limited by the embodiment of the present invention, and is set according to user requirements; however, the completion of the operation command output returned by the target terminal by the gateway is returned to the server according to the return form, and the operation information must be carried in the pair. The return form of the operation command execution result of the management operation of the target terminal.
1 02、 所述服务器接收所述网关发送的符合所述返回形式的操作命令执行结 果。 1 02. The server receives an operation command execution result that is sent by the gateway and conforms to the return form.
对应与上述管理终端的方法, 本发明实施例还提供一种管理终端的方法, 该方法为网关侧的方法, 如图 2所示, 该方法包括: Corresponding to the foregoing method for managing a terminal, the embodiment of the present invention further provides a method for managing a terminal, where the method is a gateway side method, as shown in FIG. 2, the method includes:
201、 网关接收服务器发送的对目标终端进行管理操作的操作信息。 201. The gateway receives operation information sent by the server for performing a management operation on the target terminal.
其中, 所述操作信息中可以携带有对所述目标终端进行管理操作的操作命 令执行结果的返回形式, 也可以不携带有对所述目标终端进行管理操作的操作 命令执行结果的返回形式, 本发明实施例对此不进行限制, 根据用户需求设置, 当用户需要将目标终端返回的操作命令执行结果按照预定返回形式返回时, 所 述操作信息中携带有对所述目标终端进行管理操作的操作命令执行结果的返回 形式。 The operation information may carry a return form of an operation command execution result of performing a management operation on the target terminal, or may not carry a return form of an operation command execution result of performing a management operation on the target terminal, The embodiment of the present invention does not limit this. When the user needs to return the operation result of the operation command returned by the target terminal according to the predetermined return form, the operation information carries the operation of performing the management operation on the target terminal. The return form of the command execution result.
需要说明的是, 当该服务器为 DM服务器, GwMO构架下的网关工作在网关工 作在代理模式下, 即 DMS-GW之间, GW-Device之间各保持一个 DM会话), 且同 时向一个或多个终端发送设备管理命令的时候,需要使用 Fanout机制。此 Fanout M0 保存在 Gateway 上, 如图 3 所示, Fanout 子树下面的节点功能如下: FanoutCommands由 DMS填充,是对终端的管理命令; TargetGroupRef对应 Conf ig M0管理对象中 DevGroup子树下面定义的群组的 id, 网关根据此 id找到目标终 端。 Star t为可执行节点, 由 DMS触发执行, 将 FanoutCommands的命令批量扇 出至目标终端。 本发明实施例中, 若所述操作信息中携带有对所述目标终端进 行管理操作的操作命令执行结果的返回形式, 则如图 3所示, 网关对 Fanout子 树进行扩充, 创建 Para节点, 所述 Para节点中记载了对应操作命令执行结果 的返回形式。 It should be noted that when the server is a DM server, the gateway under the GwMO framework works in the proxy mode, that is, between the DMS-GWs, and each GW-Device maintains a DM session, and simultaneously to one or both. When multiple terminals send device management commands, you need to use the Fanout mechanism. The Fanout M0 is saved on the Gateway. As shown in Figure 3, the nodes under the Fanout subtree function as follows: FanoutCommands is filled with DMS and is the management command for the terminal; TargetGroupRef corresponds to the group defined under the DevGroup subtree in the Conf ig M0 management object. The id of the group, the gateway finds the target terminal based on this id. Star t is an executable node, which is triggered by the DMS to fan out the FanoutCommands commands to the target terminal. In the embodiment of the present invention, if the operation information carries a return form of an operation command execution result of a management operation on the target terminal, as shown in FIG. 3, the gateway expands the Fanout subtree to create a Para node. A return form corresponding to the execution result of the operation command is described in the Para node.
202、 所述网关根据所述操作信息向所述目标终端发送对应的操作命令, 并 接收所述目标终端发送的所述操作命令的操作命令执行结果。 其中, 所述根据所述操作信息向所述目标终端发送对应的操作命令, 并接 收所述目标终端发送的所述操作命令执行结果的具体执行, 可以依据现有技术 的记载执行, 本发明实施例此处将不再赘述。 202. The gateway sends a corresponding operation command to the target terminal according to the operation information, and receives an operation command execution result of the operation command sent by the target terminal. The specific operation of transmitting the corresponding operation command to the target terminal according to the operation information, and receiving the execution result of the operation command sent by the target terminal may be performed according to the description of the prior art, and the implementation of the present invention is implemented. The examples will not be described here.
需要说明的是, 当步骤 201中创建了 Para节点时, 当网关根据所述操作信 息向所述目标终端发送对应的操作命令时, 即运行 S tar t节点时, 用 TargetRef 携带出 Para节点值, 用于通知网关该次操作命令执行结果的返回形式。 It should be noted that, when the Para node is created in step 201, when the gateway sends a corresponding operation command to the target terminal according to the operation information, that is, when the S tar t node is operated, the Target node carries the Para node value. The return form used to inform the gateway of the execution result of the operation command.
另外, 异步通讯时, 网关有以下几种方式来保持操作命令、 操作命令执行 结果、 服务器的对应, 具体包括: 第一种, 设置命令表格, 该命令表格如表 1 所示, 包括; 服务器、 目标设备标识、 操作命令标识。 In addition, in the asynchronous communication, the gateway has the following ways to maintain the operation command, the operation command execution result, and the server correspondence, and specifically includes: The first type, the setting command table, the command table is as shown in Table 1, including: the server, Target device ID, operation command ID.
表 1 Table 1
第二种, 网关执行操作命令时可以在 SynHdr中用 SourceRef 标签来携带操 作命令标识。 例如, "1295790618" 为操作命令标识。 具体操作如下: Second, the gateway can use the SourceRef tag to carry the operation command identifier in SynHdr when executing the operation command. For example, "1295790618" is an operation command identifier. The specific operations are as follows:
<SyncHdr> <SyncHdr>
<SourceRef > 1295790618</SourceRef > <SourceRef > 1295790618</SourceRef >
<SyncBody> <SyncBody>
操作命令放到此处 Action commands are placed here
</SyncBody> </SyncBody>
</SyncHdr> 第三种, 网关执行操作命令时可以 SynBody中添加 Al er t来携带操作命令 命令标识。 例如, "1295790618" 为操作命令标识。 具体操作如下: <SyncBody> </SyncHdr> Third, when the gateway executes the operation command, Al er t can be added to the SynBody to carry the operation command command identifier. For example, "1295790618" is an operation command identifier. The specific operations are as follows: <SyncBody>
<Aler t> <Aler t>
<CmdID>212</CmdID> <CmdID>212</CmdID>
<Data>1299</Data> <Data>1299</Data>
<I temXData>1295790618</DataX/I tem> <I temXData>1295790618</DataX/I tem>
</Aler t> </Aler t>
操作命令放到此处 Action commands are placed here
</SyncBody> </SyncBody>
第四种, 网关执行操作命令时可以在 SynBody中添加 correlator来携带操 作命令命令标识。 例如, "1295790618" 为操作命令标识。 具体操作如下: Fourth, when the gateway executes the operation command, it can add a correlator to the SynBody to carry the operation command command identifier. For example, "1295790618" is an operation command identifier. The specific operations are as follows:
<SyncBody> <SyncBody>
操作命令放到此处 Action commands are placed here
</SyncBody>。 </SyncBody>.
203、 在所述操作命令执行结果具有返回形式的指示时, 所述网关根据所指 示的操作命令执行结果的返回形式, 对所述操作命令执行结果进行处理, 得到 符合所述返回形式的操作命令执行结果。 203. When the operation command execution result has an indication of a return form, the gateway processes the execution result of the operation command according to the returned form of the executed operation command execution result, and obtains an operation command that conforms to the return form. Results of the.
其中, 所述返回形式的相应描述, 可以参考图 1的步骤 101中的相应描述, 本发明实施例此处将不再赘述。 For a corresponding description of the returning form, reference may be made to the corresponding description in step 101 of FIG. 1, and details are not described herein again.
204、 所述网关将符合所述返回形式的操作命令执行结果发送给所述服务 进一步的, 为了满足不同用户是需求, 在网关接收到所述目标终端发送的 所述操作命令执行结果后, 该方法还包括: 204. The gateway sends an operation command execution result that meets the return form to the service. To meet the requirement of different users, after the gateway receives the operation command execution result sent by the target terminal, The method also includes:
确定网关中是否存储指定所述操作命令执行结果的返回形式; 若存储指定 所述操作命令执行结果的返回形式, 则执行所述根据操作命令执行结果的返回 形式对所述执行结果进行处理, 得到符合所述返回形式的执行结果; 若所述网 关中没有存储指定所述操作命令执行结果的返回形式, 则将所述操作命令执行 结果发送给所述服务器。 其中, 在确定关中是否存储指定所述操作命令执行结 果的返回形式时, 当网关以节点的形式保存该指定所述操作命令执行结果的返 回形式时, 确定所述网关中是否存在存储指定所述操作命令执行结果的返回形 式的节点; 当然, 本发明实施例对此不进行限制, 其他保存该指定所述操作命 令执行结果的返回形式的方法也属于本发明实施例保护的范围。 Determining whether a return form specifying the execution result of the operation command is stored in the gateway; if the return form specifying the execution result of the operation command is stored, executing the return form according to the execution result of the operation command to process the execution result, and obtaining Complying with the execution result of the return form; if the return form specifying the execution result of the operation command is not stored in the gateway, the operation command execution result is sent to the server. Wherein, determining whether to store the specified operation command execution node in the gate When the gateway returns the form, when the gateway saves the return form specifying the execution result of the operation command in the form of a node, it is determined whether there is a node in the gateway that stores a return form specifying the execution result of the operation command; The embodiment of the present invention does not limit this, and other methods for saving the return form specifying the execution result of the operation command are also within the scope of protection of the embodiment of the present invention.
可选的, 在服务器接收到网关返回的符合返回形式的操作命令执行结果后, 为了方便服务器对该执行结果的进行后续管理操作, 如图 4 所示, 该方法还包 括: Optionally, after the server receives the execution result of the operation command returned by the gateway in accordance with the return form, in order to facilitate the subsequent management operation of the execution result by the server, as shown in FIG. 4, the method further includes:
301、 根据后续操作的需要, 向所述网关发送对所述操作命令执行结果对应 的目标终端进行分组的消息, 以使得所述网关按照所述对所述操作命令执行结 果对应的目标终端进行分组的消息, 对所述操作命令执行结果对应的目标终端 进行分组。 301. Send, according to the requirement of the subsequent operation, a message that the target terminal corresponding to the operation command execution result is grouped to the gateway, so that the gateway performs grouping according to the target terminal corresponding to the execution result of the operation command. The message, grouping the target terminals corresponding to the execution result of the operation command.
其中, 在同步传输时, 所述消息中可以携带对所述操作命令执行结果对应 的目标终端进行分组的分组条件, 也可以不携带对所述操作命令执行结果对应 的目标终端进行分组的分组条件, 本发明实施例对此不进行限制。 In the synchronous transmission, the message may carry a grouping condition for grouping the target terminal corresponding to the execution result of the operation command, or may not carry a grouping condition for grouping the target terminal corresponding to the execution result of the operation command. The embodiment of the present invention does not limit this.
例如, 网关上对目标设备进行分组包括 100个终端, 记为组 1 ; 在月良务器通 过网关对组 1进行第一轮操作命令操作后, 组 1中只有 90个目标终端返回操作 成功的结果。 网关按照操作命令执行结果进行分类, 并返回给服务器, 其中 90 个成功; 10个失败。 此时服务器只需要对 90个成功的设备进行后续操作; 组 1 就不再适用。 服务器就通知网关对目标终端进行分组, 将这个 90个设备分为组 2 , 以便进行后续操作。 For example, the target device is grouped by the gateway to include 100 terminals, which is recorded as group 1; after the first server operation command is performed on the group 1 through the gateway, only 90 target terminals in the group 1 return the operation successfully. result. The gateway classifies the results according to the operation command and returns it to the server, 90 of which are successful; 10 fail. At this point, the server only needs to perform subsequent operations on 90 successful devices; Group 1 is no longer applicable. The server notifies the gateway to group the target terminals, and divides the 90 devices into groups 2 for subsequent operations.
302、 网关接收所述服务器发送的对所述操作命令执行结果对应的目标终端 进行分组的消息。 302. The gateway receives, by the server, a message that is grouped by the target terminal corresponding to the execution result of the operation command.
303、 所述网关根据所述对所述操作命令执行结果对应的目标终端进行分组 的消息, 对所述操作命令执行结果对应的目标终端进行分组。 303. The gateway groups, according to the message that the target terminal corresponding to the operation command execution result is grouped, the target terminal corresponding to the operation command execution result.
具体是, 所述网关根据所述对所述操作命令执行结果对应的目标终端进行 分组的消息, 对所述操作命令执行结果对应的目标终端进行分组包括: Specifically, the gateway, according to the message that the target terminal corresponding to the execution result of the operation command is grouped, grouping the target terminal corresponding to the execution result of the operation command includes:
若所述对所述操作命令执行结果对应的目标终端进行分组的消息中, 携带 对所述操作命令执行结果对应的目标终端进行分组的分组条件, 则所述根据所 述对所述操作命令执行结果对应的目标终端进行分组的消息, 对所述操作命令 执行结果对应的目标终端进行分组为: 根据所述分组条件对所述操作命令执行 结果对应的目标终端进行分组。 And if the message for grouping the target terminal corresponding to the execution result of the operation command carries a grouping condition for grouping the target terminal corresponding to the execution result of the operation command, the a message for grouping the target terminals corresponding to the execution result of the operation command, and grouping the target terminals corresponding to the execution result of the operation command into: grouping the target terminals corresponding to the execution result of the operation command according to the grouping condition .
若所述对所述操作命令执行结果对应的目标终端进行分组的消息中, 没有 携带对所述操作命令执行结果对应的目标终端进行分组的分组条件, 则所述根 据所述对所述操作命令执行结果对应的目标终端进行分组的消息, 对所述操作 命令执行结果对应的目标终端进行分组为: 按照所述操作命令执行结果进行分 组, 每组包含相同所述操作命令执行结果对应的目标终端。 结果发送给所述服务器。 其中, 所述执行结果包括分组成功或失败。 And if the grouping of the target terminal corresponding to the execution result of the operation command does not carry a grouping condition for grouping the target terminal corresponding to the execution result of the operation command, the operation command according to the pair a message that the target terminal corresponding to the execution result is grouped, and the target terminals corresponding to the execution result of the operation command are grouped into: grouping according to the execution result of the operation command, and each group includes a target terminal corresponding to the execution result of the same operation command . The result is sent to the server. The execution result includes a success or failure of the group.
305、 所述服务器接收所述网关发送的对所述操作命令执行结果对应的目标 终端进行分组的执行结果, 以便所述操作命令执行结果对应的目标终端进行后 续操作。 例如, 如图 5所示, 对操作命令执行结果分组为 Group2的目标终端继 续操作。 则可以执行 Crea teGroup , 在网关管理树上 Conf i gMO对象中重新生成 新非分组信息。 305. The server receives, by the gateway, an execution result of grouping the target terminal corresponding to the execution result of the operation command, so that the target terminal corresponding to the execution result of the operation command performs subsequent operations. For example, as shown in FIG. 5, the target terminal grouped with the operation command execution result group 2 continues to operate. You can execute Crea teGroup to regenerate new non-grouping information in the Conf i gMO object on the gateway management tree.
另外, 需要说明的是, 当异步传输时, 在服务器接收到网关返回的符合返 回形式的操作命令执行结果后, 为了方便服务器对该执行结果的进行后续管理 操作, 本发明实施例还包括: In addition, it should be noted that, in the case of asynchronous transmission, after the server receives the execution result of the operation command in the return form returned by the gateway, in order to facilitate the subsequent management operation of the execution result by the server, the embodiment of the present invention further includes:
服务器根据后续操作的需要, 向所述网关发送对所述操作命令执行结果对 应的目标终端进行分组的分组条件消息, 所述分组条件消息中携带对所述操作 命令执行结果对应的目标终端进行分组的分组条件, 以使得所述网关根据所述 分组条件对所述操作命令执行结果对应的目标终端进行分组。 And the server sends, to the gateway, a grouping condition message for grouping the target terminal corresponding to the execution result of the operation command, where the packet conditional message carries the grouping of the target terminals corresponding to the execution result of the operation command. a grouping condition, so that the gateway groups the target terminals corresponding to the execution result of the operation command according to the grouping condition.
网关接收所述服务器发送的分组条件消息, 根据所述分组条件对所述操作 命令执行结果对应的目标终端进行分组。 The gateway receives the packet condition message sent by the server, and groups the target terminals corresponding to the execution result of the operation command according to the grouping condition.
另外, 需要说明的是, 在异步传输的过程中, 若网关仅接收到对所述操作 命令执行结果对应的目标终端进行分组的消息, 而没有接收到所述分组条件信 息, 则默认按照所述操作命令执行结果进行分组, 每组包含相同所述操作命令 执行结果对应的目标终端。 进一步可选的, 为了实现异步管理, 服务器建立并维护一份管理操作表, 该管理操作表至少包括如下信息: 操作命令编号、 操作命令名称、 目标终端的 路径、 操作命令执行结果标识。 例如, 如表 2所示, In addition, it should be noted that, in the process of asynchronous transmission, if the gateway only receives the message that the target terminal corresponding to the operation command execution result is grouped, but does not receive the grouping condition information, the default is as follows. The operation command execution results are grouped, and each group includes the target terminal corresponding to the execution result of the same operation command. Further, in order to implement asynchronous management, the server establishes and maintains a management operation table, and the management operation table includes at least the following information: an operation command number, an operation command name, a path of the target terminal, and an operation command execution result identifier. For example, as shown in Table 2,
表 2 Table 2
其中, Operat ion 为操作命令编号, Command为操作命令名称, Via为目标 终端的路径, SetTime 为操作命令执行结果标识, mode 为网关执行操作命令的 模式, To为目的终端所在的分组。 需要说明的是 SetTime为操作命令执行结果 标识, 表示了唯一的一条被执行的操作命令, 其表示形式不局限于上述数字。 Operat is the operation command number, Command is the operation command name, Via is the path of the target terminal, SetTime is the operation command execution result identifier, mode is the mode in which the gateway executes the operation command, and To is the group in which the destination terminal is located. It should be noted that SetTime is an operation command execution result identifier, which indicates a unique operation command that is executed, and its representation is not limited to the above numbers.
在网关执行完对应的操作命令后, 服务器根据所述操作命令执行结果更新 预定义的管理操作表。 After the gateway executes the corresponding operation command, the server updates the predefined management operation table according to the operation command execution result.
进一步可选的, 为了将一些服务器无法继续触发操作命令及时的从网关中 删除, 以便使网关节省网关存储空间, 本发明实施例还包括: Further, in addition, in order to prevent the server from being able to continue to trigger the operation command to be deleted from the gateway in time, so that the gateway saves the gateway storage space, the embodiment of the present invention further includes:
服务器在向网关发送对目标终端进行管理操作的操作信息时, 所述操作信 息携带有所述操作命令的有效期或者携带所述操作命令的有效期和所述网关执 行操作命令的模式, 以使得所述网关删除到期的操作命令; 所述网关执行操作 命令的模式包括允许网关在操作命令到期时自动执行和不允许网关在操作命令 到期时自动执行; 该允许网关在操作命令到期时自动执行, 表示网关在执行操 作命令时, 若在操作命令的有效期到期时, 还没有接收到服务器针对该操作命 令的执行指示信息, 则不无需等待该操作命令的执行指示信息, 自动将所述到 期的操作命令发送到对应的目标终端; 该不允许网关在操作命令到期时自动执 行, 表示网关在执行操作命令时, 若在操作命令的有效期到期时, 还没有接收 到服务器针对该操作命令的执行指示信息, 则需等待该操作命令的执行指示信 息, 并不能对所述到期的操作命令发送到对应的目标终端。 其中, 由于每个网 关的机能不同, 所以每个网关有自己的 MaxFanoutTime , 用于表示网关的一个 Fanout 对象存在的时间; 服务器在配置 Fanout 对象时, 也出示一个值, 记作 TimeOut , 用于表示一个 Fanout 操作命令存在的时间。 所以所述操作命令的有 效期可以为 MaxFanoutTime和 TimeOut的最小值; 但本发明实施例并不局限于 此, 还可以通过其他方式设定所述有效期。 When the server sends the operation information of the management operation to the target terminal, the operation information carries the validity period of the operation command or the validity period of the operation command and the mode in which the gateway executes the operation command, so that the The gateway deletes the expired operation command; the mode in which the gateway executes the operation command includes allowing the gateway to automatically execute when the operation command expires and does not allow the gateway to automatically execute when the operation command expires; the permission gateway automatically starts when the operation command expires Execution, indicating that when the operation command is executed by the gateway, if the execution instruction information of the operation command is not received by the server when the validity period of the operation command expires, the execution instruction information of the operation command is not required to be automatically The expired operation command is sent to the corresponding target terminal; the gateway is not allowed to automatically execute when the operation command expires The line indicates that when the operation command is executed by the gateway, if the execution instruction information of the operation command is not received by the server when the validity period of the operation command expires, the execution instruction information of the operation command is waited for, and the operation instruction cannot be The expired operation command is sent to the corresponding target terminal. Among them, because each gateway has different functions, each gateway has its own MaxFanoutTime, which is used to indicate the time when a Fanout object of the gateway exists. When the server configures the Fanout object, it also presents a value, which is called TimeOut, which is used to represent The time at which a Fanout operation command exists. Therefore, the validity period of the operation command may be the minimum value of the MaxFanoutTime and the TimeOut; however, the embodiment of the present invention is not limited thereto, and the validity period may also be set by other means.
其中, 当 GwMO构架下的网关工作在网关工作在代理模式下时, 服务器在向 网关发送对目标终端进行管理操作的操作信息时, 所述操作信息携带有所述操 作命令的有效期或者所述操作命令的有效期和所述网关执行操作命令的模式, 以使得所述网关删除到期的操作命令, 具体可以表现为:服务器对网关中的 When the gateway in the GwMO framework works in the proxy mode, when the server sends the operation information to the gateway for performing the management operation on the target terminal, the operation information carries the validity period of the operation command or the operation. The validity period of the command and the mode in which the gateway executes the operation command, so that the gateway deletes the expired operation command, which may be expressed as:
Fanout对象进行扩充, 由服务器指定所述操作命令的有效期或者和所述操作命 令的有效期和所述网关执行操作命令的模式, 例如, 如图 6所示, 在 Fanout对 象中创建对应的 Exp i ry节点和 ExeFlag节点, 所述 Expi ry节点用于承载所述 操作命令的有效期,其可以为 32位 int型数据,以秒为最小单位的递减计数器, 但本发明实施例对此不进行限制, 还可以为其他可以为其他数据类型; 所述 ExeFlag节点用于承载所述网关执行操作命令的模式, 其可以为 int型, 例如, 1表示允许网关在操作命令到期时自动执行, 0表示不允许网关在操作命令到期 时自动执行, 2表示命令已经被执行过, 但本发明实施例对此不进行限制, 还可 以为其他可以为其他数据类型。 The Fanout object is expanded, and the server specifies the validity period of the operation command or the validity period of the operation command and the mode in which the gateway executes the operation command. For example, as shown in FIG. 6, the corresponding Exp i ry is created in the Fanout object. a node and an ExeFlag node, where the Expiry node is used to carry the validity period of the operation command, which may be a 32-bit int type data, a decrement counter in a minimum unit of seconds, but the embodiment of the present invention does not limit this. Other modes may be other data types; the ExeFlag node is used to carry the operation command of the gateway, which may be an int type, for example, 1 means that the gateway is allowed to automatically execute when the operation command expires, and 0 means not allowed. The gateway is automatically executed when the operation command expires, and 2 indicates that the command has been executed. However, the embodiment of the present invention does not limit this, and may be other data types.
所述网关根据操作命令的有效期或者和所述操作命令的有效期和所述网关 执行操作命令的模式, 删除到期的操作命令, 具体包括: The gateway deletes the expired operation command according to the validity period of the operation command or the validity period of the operation command and the mode in which the gateway executes the operation command, and specifically includes:
当所述操作信息中携带有所述操作命令的有效期时, 所述网关根据操作命 令的有效期删除到期的操作命令的方法, 如图 7所示, 包括: When the operation information carries the validity period of the operation command, the gateway deletes the expired operation command according to the validity period of the operation command, as shown in FIG. 7, including:
401、 检测所述操作命令是否在所述有效期内; 若所述操作命令不在所述有 效期内, 则执行步骤 402; 若所述操作命令在所述有效期内, 则执行步骤 401。 401. Detect whether the operation command is within the validity period; if the operation command is not in the valid period, execute step 402; if the operation command is within the validity period, perform step 401.
其中, 检测所述操作命令是否在所述有效期内时, 可以根据预定的时间周 期周期的检测, 也可以实时检测, 本发明实施例对此不进行限制; 当根据预定 的时间周期周期的检测时, 其预定的时间周期可以根据用户的需求设置, 并根 据用户的需求修改, 本发明实施例对此也不进行限制。 Wherein, detecting whether the operation command is within the validity period may be based on a predetermined time period The detection of the period period can also be detected in real time. The embodiment of the present invention does not limit this; when detecting according to a predetermined time period period, the predetermined time period can be set according to the user's needs, and is modified according to the user's needs. This embodiment of the present invention does not limit this.
402、 删除所述操作命令。 402. Delete the operation command.
需要说明的是, 当所述操作信息中今携带有所述操作命令的有效期, 没有 携带所述网关执行操作命令的模式时, 只要所述操作命令不在所述有效期内, 不论所述操作命令是否已被执行, 都将被删除。 It should be noted that, when the operation information carries the validity period of the operation command, and does not carry the mode in which the gateway executes the operation command, as long as the operation command is not in the validity period, whether the operation command is Has been executed, will be deleted.
当所述操作信息中携带有所述操作命令的有效期和所述网关执行操作命令 的模式时, 所述网关根据操作命令的有效期和所述网关执行操作命令的模式, 删除到期的操作命令的方法, 如图 8所示, 包括: When the operation information carries the validity period of the operation command and the mode in which the gateway executes the operation command, the gateway deletes the expired operation command according to the validity period of the operation command and the mode in which the gateway executes the operation command. The method, as shown in Figure 8, includes:
501、 检测所述操作命令是否在所述有效期内; 若所述操作命令不在所述有 效期内, 则执行步骤 502; 若所述操作命令在所述有效期内, 则执行步骤 501。 501: Detect whether the operation command is within the validity period; if the operation command is not in the valid period, execute step 502; if the operation command is within the validity period, perform step 501.
502、 确定所述网关执行操作命令的模式; 若所述网关执行操作命令的模式 为不允许网关在操作命令到期时自动执行, 则执行步骤 503; 若所述网关执行操 作命令的模式为允许网关在操作命令到期时自动执行, 则执行步骤 504。 502. Determine a mode in which the gateway performs an operation command. If the mode in which the gateway executes an operation command is to prevent the gateway from automatically executing when the operation command expires, step 503 is performed; if the mode in which the gateway executes the operation command is allowed When the gateway automatically executes when the operation command expires, step 504 is performed.
503、 删除所述操作命令。 503. Delete the operation command.
504、 确定所述操作命令的执行状态, 所述操作命令的执行状态为未被执行 和已被执行过; 若所述操作命令的执行状态为已被执行过, 则执行步骤 503; 若 所述操作命令的执行状态为未被执行过, 则执行步骤 505。 504. Determine an execution status of the operation command, where an execution status of the operation command is not executed and has been executed; if an execution status of the operation command is performed, step 503 is performed; If the execution status of the operation command is not executed, step 505 is performed.
505、 将所述操作命令发送给对应的目标终端。 505. Send the operation command to a corresponding target terminal.
进一步可选的, 为了方便服务器对终端设备的管理, 该方法还包括: 在删 除所述操作命令之后, 网关向所述服务器发送到期操作命令已被删除的通知消 息。 服务器接收所述网关发送的到期操作命令已被删除的通知消息; 并根据所 述通知消息更新预定义的操作命令执行状态表。 其中, 所述预定义的操作命令 执行状态表至少包括操作命令的操作命令编号、 操作命令名称、 操作命令执行 状态。 Further, in order to facilitate management of the terminal device by the server, the method further includes: after deleting the operation command, the gateway sends a notification message to the server that the expiration operation command has been deleted. The server receives a notification message that the expiration operation command sent by the gateway has been deleted; and updates a predefined operation command execution status table according to the notification message. The predefined operation command execution state table includes at least an operation command number of the operation command, an operation command name, and an operation command execution state.
本发明实施例中, 在向网关发送对目标终端进行管理操作的操作信息时, 在所述操作信息中携带有对所述目标终端进行管理操作的操作命令执行结果的 返回形式; 当该网关接收到目标终端发送的操作命令执行结果后, 在所述操作 命令执行结果具有返回形式的指示时, 按照该返回形式对所述操作命令执行结 果进行处理, 得到符合所述返回形式的操作命令执行结果, 并将符合所述返回 形式的操作命令执行结果发送给所述服务器; 使服务在对操作命令执行结果进 行处理时, 能够按照执行结果的返回形式, 对同一类的执行结果进行批量处理; 与现有技术中服务器逐个处理该执行结果相比, 提高了服务器处理终端执行操 作命令结果的效率。 In the embodiment of the present invention, when the operation information for performing the management operation on the target terminal is sent to the gateway, the operation information carries the operation command execution result of the management operation on the target terminal. Returning form; after the gateway receives the operation command execution result sent by the target terminal, when the operation command execution result has an indication of a return form, processing the execution result of the operation command according to the return form, and obtaining the Returning the operation result of the operation command of the form, and transmitting the execution result of the operation command conforming to the return form to the server; enabling the service to process the execution result of the operation command, according to the return form of the execution result, to the same class Execution results are processed in batches; compared with processing results of the servers one by one in the prior art, the efficiency of the server processing terminal executing the operation command results is improved.
并且, 本发明实施例中, 服务器可以根据管理需求对目标终端执行操作命 令的执行结果指示网关再次对目标终端进行分组, 方便后续操作。 进一步的, 本发明实施例中, 服务器维护了一个管理操作表, 使得被执行命令有记录, 方 便进一步的操作。 Moreover, in the embodiment of the present invention, the server may perform an execution result of the operation command on the target terminal according to the management requirement, and instruct the gateway to group the target terminal again, thereby facilitating subsequent operations. Further, in the embodiment of the present invention, the server maintains a management operation table, so that the executed command has a record, thereby facilitating further operations.
进一步的, 本发明实施例中, 服务器在向网关发送对目标终端进行管理操 作的操作信息时, 所述操作信息携带有所述操作命令的有效期或者所述操作命 令的有效期和所述网关执行操作命令的模式; 使得所述网关根据其删除到期的 操作命令, 节省了网关大量的存储空间。 Further, in the embodiment of the present invention, when the server sends the operation information of the management operation to the target terminal to the gateway, the operation information carries the validity period of the operation command or the validity period of the operation command and the gateway performs an operation. The mode of the command; enables the gateway to save a large amount of storage space of the gateway according to the operation command for deleting the expiration.
本发明实施例提供一种服务器, 包括: 如图 9 所示, 该服务器包括: 第一 发送单元 61、 第一接收单元 62。 The embodiment of the present invention provides a server, including: as shown in FIG. 9, the server includes: a first sending unit 61 and a first receiving unit 62.
第一发送单元 61 , 用于向网关发送对目标终端进行管理操作的操作信息, 所述操作信息中携带有对所述目标终端进行管理操作的操作命令执行结果的返 回形式, 以使得所述网关将所述目标终端返回的操作命令执行结果按照所述返 回形式返回给服务器; 所述返回形式为指示网关如何将目标终端的操作命令执 行结果进行分组的指示信息。 其中, 关于所述返回形式的相关描述, 可以参考 图 1中的步骤 101中的相应描述, 本发明实施例此处将不再赘述。 The first sending unit 61 is configured to send, to the gateway, operation information for performing a management operation on the target terminal, where the operation information carries a return form of an operation command execution result of performing a management operation on the target terminal, so that the gateway is Returning, to the server, the operation command execution result returned by the target terminal according to the return form; the return form is indication information indicating how the gateway groups the operation command execution result of the target terminal. For a description of the returning form, reference may be made to the corresponding description in step 101 in FIG. 1 , and details are not described herein again.
第一接收单元 62 , 用于接收所述网关发送的符合所述返回形式的操作命令 执行结果。 The first receiving unit 62 is configured to receive an operation command execution result that is sent by the gateway and meets the return form.
进一步可选的, 为了方便服务器对该执行结果的进行后续管理操作, 如图 10所示, 该服务器还包括: 第二发送单元 63。 Further, in order to facilitate the server to perform subsequent management operations on the execution result, as shown in FIG. 10, the server further includes: a second sending unit 63.
第二发送单元 63 ,用于在所述第一接收单元 62接收到所述网关发送的具有 所述返回形式的操作命令执行结果之后, 根据后续操作的需要, 向所述网关发 送对所述操作命令执行结果对应的目标终端进行分组的消息, 以使得所述网关 根据所述对所述操作命令执行结果对应的目标终端进行分组的消息, 对所述操 作命令执行结果对应的目标终端进行分组。 其中, 所述第二发送单元 63 , 向所 述网关发送对所述操作命令执行结果对应的目标终端进行分组的消息时, 所述 对所述操作命令执行结果对应的目标终端进行分组的消息中, 可以携带对所述 操作命令执行结果对应的目标终端进行分组的分组条件, 以使得所述网关按照 所述分组条件对所述操作命令执行结果对应的目标终端进行分组; 所述对所述 操作命令执行结果对应的目标终端进行分组的消息中, 也可以不携带对所述操 作命令执行结果对应的目标终端进行分组的分组条件, 网关会根据操作命令执 行结果, 对所述操作命令执行结果对应的目标终端进行分组。 本发明实施例对 此不进行限制。 a second sending unit 63, configured to receive, by the first receiving unit 62, the sent by the gateway After the operation result of the returning operation command is executed, a message for grouping the target terminal corresponding to the execution result of the operation command is sent to the gateway according to the need of the subsequent operation, so that the gateway performs the operation according to the operation. The message that the target terminal corresponding to the command execution result is grouped, and the target terminals corresponding to the execution result of the operation command are grouped. When the second sending unit 63 sends a message to the gateway to group the target terminal corresponding to the execution result of the operation command, the message is grouped in the target terminal corresponding to the execution result of the operation command. And a grouping condition for grouping the target terminal corresponding to the operation result of the operation command, so that the gateway groups the target terminal corresponding to the execution result of the operation command according to the grouping condition; The message that the target terminal corresponding to the command execution result is grouped may not carry the grouping condition for grouping the target terminal corresponding to the execution result of the operation command, and the gateway may execute the result according to the operation command, and the execution result of the operation command is corresponding. The target terminals are grouped. This embodiment of the present invention does not limit this.
进一步可选的, 如图 1 1所示, 该服务器还包括第三发送单元 64。 Further optionally, as shown in FIG. 11, the server further includes a third sending unit 64.
第三发送单元 64 ,用于在所述第一接收单元 62接收到所述网关发送的具有 所述返回形式的操作命令执行结果之后, 向所述网关发送对所述操作命令执行 结果对应的目标终端进行分组的分组条件消息, 所述分组条件消息中携带对所 述操作命令执行结果对应的目标终端进行分组的分组条件, 以使得所述网关根 据所述分组条件对所述操作命令执行结果对应的目标终端进行分组。 a third sending unit 64, configured to send, to the gateway, a target corresponding to the execution result of the operation command after the first receiving unit 62 receives the execution result of the operation command with the return form sent by the gateway And a packet condition message that is sent by the terminal, where the packet condition message carries a grouping condition for grouping the target terminal corresponding to the operation result of the operation command, so that the gateway corresponds to the execution result of the operation command according to the grouping condition. The target terminals are grouped.
进一步可选的, 为了实现异步管理, 如图 12所示, 该服务器还包括: 第一 更新单元 65。 Further, in order to implement asynchronous management, as shown in FIG. 12, the server further includes: a first updating unit 65.
第一更新单元 65 ,用于在所述第一接收单元 62接收到所述网关发送的符合 所述返回形式的操作命令执行结果之后, 根据所述操作命令执行结果更新预定 义的管理操作表, 所述管理操作表中包含操作命令编号、 操作命令名称、 目标 终端的路径、 操作命令执行结果标识。 The first update unit 65 is configured to: after the first receiving unit 62 receives the execution result of the operation command that is sent by the gateway and meets the return form, update the predefined management operation table according to the operation command execution result, The management operation table includes an operation command number, an operation command name, a path of the target terminal, and an operation command execution result identifier.
进一步的, 为了将一些服务器无法继续触发操作命令及时的从网关中删除, 以便使网关节省网关存储空间, 在所述第一发送单元 61向网关发送对目标终端 进行管理操作的操作信息时, 所述操作信息携带有所述操作命令的有效期或者 携带所述操作命令的有效期和所述网关执行操作命令的模式, 以使得所述网关 删除到期的操作命令; 所述网关执行操作命令的模式包括允许网关在操作命令 到期时自动执行和不允许网关在操作命令到期时自动执行。 其中, 关于允许网 关在操作命令到期时自动执行和不允许网关在操作命令到期时自动执行的具体 描述, 可以参考图 4的步骤 305中的相应描述, 本发明实施例此处将不再赘述。 Further, in order to prevent some servers from continuing to trigger the operation command to be deleted from the gateway in time, so that the gateway saves the gateway storage space, when the first sending unit 61 sends the operation information of the management operation to the target terminal to the gateway, The operation information carries an expiration date of the operation command or a mode of carrying the operation command and a mode in which the gateway executes an operation command, so that the gateway Deleting the expired operation command; the mode in which the gateway executes the operation command includes allowing the gateway to automatically execute when the operation command expires and not allowing the gateway to automatically execute when the operation command expires. For a specific description about allowing the gateway to automatically execute and disallow the gateway to be automatically executed when the operation command expires, refer to the corresponding description in step 305 of FIG. 4, and the embodiment of the present invention will no longer be used herein. Narration.
进一步可选的, 如图 13所示, 所述服务器还包括: 第三接收单元 66、 第二 更新操作单元 67。 Further, as shown in FIG. 13, the server further includes: a third receiving unit 66 and a second updating operating unit 67.
第三接收单元 66 , 用于接收所述网关发送的到期操作命令已被删除的通知 消息。 The third receiving unit 66 is configured to receive a notification message that the expiration operation command sent by the gateway has been deleted.
第二更新操作单元 67 ,根据所述第二接收单元 66接收的所述通知消息更新 预定义的操作命令执行状态表。 The second update operation unit 67 updates the predefined operation command execution status table according to the notification message received by the second receiving unit 66.
需要说明的是, 本发明实施例提供的服务器所包含各个功能模块的其他描 述, 可以参考图 1至图 8中的相关描述, 本发明实施例此处将不再赘述。 It should be noted that other descriptions of the various functional modules included in the server provided by the embodiment of the present invention may be referred to the related descriptions in FIG. 1 to FIG.
本发明实施例还提供一种网关, 如图 14所示, 该网关包括: 第一接收单元 71、 第一发送单元 72、 第二接收单元 73、 操作单元 74、 第二发送单元 75。 The embodiment of the present invention further provides a gateway. As shown in FIG. 14, the gateway includes: a first receiving unit 71, a first sending unit 72, a second receiving unit 73, an operating unit 74, and a second sending unit 75.
第一接收单元 71 , 用于接收服务器发送的对目标终端进行管理操作的操作 信息。 The first receiving unit 71 is configured to receive operation information sent by the server for performing a management operation on the target terminal.
第一发送单元 72 ,用于根据所述第一接收单元 71接收的所述操作信息向所 述目标终端发送对应的操作命令。 The first sending unit 72 is configured to send a corresponding operation command to the target terminal according to the operation information received by the first receiving unit 71.
第二接收单元 73 , 用于接收所述目标终端发送的所述操作命令的操作命令 执行结果。 The second receiving unit 73 is configured to receive an operation command execution result of the operation command sent by the target terminal.
操作单元 74 , 用于在所述操作命令执行结果具有返回形式的指示时, 根据 所指示的操作命令执行结果的返回形式, 对所述第二接收单元 73接收到的所述 操作命令执行结果进行处理, 得到符合所述返回形式的操作命令执行结果。 The operation unit 74 is configured to: when the operation command execution result has an indication of a return form, perform the operation command execution result received by the second receiving unit 73 according to the returned form of the indicated operation command execution result Processing, obtaining an operation command execution result that conforms to the return form.
第二发送单元 75 ,用于将所述操作单元 74得到的符合所述返回形式的操作 命令执行结果发送给所述服务器。 The second sending unit 75 is configured to send the operation result of the operation command obtained by the operation unit 74 in accordance with the return form to the server.
进一步可选的, 如图 15所示, 所述网关还包括: 第一确定单元 76。 Further, as shown in FIG. 15, the gateway further includes: a first determining unit 76.
第一确定单元 76 ,用于在所述第二接收单元 73接收所述目标终端发送的所 述操作命令的操作命令执行结果之后, 确定所述网关中是否存储有所述操作命 令执行结果的返回形式。 a first determining unit 76, configured to determine, after the second receiving unit 73 receives an operation command execution result of the operation command sent by the target terminal, whether the operation life is stored in the gateway The return form of the execution result.
所述操作单元 74还用于, 在所述第一确定单元 76确定所述网关中存储有 所述操作命令执行结果的返回形式时, 根据所述存储的返回形式对所述操作命 令执行结果进行处理, 得到符合所述返回形式的操作命令执行结果。 The operation unit 74 is further configured to: when the first determining unit 76 determines that the return form of the operation command execution result is stored in the gateway, perform the operation command execution result according to the stored return form Processing, obtaining an operation command execution result that conforms to the return form.
第二发送单元 75还用于, 在所述第一确定单元 76确定所述确定网关中没 有存储所述操作命令执行结果的返回形式时, 将所述操作命令执行结果发送给 所述服务器。 The second sending unit 75 is further configured to: when the first determining unit 76 determines that the returning form of the operation command execution result is not stored in the determining gateway, send the operation command execution result to the server.
进一步可选的, 如图 16所示, 所述网关还包括: 第三接收单元 77、 分组操 作单元 78、 第三发送单元 79。 Further, as shown in FIG. 16, the gateway further includes: a third receiving unit 77, a grouping operation unit 78, and a third sending unit 79.
第三接收单元 77 ,用于在所述第二发送单元 75将符合所述返回形式的操作 命令执行结果发送给所述服务器之后, 接收所述服务器发送的对所述操作命令 执行结果对应的目标终端进行分组的消息; 其中, 所述消息中可以携带对所述 操作命令执行结果对应的目标终端进行分组的分组条件, 也可以不携带对所述 分组操作单元 78 ,用于根据所述第三接收单元 77接收的对所述操作命令执 行结果对应的目标终端进行分组的消息, 对所述操作命令执行结果对应的目标 终端进行分组。 a third receiving unit 77, configured to receive, after the second sending unit 75 sends an operation command execution result that conforms to the return form to the server, a target corresponding to the execution result of the operation command sent by the server a message that the terminal performs grouping; wherein the message may carry a grouping condition for grouping the target terminal corresponding to the operation result of the operation command, or may not carry the grouping operation unit 78 for the third The message received by the receiving unit 77 for grouping the target terminals corresponding to the execution result of the operation command is grouped by the target terminal corresponding to the execution result of the operation command.
其中, 所述分组操作单元 78根据所述第三接收单元 77接收的对所述操作 命令执行结果对应的目标终端进行分组的消息, 对所述操作命令执行结果对应 的目标终端进行分组具体包括: 当第三接收单元 77接收的对所述操作命令执行 结果对应的目标终端进行分组的消息中, 携带对所述操作命令执行结果对应的 目标终端进行分组的分组条件时, 所述分组操作单元 78用于根据所述分组条件 对所述操作命令执行结果对应的目标终端进行分组; 当所述第三接收单元 77接 收的对所述操作命令执行结果对应的目标终端进行分组的消息中, 没有携带对 所述操作命令执行结果对应的目标终端进行分组的分组条件时, 所述分组操作 单元 78用于按照所述操作命令执行结果, 对所述操作命令执行结果对应的目标 终端进行分组, 每组包含相同所述操作命令执行结果对应的目标终端。 The grouping operation unit 78, according to the message that the target terminal corresponding to the execution result of the operation command is received by the third receiving unit 77, grouping the target terminal corresponding to the execution result of the operation command, specifically includes: When the message received by the third receiving unit 77 for grouping the target terminal corresponding to the execution result of the operation command carries a grouping condition for grouping the target terminal corresponding to the execution result of the operation command, the grouping operation unit 78 The target terminal corresponding to the execution result of the operation command is grouped according to the grouping condition; when the message received by the third receiving unit 77 for grouping the target terminal corresponding to the execution result of the operation command is not carried, When the grouping condition of the target terminal corresponding to the operation command execution result is grouped, the grouping operation unit 78 is configured to group the target terminals corresponding to the operation command execution result according to the operation command execution result, each group Contains the same operation command execution result pair The target terminal should be.
第三发送单元 79 , 用于将对所述操作命令执行结果对应的目标终端进行分 组的执行结果发送给所述服务器。 a third sending unit 79, configured to divide the target terminal corresponding to the execution result of the operation command The execution result of the group is sent to the server.
进一步可选的, 如图 17所示, 所述网关还包括: 第四接收单元 710。 Further, as shown in FIG. 17, the gateway further includes: a fourth receiving unit 710.
第四接收单元 710 , 用于在所述第二发送单元 75将符合所述返回形式的操 作命令执行结果发送给所述服务器之后, 接收所述服务器发送的对所述操作命 The fourth receiving unit 710 is configured to: after the second sending unit 75 sends an operation command execution result that conforms to the return form to the server, receive the operation sent by the server
所述分组操作单元 78用于根据所述分组条件对所述操作命令执行结果对应 的目标终端进行分组。 The grouping operation unit 78 is configured to group the target terminals corresponding to the execution result of the operation command according to the grouping condition.
另外, 需要说明的是, 在异步传输的过程中, 若所述网关仅接收到对所述 操作命令执行结果对应的目标终端进行分组的消息, 而没有接收到所述分组条 件信息, 则默认按照所述操作命令执行结果进行分组, 每组包含相同所述操作 命令执行结果对应的目标终端。 In addition, it is to be noted that, in the process of asynchronous transmission, if the gateway only receives the message that the target terminal corresponding to the operation command execution result is grouped, but does not receive the grouping condition information, the default is as follows. The operation command execution result is grouped, and each group includes a target terminal corresponding to the execution result of the same operation command.
进一步可选的, 如图 18所示, 所述网关还包括: 检测单元 711、 删除单元 Further, as shown in FIG. 18, the gateway further includes: a detecting unit 711, a deleting unit
712。 712.
检测单元 711 , 用于在所述第一接收单元 71接收到的所述操作信息中携带 有所述操作命令的有效期时, 检测所述操作命令是否在所述有效期内。 The detecting unit 711 is configured to detect, when the validity period of the operation command is carried in the operation information received by the first receiving unit 71, whether the operation command is within the validity period.
删除单元 712 ,用于在所述检测单元 711检测到所述操作命令不在所述有效 期内时, 删除所述操作命令。 The deleting unit 712 is configured to delete the operation command when the detecting unit 711 detects that the operation command is not within the validity period.
进一步可选的, 如图 19所示, 所述网关还包括: 第二确定单元 71 3、 第三 确定单元 714、 第四发送单元 715。 Further, as shown in FIG. 19, the gateway further includes: a second determining unit 71 3, a third determining unit 71 4 , and a fourth sending unit 715.
所述检测单元 711还用于, 在所述第一接收单元 71接收到的所述操作信息 中携带有所述操作命令的有效期和所述网关执行操作命令的模式, 所述网关执 行操作命令的模式包括允许网关在操作命令到期时自动执行和不允许网关在操 作命令到期时自动执行时, 检测所述操作命令是否在所述有效期内。 The detecting unit 711 is further configured to: in the operation information received by the first receiving unit 71, a validity period of the operation command and a mode in which the gateway executes an operation command, where the gateway executes an operation command The mode includes allowing the gateway to automatically execute when the operation command expires and not allowing the gateway to automatically execute when the operation command expires, detecting whether the operation command is within the validity period.
第二确定单元 71 3 ,用于在所述检测单元 711检测到所述操作命令不在所述 有效期内时, 确定所述网关执行操作命令的模式。 The second determining unit 71 3 is configured to determine, when the detecting unit 711 detects that the operation command is not within the validity period, determine a mode in which the gateway executes an operation command.
所述删除单元 712还用于, 在所述第二确定单元 71 3确定所述网关执行操 作命令的模式为不允许网关在操作命令到期时自动执行时, 删除所述操作命令。 第三确定单元 714 ,用于在所述第二确定单元 71 3确定所述网关执行操作命 令的模式为允许网关在操作命令到期时自动执行时, 确定所述操作命令的执行 状态, 所述操作命令的执行状态为未被执行和已被执行过。 The deleting unit 712 is further configured to: when the second determining unit 71 determines that the mode in which the gateway executes the operation command is to prevent the gateway from automatically executing when the operation command expires, deleting the operation command. The third determining unit 714 is configured to determine, in the second determining unit 71 3, that the mode in which the gateway executes the operation command is to allow the gateway to automatically execute when the operation command expires, determine an execution state of the operation command, The execution status of the operation command is not executed and has been executed.
所述删除单元 712还用于, 在所述第三确定单元 714确定所述操作命令的 执行状态为已被执行过时, 删除所述操作命令。 The deleting unit 712 is further configured to delete the operation command when the third determining unit 714 determines that the execution state of the operation command is that it has been executed.
第四发送单元 715 ,用于在所述第三确定单元 714确定所述操作命令的执行 状态为未被执行过时, 将所述操作命令发送给对应的目标终端。 The fourth sending unit 715 is configured to send the operation command to the corresponding target terminal when the third determining unit 714 determines that the execution state of the operation command is not performed.
进一步可选的, 如图 20所示, 所述网关还包括: 第五发送单元 716。 Further, as shown in FIG. 20, the gateway further includes: a fifth sending unit 716.
第五发送单元 716 , 用于在所述删除单元 712删除所述操作命令之后, 向所 述服务器发送到期操作命令已被删除的通知消息。 The fifth sending unit 716 is configured to send, to the server, a notification message that the expiration operation command has been deleted after the deleting unit 712 deletes the operation command.
需要说明的是, 本发明实施例提供的网关所包含各个功能模块的其他描述, 可以参考图 1至图 8中的相关描述, 本发明实施例此处将不再赘述。 It should be noted that, for other descriptions of the various functional modules included in the gateway provided by the embodiment of the present invention, reference may be made to the related description in FIG. 1 to FIG. 8 , which will not be further described herein.
本发明实施例还提供一种管理终端的系统, 如图 21所示, 该系统包括: 服 务器 81、 网关 82。 The embodiment of the present invention further provides a system for managing a terminal. As shown in FIG. 21, the system includes: a server 81 and a gateway 82.
服务器 81 , 用于向网关 82发送对目标终端进行管理操作的操作信息, 所述 操作信息中携带对所述目标终端进行管理操作的操作命令执行结果的返回形 式, 以便所述网关 82将所述目标终端返回的操作命令执行结果按照所述返回形 式返回给服务器 81 , 所述返回形式为指示网关如何将目标终端的操作命令执行 结果进行分组的指示信息; 接收所述网关 82发送的具有所述返回形式的操作命 令执行结果。 The server 81 is configured to send, to the gateway 82, operation information for performing a management operation on the target terminal, where the operation information carries a return form of an operation command execution result of performing a management operation on the target terminal, so that the gateway 82 The operation result returned by the target terminal is returned to the server 81 according to the return form, and the return form is indication information indicating how the gateway groups the operation command execution result of the target terminal; and receiving the gateway 82 to send the Returns the form of the operation command execution result.
网关 82 , 用于接收所述服务器 81发送的所述操作信息; 根据所述操作信息 向所述目标终端发送对应的操作命令, 并接收所述目标终端发送的所述操作命 令的操作命令执行结果; 在所述操作命令执行结果具有返回形式的指示时, 根 据指示的操作命令执行结果的返回形式, 对所述操作命令执行结果进行处理, 得到符合所述返回形式的操作命令执行结果; 将符合所述返回形式的操作命令 执行结果发送给所述服务器 81。 The gateway 82 is configured to receive the operation information sent by the server 81, send a corresponding operation command to the target terminal according to the operation information, and receive an operation command execution result of the operation command sent by the target terminal. When the operation command execution result has an indication of a return form, according to the returned form of the indicated operation command execution result, the operation command execution result is processed to obtain an operation command execution result that conforms to the return form; The return operation command execution result is sent to the server 81.
需要说明的是, 本发明实施例提供的网关所包含各个功能模块的其他描述, 可以参考图 1至图 18中的相关描述, 本发明实施例此处将不再赘述。 本发明实施例中, 在向网关发送对目标终端进行管理操作的操作信息时, 在所述操作信息中携带有对所述目标终端进行管理操作的操作命令执行结果的 返回形式; 当该网关接收到目标终端发送的操作命令执行结果后, 在所述操作 命令执行结果具有返回形式的指示时, 按照该返回形式对所述操作命令执行结 果进行处理, 得到符合所述返回形式的操作命令执行结果, 并将符合所述返回 形式的操作命令执行结果发送给所述服务器; 使服务在对操作命令执行结果进 行处理时, 能够按照执行结果的返回形式, 对同一类的执行结果进行批量处理; 与现有技术中服务器逐个处理该执行结果相比, 提高了服务器处理终端执行操 作命令结果的效率。 It should be noted that other descriptions of the various functional modules included in the gateway provided by the embodiment of the present invention may be referred to the related description in FIG. 1 to FIG. 18, and details are not described herein again. In the embodiment of the present invention, when the operation information for performing the management operation on the target terminal is sent to the gateway, the operation information carries a return form of the execution result of the operation command for performing the management operation on the target terminal; when the gateway receives After the execution result of the operation command sent by the target terminal, when the operation command execution result has an indication of a return form, the operation result execution result is processed according to the return form, and an operation command execution result conforming to the return form is obtained. And sending an operation result execution result conforming to the return form to the server; enabling the service to perform batch processing on the execution result of the same type according to the return form of the execution result when processing the execution result of the operation command; In the prior art, the server processes the execution result one by one, and improves the efficiency of the server processing terminal executing the operation command result.
并且, 本发明实施例中, 服务器可以根据管理需求对目标终端执行操作命 令的执行结果指示网关再次对目标终端进行分组, 方便后续操作。 进一步的, 本发明实施例中, 服务器维护了一个管理操作表, 使得被执行命令有记录, 方 便进一步的操作。 Moreover, in the embodiment of the present invention, the server may perform an execution result of the operation command on the target terminal according to the management requirement, and instruct the gateway to group the target terminal again, thereby facilitating subsequent operations. Further, in the embodiment of the present invention, the server maintains a management operation table, so that the executed command has a record, thereby facilitating further operations.
进一步的, 本发明实施例中, 服务器在向网关发送对目标终端进行管理操 作的操作信息时, 所述操作信息携带有所述操作命令的有效期或者所述操作命 令的有效期和所述网关执行操作命令的模式; 使得所述网关根据其删除到期的 操作命令, 节省了网关大量的存储空间。 Further, in the embodiment of the present invention, when the server sends the operation information of the management operation to the target terminal to the gateway, the operation information carries the validity period of the operation command or the validity period of the operation command and the gateway performs an operation. The mode of the command; enables the gateway to save a large amount of storage space of the gateway according to the operation command for deleting the expiration.
通过以上的实施方式的描述, 所属领域的技术人员可以清楚地了解到本发 明可借助软件加必需的通用硬件的方式来实现, 当然也可以通过硬件, 但 4艮多 情况下前者是更佳的实施方式。 基于这样的理解, 本发明的技术方案本质上或 者说对现有技术做出贡献的部分可以以软件产品的形式体现出来, 该计算机软 件产品存储在可读取的存储介质中, 如计算机的软盘, 硬盘或光盘等, 包括若 干指令用以使得一台计算机设备(可以是个人计算机, 服务器, 或者网络设备 等)执行本发明各个实施例所述的方法。 Through the description of the above embodiments, those skilled in the art can clearly understand that the present invention can be implemented by means of software plus necessary general hardware, and of course, by hardware, but in the case of more than 4, the former is better. Implementation. Based on such understanding, the technical solution of the present invention, which is essential or contributes to the prior art, may be embodied in the form of a software product stored in a readable storage medium, such as a floppy disk of a computer. A hard disk or optical disk or the like includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform the methods described in various embodiments of the present invention.
以上所述, 仅为本发明的具体实施方式, 但本发明的保护范围并不局限于此, 任何熟悉本技术领域的技术人员在本发明揭露的技术范围内, 可轻易想到变化 或替换, 都应涵盖在本发明的保护范围之内。 因此, 本发明的保护范围应以所 述权利要求的保护范围为准。 The above is only the specific embodiment of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily think of changes or substitutions within the technical scope of the present invention. It should be covered by the scope of the present invention. Therefore, the scope of protection of the present invention should be The scope of protection of the claims is subject to.
Claims
Priority Applications (3)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| EP12802233.2A EP2645629B1 (en) | 2011-06-22 | 2012-06-05 | Terminal management method and device |
| ES12802233.2T ES2690084T3 (en) | 2011-06-22 | 2012-06-05 | Terminal and device management method |
| US14/136,888 US9832075B2 (en) | 2011-06-22 | 2013-12-20 | Terminal management method and apparatus |
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201110169708.6A CN102843251B (en) | 2011-06-22 | 2011-06-22 | The method and apparatus of office terminal |
| CN201110169708.6 | 2011-06-22 |
Related Child Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| US14/136,888 Continuation US9832075B2 (en) | 2011-06-22 | 2013-12-20 | Terminal management method and apparatus |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2012174987A1 true WO2012174987A1 (en) | 2012-12-27 |
Family
ID=47370328
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2012/076478 Ceased WO2012174987A1 (en) | 2011-06-22 | 2012-06-05 | Terminal management method and device |
Country Status (5)
| Country | Link |
|---|---|
| US (1) | US9832075B2 (en) |
| EP (1) | EP2645629B1 (en) |
| CN (1) | CN102843251B (en) |
| ES (1) | ES2690084T3 (en) |
| WO (1) | WO2012174987A1 (en) |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| KR102401645B1 (en) | 2015-05-22 | 2022-05-25 | 삼성전자주식회사 | Electronic device and gateway and method for controlling thereof |
Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN1859177A (en) * | 2005-11-10 | 2006-11-08 | 华为技术有限公司 | Method for processing customized task in equipment management |
| KR100661006B1 (en) * | 2005-12-28 | 2006-12-22 | 주식회사 케이티 | Home network terminal management system and method |
| KR100818962B1 (en) * | 2007-06-12 | 2008-04-04 | (재)대구경북과학기술연구원 | Remote Management Methods for Mobile Devices |
Family Cites Families (18)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US6662205B1 (en) * | 1996-10-01 | 2003-12-09 | International Business Machines Corporation | Scaleable and extensible system management architecture with dataless endpoints |
| CN100479575C (en) * | 2005-06-30 | 2009-04-15 | 华为技术有限公司 | Method and apparatus for realizing scheduled operation in equipment management |
| CN100499494C (en) * | 2005-09-13 | 2009-06-10 | 华为技术有限公司 | System for tele-managing local network device and realization method |
| US7903585B2 (en) * | 2006-02-15 | 2011-03-08 | Cisco Technology, Inc. | Topology discovery of a private network |
| US8752006B1 (en) * | 2007-07-02 | 2014-06-10 | Cisco Technology, Inc. | System and method and apparatus for automatically generating computer code for remote procedure calls |
| US7924853B1 (en) * | 2007-10-04 | 2011-04-12 | Sprint Communications Company L.P. | Method of maintaining a communication network |
| US20090204578A1 (en) * | 2008-02-12 | 2009-08-13 | Microsoft Corporation | Targeted queries using an oma dm protocol |
| US8566961B2 (en) * | 2008-08-08 | 2013-10-22 | Absolute Software Corporation | Approaches for a location aware client |
| US8213924B2 (en) * | 2008-10-06 | 2012-07-03 | Facebook, Inc. | Providing distributed online services for mobile devices |
| WO2010051837A1 (en) * | 2008-11-05 | 2010-05-14 | Telefonaktiebolaget L M Ericsson (Publ) | Conditional execution of commands |
| US8078712B2 (en) * | 2008-11-26 | 2011-12-13 | Red Hat, Inc. | Systems and methods for network command delegation using auto-discovered pathways |
| JP5272702B2 (en) * | 2008-12-16 | 2013-08-28 | 富士通株式会社 | Mobile network system and guidance message providing method |
| CN101635895B (en) * | 2009-07-31 | 2014-03-12 | 青岛海信移动通信技术股份有限公司 | Website content subscribing system, website content subscribing method, mobile communication terminal and server |
| US10051074B2 (en) * | 2010-03-29 | 2018-08-14 | Samsung Electronics Co, Ltd. | Techniques for managing devices not directly accessible to device management server |
| CN101882161B (en) | 2010-06-23 | 2012-07-04 | 中国工商银行股份有限公司 | Application level asynchronous task scheduling system and method |
| CN102457395B (en) * | 2010-10-26 | 2014-12-24 | 华为终端有限公司 | Method and equipment for managing terminal in equipment management system |
| CN102142980B (en) * | 2010-10-27 | 2014-05-07 | 华为技术有限公司 | Method and gateway for remotely managing sensor network topology |
| RU2446457C1 (en) * | 2010-12-30 | 2012-03-27 | Закрытое акционерное общество "Лаборатория Касперского" | System and method for remote administration of personal computers within network |
-
2011
- 2011-06-22 CN CN201110169708.6A patent/CN102843251B/en active Active
-
2012
- 2012-06-05 WO PCT/CN2012/076478 patent/WO2012174987A1/en not_active Ceased
- 2012-06-05 EP EP12802233.2A patent/EP2645629B1/en active Active
- 2012-06-05 ES ES12802233.2T patent/ES2690084T3/en active Active
-
2013
- 2013-12-20 US US14/136,888 patent/US9832075B2/en active Active
Patent Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN1859177A (en) * | 2005-11-10 | 2006-11-08 | 华为技术有限公司 | Method for processing customized task in equipment management |
| KR100661006B1 (en) * | 2005-12-28 | 2006-12-22 | 주식회사 케이티 | Home network terminal management system and method |
| KR100818962B1 (en) * | 2007-06-12 | 2008-04-04 | (재)대구경북과학기술연구원 | Remote Management Methods for Mobile Devices |
Non-Patent Citations (1)
| Title |
|---|
| See also references of EP2645629A4 * |
Also Published As
| Publication number | Publication date |
|---|---|
| US20140108637A1 (en) | 2014-04-17 |
| EP2645629A4 (en) | 2013-11-27 |
| CN102843251A (en) | 2012-12-26 |
| CN102843251B (en) | 2016-03-30 |
| ES2690084T3 (en) | 2018-11-19 |
| US9832075B2 (en) | 2017-11-28 |
| EP2645629A1 (en) | 2013-10-02 |
| EP2645629B1 (en) | 2018-08-08 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN111869177A (en) | A method and device for updating a UE policy, and a computer storage medium | |
| WO2013170410A1 (en) | Group communication method and system, group server and group member device | |
| CN111601353A (en) | Routing method of application program and related device | |
| WO2010028571A1 (en) | Large data object transmission method, transmission system, transmitting device and receiving device | |
| WO2015127889A1 (en) | Profile association management method and device | |
| CN101674198A (en) | Method and device for realizing stacking | |
| WO2014101731A1 (en) | System and method for opening network capabilities, and related network elements | |
| WO2009076866A1 (en) | Method, system and device for remote control terminal | |
| CN107566377B (en) | Method for carrying out multi-protocol adaptation on charging device and charging device | |
| WO2015180251A1 (en) | Wake-on-lan method, server, and client | |
| CN110337137B (en) | Packet filtering method, device and system | |
| CN106302638B (en) | Data management method, forwarding equipment and system | |
| US10904746B2 (en) | Implementation method, apparatus and system for remote access | |
| CN105376706B (en) | A method and device for subscribing to device location information | |
| CN109728932B (en) | SDN setting method, controller, switch and computer readable storage medium | |
| WO2009146650A1 (en) | Method for erasing data of terminal and terminal device | |
| WO2012174987A1 (en) | Terminal management method and device | |
| WO2015074395A1 (en) | Data packet forwarding method, apparatus and system | |
| CN103987017B (en) | A method and system for establishing service access in WLAN | |
| CN100542103C (en) | Method and device for hot upgrading network processor | |
| CN106878352A (en) | A method for realizing remote access, AllJoyn gateway agent, cloud server and mobile device | |
| WO2013017020A1 (en) | Method and system for operating executable node | |
| CN111371843B (en) | Data storage method and device | |
| WO2012075965A1 (en) | Method, apparatus and system for device management | |
| WO2010139264A1 (en) | Network element registration subsystem, telecommunication value-added service system and network element registration method |
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: 12802233 Country of ref document: EP Kind code of ref document: A1 |
|
| WWE | Wipo information: entry into national phase |
Ref document number: 2012802233 Country of ref document: EP |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |