WO2021184216A1 - 物联网通信方法及装置 - Google Patents

物联网通信方法及装置 Download PDF

Info

Publication number
WO2021184216A1
WO2021184216A1 PCT/CN2020/079776 CN2020079776W WO2021184216A1 WO 2021184216 A1 WO2021184216 A1 WO 2021184216A1 CN 2020079776 W CN2020079776 W CN 2020079776W WO 2021184216 A1 WO2021184216 A1 WO 2021184216A1
Authority
WO
WIPO (PCT)
Prior art keywords
subscription
target resource
information
client
server
Prior art date
Application number
PCT/CN2020/079776
Other languages
English (en)
French (fr)
Inventor
吕小强
Original Assignee
Oppo广东移动通信有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Oppo广东移动通信有限公司 filed Critical Oppo广东移动通信有限公司
Priority to KR1020227032596A priority Critical patent/KR20220155307A/ko
Priority to JP2022556458A priority patent/JP2023524367A/ja
Priority to PCT/CN2020/079776 priority patent/WO2021184216A1/zh
Priority to EP20926201.3A priority patent/EP4109835A4/en
Priority to CN202080095226.8A priority patent/CN115053507A/zh
Publication of WO2021184216A1 publication Critical patent/WO2021184216A1/zh
Priority to US17/945,294 priority patent/US20230017797A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/51Discovery or management thereof, e.g. service location protocol [SLP] or web services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0866Checking the configuration
    • H04L41/0869Validating the configuration within one network element
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16YINFORMATION AND COMMUNICATION TECHNOLOGY SPECIALLY ADAPTED FOR THE INTERNET OF THINGS [IoT]
    • G16Y10/00Economic sectors
    • G16Y10/75Information technology; Communication
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16YINFORMATION AND COMMUNICATION TECHNOLOGY SPECIALLY ADAPTED FOR THE INTERNET OF THINGS [IoT]
    • G16Y40/00IoT characterised by the purpose of the information processing
    • G16Y40/30Control
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16YINFORMATION AND COMMUNICATION TECHNOLOGY SPECIALLY ADAPTED FOR THE INTERNET OF THINGS [IoT]
    • G16Y40/00IoT characterised by the purpose of the information processing
    • G16Y40/40Maintenance of things
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/12Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
    • H04L67/125Protocols 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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/55Push-based network services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/28Timers or timing mechanisms used in protocols
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/70Services for machine-to-machine communication [M2M] or machine type communication [MTC]

Definitions

  • the present invention relates to the field of communication technology, in particular to an Internet of Things communication method and device.
  • the subscription/push technology in the Internet of Things system can not only be applied to the information transmission between the device and the cloud platform (device to cloud, D2C), but also can be applied to the business processing layer under the application layer and the device to device communication (device to device, D2D) field.
  • D2C device to cloud
  • D2D device to device communication
  • the mobile phone subscribes to the temperature of the thermometer at home, and when the temperature of the thermometer exceeds the set value, the air conditioner is turned on.
  • the one that sends out subscription information can act as a client, and the one that provides target resources can act as a server.
  • the client may actively cancel the subscription relationship to the target resource.
  • the client can actively forget the subscription relationship to the target resource.
  • the client sends a request message to the server, and the subscription identifier (obs) in the request message can be set to cancel the subscription, so that the server cancels the client's subscription to the target resource.
  • the server may clear the subscription relationship between the target resource and the client due to reboots and other situations.
  • the client does not know that the server has cleared the subscription relationship between the target resource and the client. Unable to re-subscribe the target resource in time.
  • the embodiments of the present invention provide an Internet of Things communication method and device to solve the problem in the prior art that the client cannot re-subscribe to the target resource in a timely manner after the server clears the subscription relationship between the target resource and the client.
  • the first aspect of the present invention provides an Internet of Things communication method, which is applied to a client, and includes:
  • the second aspect of the present invention provides an Internet of Things communication method, which is applied to the server, and includes:
  • the subscription response information is used to indicate that the client successfully subscribes to the target resource, and the subscription response information includes the validity period of the current state of the target resource;
  • the third aspect of the present invention provides an Internet of Things communication method, which is applied to the server, and includes:
  • the fourth aspect of the present invention provides an Internet of Things communication method, which is applied to a client, and includes:
  • the unsubscription information resending the subscription information of the target resource to the server.
  • a fifth aspect of the present invention provides an Internet of Things communication device, including:
  • a sending module configured to send subscription information to the server, where the subscription information is used to request a subscription to the target resource on the server;
  • a receiving module configured to receive subscription response information sent by the server, where the subscription response information is used to characterize that the IoT communication device successfully subscribes to the target resource, and the subscription response information includes the validity period of the target resource;
  • the sending module is further configured to resend the subscription information of the target resource to the server after the subscription time of the target resource exceeds the validity period of the target resource.
  • a sixth aspect of the present invention provides an Internet of Things communication device, including:
  • the receiving module is configured to receive subscription information sent by the client, where the subscription information is used to request a subscription to the target resource on the Internet of Things communication device;
  • a sending module configured to send subscription response information to the client, where the subscription response information is used to indicate that the client successfully subscribes to the target resource, and the subscription response information includes the validity period of the target resource;
  • the receiving module is configured to receive the subscription information of the target resource re-sent by the client after the subscription time of the target resource exceeds the validity period of the target resource.
  • a seventh aspect of the present invention provides an Internet of Things communication device, including:
  • a processing module for determining to release the subscription relationship between the client and the target resource on the IoT communication device
  • a sending module configured to send unsubscription information to the client, where the unsubscription information is used to notify the client that the server cancels the subscription relationship of the target resource;
  • the receiving module is further configured to receive the subscription information of the target resource re-sent by the client.
  • An eighth aspect of the present invention provides an Internet of Things communication device, including:
  • a receiving module configured to receive unsubscription information sent by a server, where the unsubscription information is used to notify a client that the server cancels the subscription relationship of the target resource;
  • the sending module is configured to resend the subscription information of the target resource to the server according to the unsubscription information.
  • a ninth aspect of the present invention provides a client, the client includes: a processor, a memory, a transmitter, and a receiver; the transmitter and the receiver are coupled to the processor, and the processor controls The sending action of the transmitter, and the processor controlling the receiving action of the receiver;
  • the memory is used to store computer executable program code, and the program code includes information; when the processor executes the information, the information causes the network device to execute the Internet of Things communication method provided in the first and fourth aspects.
  • a tenth aspect of the present invention provides a server, the client includes: a processor, a memory, a transmitter, and a receiver; the transmitter and the receiver are coupled to the processor, and the processor controls The sending action of the transmitter, and the processor controlling the receiving action of the receiver;
  • the memory is used to store computer executable program code, and the program code includes information; when the processor executes the information, the information causes the network device to execute the Internet of Things communication method provided in the second and third aspects.
  • An eleventh aspect of the present invention provides a chip, including: a processor, configured to call and run a computer program from a memory, so that a device installed with the chip executes the Internet of Things provided in the first and fourth aspects Communication method.
  • a twelfth aspect of the present invention provides a chip, including: a processor, configured to call and run a computer program from a memory, so that the device installed with the chip executes the Internet of Things provided in the second and third aspects Communication method.
  • a thirteenth aspect of the present invention provides a computer-readable storage medium for storing a computer program that enables a computer to execute the Internet of Things communication method provided in the first and fourth aspects.
  • a fourteenth aspect of the present invention provides a computer-readable storage medium for storing a computer program that enables a computer to execute the Internet of Things communication method provided in the second and third aspects.
  • the fifteenth aspect of the present invention provides a computer program product, including computer program information, which enables a computer to execute the Internet of Things communication method provided in the first and fourth aspects.
  • the sixteenth aspect of the present invention provides a computer program product, including computer program information, which enables a computer to execute the Internet of Things communication method provided in the second and third aspects.
  • a seventeenth aspect of the present invention provides a computer program that causes a computer to execute the Internet of Things communication method provided in the first and fourth aspects.
  • the eighteenth aspect of the present invention provides a computer program that causes a computer to execute the Internet of Things communication method provided in the second and third aspects.
  • the client sends subscription information to the server, and the subscription information is used to request subscription to the target resource on the server, and then the client receives the subscription response information sent by the server, and the subscription response The information is used to indicate that the client successfully subscribes to the target resource, and the subscription response information contains the validity period of the current state of the target resource.
  • the client re-sends the subscription information of the target resource to the server.
  • the client can re-subscribe the target resource to the server, so that the server can re-subscribe to the target resource for some reasons. After clearing the subscription relationship between the target resource and the client, the client can re-subscribe to the target resource in time.
  • FIG. 1 is a schematic diagram of a scenario of an Internet of Things communication method provided by an embodiment of this application;
  • FIG. 2 is a signaling interaction diagram of an Internet of Things communication method provided by an embodiment of this application.
  • FIG. 3 is a signaling interaction diagram of another Internet of Things communication method provided by an embodiment of this application.
  • FIG. 4 is a signaling interaction diagram of yet another Internet of Things communication method provided by an embodiment of this application.
  • FIG. 5 is a signaling interaction diagram of yet another Internet of Things communication method provided by an embodiment of this application.
  • FIG. 6 is a signaling interaction diagram of yet another Internet of Things communication method provided by an embodiment of this application.
  • FIG. 7 is a signaling interaction diagram of yet another Internet of Things communication method provided by an embodiment of this application.
  • FIG. 8 is a schematic structural diagram of an Internet of Things communication device provided by an embodiment of this application.
  • FIG. 9 is a schematic structural diagram of another Internet of Things communication device provided by an embodiment of this application.
  • FIG. 10 is a schematic structural diagram of a client provided by an embodiment of this application.
  • FIG. 11 is a schematic structural diagram of a server provided by an embodiment of this application.
  • the one that sends out subscription information can act as a client, and the one that provides target resources can act as a server.
  • the client may actively cancel the subscription relationship to the target resource.
  • the client can actively forget the subscription relationship to the target resource.
  • the client sends a request message to the server, and the subscription identifier (obs) in the request message can be set to cancel the subscription, so that the server cancels the client's subscription to the target resource.
  • the server may clear the subscription relationship between the target resource and the client due to reboots and other situations.
  • the client does not know that the server has cleared the subscription relationship between the target resource and the client. Unable to re-subscribe the target resource in time.
  • the client cannot re-subscribe to the target resource in time after the server clears the subscription relationship between the target resource and the client.
  • the first method is to add a validity period to the subscription relationship of the target resource. When the validity period of the current state of the target resource expires, the client resends the subscription information of the target resource to the server.
  • the second method is to actively notify the customer service after the server releases the subscription relationship between the client and the target resource on the server, so that the client re-sends the subscription information of the target resource to the server.
  • FIG. 1 is a schematic diagram of a scenario of an Internet of Things communication method provided by an embodiment of this application.
  • the client 101 and the server 102 are connected to each other to form the Internet of Things.
  • the user operates the client 101 to send subscription information to the server 102, and subscribes to the target resource in the server 102.
  • the server 102 After completing the subscription of the target resource, the server 102 will send a subscription response message to the client, and feedback that the client 101 has successfully subscribed to the target resource. Subsequently, the client 101 will continue to monitor the notification information of the target resource to determine the change of the target resource.
  • the client 101 and the server 102 may be called terminal, user equipment (UE), mobile station (MS), mobile terminal (MT), etc., and may also be a mobile phone (mobile terminal, MT), etc. phone), tablet computer (pad), computer with wireless transceiver function, virtual reality (VR) terminal equipment, augmented reality (AR) terminal equipment, industrial control (industrial control) wireless terminal, no Wireless terminals in self-driving, wireless terminals in remote medical surgery, wireless terminals in smart grids, wireless terminals in smart homes, etc.
  • UE user equipment
  • MS mobile station
  • MT mobile terminal
  • the client 101 and the server 102 may be called terminal, user equipment (UE), mobile station (MS), mobile terminal (MT), etc., and may also be a mobile phone (mobile terminal, MT), etc. phone), tablet computer (pad), computer with wireless transceiver function, virtual reality (VR) terminal equipment, augmented reality (AR) terminal equipment, industrial control (industrial control) wireless terminal, no Wireless terminals in self-driving, wireless terminals in remote medical surgery,
  • the target resource may be a physical object or a functional object in the server 102.
  • the referenced resource may be a switch of the refrigerator, a lamp in the refrigerator, and so on.
  • the reference resource may be a switch of the TV, a volume button of the TV, and so on.
  • FIG. 1 is only an achievable scenario of the Internet of Things communication method.
  • the Internet of Things communication method involved in the embodiments of this application can be applied to a variety of Internet of Things systems. There are no restrictions on the Internet of Things system used.
  • Figure 2 is a signaling interaction diagram of an Internet of Things communication method provided by an embodiment of the application. The process of how the client and the server interact in the embodiments of this application. As shown in Figure 2, the method includes:
  • S201 The client sends subscription information to the server, and the subscription information is used to request a subscription to the target resource on the server.
  • the embodiment of this application does not limit the type of subscription information.
  • the type of subscription information may be Retrieve.
  • the subscription information may include Fr parameters, To parameters, Ri parameters, and Obs parameters.
  • the Fr parameter is the identifier of the device where the client is located;
  • the To parameter is the resource identifier subscribed by the client;
  • Ri is the request identifier, used to complete the binding of the request and response;
  • the Obs parameter is the subscription identifier, when the Obs parameter is set to 0, it means It is a subscription request.
  • the Obs parameter is set to 1, it means an unsubscribe request.
  • there is no Obs parameter it means a normal acquisition request.
  • the embodiment of the application does not limit the target resource, and can be specifically set according to actual conditions.
  • the target resource may be the power switch of the smart TV, or the volume switch of the smart TV.
  • the server sends subscription response information to the client.
  • the subscription response information is used to indicate that the client successfully subscribes to the target resource.
  • the subscription response information includes the validity period of the current state of the target resource.
  • the server can send subscription response information to the client.
  • the server may establish the client's subscription relationship to the target resource after authenticating the subscription information, and establish a monitoring mechanism for the client. Subsequently, the server replies a subscription response message to the client, thereby notifying the client that the target resource has been successfully subscribed.
  • the subscription response information may include the validity period of the current state of the target resource.
  • the validity period of the target resource may be characterized by the maxage parameter.
  • the client receives the subscription response information of the server, and when the validity period of the current state of the target resource expires, the client can resend the subscription information of the target resource to the server.
  • the subscription response information includes a maxage parameter
  • the meaning of the maxage parameter is the validity period of the target resource.
  • the client may combine resources on other servers to which it subscribes to comprehensively consider resending the subscription information of the target resource. For example, when the subscription duration of the target resource currently subscribed exceeds the validity period, but the subscription duration of other resources has not exceeded the validity period, the subscription information can be uniformly resent after the subscription duration of all resources exceeds the validity period.
  • an error notification is sent to the server.
  • the server receives the client resends the subscription information of the target resource, if there is no subscription relationship of the client to the target resource, a subscription relationship of the client to the target resource is generated.
  • the subscription information, subscription response information, and notification information all include a token identifier, and the token identifier is used to indicate the target resource corresponding to the subscription information, subscription response information, and notification information.
  • the client sends subscription information to the server, and the subscription information is used to request subscription to the target resource on the server. Then, the client receives the subscription response information sent by the server and uses the subscription response information. To indicate that the client has successfully subscribed to the target resource, the subscription response information includes the validity period of the current state of the target resource. When the validity period of the current state of the target resource expires, the client re-sends the subscription information of the target resource to the server.
  • the client can re-subscribe the target resource to the server, so that the server can re-subscribe to the target resource for some reasons. After clearing the subscription relationship between the target resource and the client, the client can re-subscribe to the target resource in time.
  • FIG. 3 is a signaling interaction diagram of another Internet of Things communication method provided by an embodiment of the application.
  • the Internet of Things communication method includes:
  • the client sends subscription information to the server, and the subscription information is used to request a subscription to the target resource on the server.
  • the server sends subscription response information to the client.
  • the subscription response information is used to indicate that the client successfully subscribes to the target resource, and the subscription response information includes the validity period of the target resource.
  • S301-S302 can be understood with reference to S201-S202 shown in FIG. 2, and the repeated content will not be repeated here.
  • the server sends notification information of the target resource to the client, where the notification information is used to indicate the change state of the target resource, and the notification information includes an updated value of the validity period of the current state of the target resource.
  • the server after the server sends the subscription response information to the client, when the status of the target resource changes, it can send notification information of the target resource to the client to inform the change of the target resource.
  • the notification information contains the updated value of the validity period of the current state of the target resource.
  • the updated value of the validity period can be determined by the server, and can be used to update the validity period of the current state of the target resource.
  • the updated value of the validity period can also be characterized by the Maxage parameter.
  • the client before the maxage parameter of the latest notification information expires, if no updated notification information arrives, the client can determine that the server no longer saves the client's subscription relationship to the target resource. The client can resend the subscription information of the target resource to the server, thereby re-subscribing to the target resource.
  • the validity period of the current state of the target resource can be adjusted by the server.
  • the client uses the updated value of the validity period of the current state of the target resource to update the validity period of the current state of the target resource.
  • the client after the client receives the notification information sent by the server, it can use the updated value of the validity period therein to update the validity period of the current state of the target resource.
  • the validity period of the target resource can be updated with the new maxage parameter, and the maxage parameter of the previous notification message is automatically invalidated.
  • the client sends subscription information to the server, and the subscription information is used to request subscription to the target resource on the server. Then, the client receives the subscription response information sent by the server and uses the subscription response information. To indicate that the client has successfully subscribed to the target resource, the subscription response information includes the current state validity period of the target resource. When the validity period of the current state of the target resource expires, the client stops monitoring the notification information of the target resource, and the notification information contains the change of the target resource.
  • the client since the server will attach the validity period of the target resource when it feeds back the subscription response information, when the validity period of the current state of the target resource expires, the client can re-subscribe the target resource to the server, thereby clearing the target on the server side for some reason After the subscription relationship between the resource and the client, the client can re-subscribe to the target resource in time.
  • Figure 4 is a signaling interaction diagram of yet another Internet of Things communication method provided by an embodiment of this application.
  • the embodiment of this application relates to the specific process of how the server sends unsubscription information to the client.
  • Network communication methods including:
  • S401 The server determines to release the subscription relationship between the client and the target resource on the server.
  • the embodiment of the application does not limit when to determine the subscription relationship between the client and the target resource on the server. For example, when the server is rebooted, it can be determined to release the target resource on the client and the server. Subscription relationship.
  • S402 The server sends unsubscribe information to the client, and the unsubscribe information is used to notify the client to cancel the subscription relationship of the target resource.
  • the server determines to release the subscription relationship between the client and the target resource on the server, it can send unsubscription information to the client.
  • the server when the server restarts (reboot), the server can traverse all subscription relationships on the server, determine the client corresponding to each subscription relationship, and then send the corresponding unsubscribe information to each client to notify The client server has cancelled the subscription relationship of the target resource.
  • S403 The client resends the subscription information of the target resource to the server according to the unsubscription information.
  • the server after receiving the unsubscription information sent by the server, the server resends the subscription information of the target resource to the server.
  • the server determines to release the subscription relationship between the client and the target resource on the server. Subsequently, the server sends unsubscribe information to the client, and the unsubscribe information is used to notify the client to cancel the subscription relationship of the target resource. Finally, the client re-sends the subscription information of the target resource to the server according to the unsubscribe information. In this way, the client can be actively notified, so that the client can more accurately perceive the cancellation of the subscription relationship. After the server clears the subscription relationship between the target resource and the client for some reason, the client can re-subscribe to the target resource in time.
  • FIG. 5 is a signaling interaction diagram of another IoT communication method provided by an embodiment of the application. As shown in FIG. 5, the IoT communication method includes:
  • the client sends subscription information to the server, and the subscription information is used to request a subscription to a target resource on the server.
  • S502 The server sends subscription response information to the client, and the subscription response information is used to characterize that the client successfully subscribes to the target resource.
  • S501-S502 can be understood with reference to S201-S302 shown in FIG. 2, and the repeated content will not be repeated here.
  • S503 The server determines to release the subscription relationship between the client and the target resource on the server.
  • the server sends unsubscribe information to the client, where the unsubscribe information is used to notify the client that the server cancels the subscription relationship of the target resource, and the unsubscribe information includes the status of the target resource and the subscription identifier of the target resource.
  • S505 The client resends the subscription information of the target resource to the server according to the unsubscription information.
  • steps S504 and S505 after the server needs to release the subscription relationship between the client and the target resource on the server, it can send unsubscription information to the client. Since the unsubscribe information includes the status of the target resource and the subscription identifier of the target resource, after the terminal device receives the unsubscribe information, because the subscription identifier of the target resource displays the unsubscription, the client can promptly know that the server has cancelled the target resource. Subscription relationship, so that the subscription information of the target resource can be re-sent to the server in time, and the bright-moon relationship of the target resource can be re-established.
  • the subscription identifier may be an Obs parameter, and the Obs parameter in the unsubscribe information is set to 1.
  • FIG. 6 is a signaling interaction diagram of another IoT communication method provided by an embodiment of the application. As shown in FIG. 6, the IoT communication method includes:
  • the client sends subscription information to the server, and the subscription information is used to request a subscription to a target resource on the server.
  • S602 The server sends subscription response information to the client, and the subscription response information is used to characterize the client's successful subscription to the target resource.
  • S601-S602 can be understood with reference to S201-S202 shown in FIG. 2, and the repeated content will not be repeated here.
  • S603 The server determines to release the subscription relationship between the client and the target resource on the server.
  • the server uses the subscription cancellation resource to send unsubscription information to the client.
  • the cancellation subscription information is used to notify the client server to cancel the subscription relationship of the target resource, and the subscription cancellation resource is used to cancel the subscription relationship of the target resource.
  • the subscription and cancellation resources can be defined by the server.
  • the server may define a subscription and cancellation resource oic.r.unobserve resource.
  • the function of the subscription cancellation resource is to notify the client to cancel the subscription relationship on the server side.
  • the subscription cancellation resource includes the targetClient attribute and the targetResource attribute.
  • the targetClient is used to identify the notified client, and the targetResource attribute identifies the target resource for unsubscription.
  • the targetResource attribute can be set to "all".
  • S605 The client resends the subscription information of the target resource to the server according to the unsubscription information.
  • FIG. 7 is a signaling interaction diagram of another IoT communication method provided by an embodiment of the application. As shown in FIG. 7, the IoT communication method includes:
  • the client sends subscription information to the server, and the subscription information is used to request a subscription to a target resource on the server.
  • the server sends subscription response information to the client, and the subscription response information is used to characterize that the client successfully subscribes to the target resource.
  • S703 The server determines to release the subscription relationship between the client and the target resource on the server.
  • the server uses the subscription cancellation resource to send unsubscription information to the cloud.
  • the unsubscription information is used to notify the client server to cancel the subscription relationship of the target resource, and the subscription cancellation resource is used to cancel the subscription relationship of the target resource.
  • the cloud sends unsubscription information to the client.
  • S706 The client resends the subscription information of the target resource to the server according to the unsubscription information.
  • the server determines to release the subscription relationship between the client and the target resource on the server. Subsequently, the server sends unsubscribe information to the client, and the unsubscribe information is used to instruct the client to cancel the subscription to the target resource on the server. Finally, the client stops monitoring the notification information of the target resource according to the unsubscribe information, and the notification information contains the change of the target resource. In this way, the client can be actively notified, so that the client can more accurately perceive the cancellation of the subscription relationship. After the server clears the subscription relationship between the target resource and the client for some reason, the client can re-subscribe to the target resource in time.
  • the aforementioned program can be stored in a computer readable storage medium, and when the program is executed, it is executed. Including the steps of the foregoing method embodiment; and the foregoing storage medium includes: ROM, RAM, magnetic disk, or optical disk and other media that can store program codes.
  • FIG. 8 is a schematic structural diagram of an Internet of Things communication device provided by an embodiment of this application.
  • the Internet of Things communication device can be implemented by software, hardware or a combination of the two to execute the above-mentioned client-side Internet of Things communication method.
  • the IoT communication device 800 includes: a sending module 801, a receiving module 802, and a processing module 803.
  • the sending module 801 is used to send subscription information to the server, and the subscription information is used to request a subscription to the target resource on the server;
  • the receiving module 802 is configured to receive subscription response information sent by the server, the subscription response information is used to characterize the successful subscription of the target resource by the IoT communication device, and the subscription response information includes the validity period of the current state of the target resource;
  • the sending module 801 is also used to resend the subscription information of the target resource to the server after the validity period of the current state of the target resource expires.
  • the receiving module 802 is further configured to receive notification information of the target resource sent by the server.
  • the notification information is used to indicate the change state of the target resource, and the notification information includes an update of the validity period of the current state of the target resource. value;
  • the processing module 803 is configured to use the updated value of the validity period of the current state of the target resource to update the validity period of the current state of the target resource.
  • the receiving module 802 is further configured to receive an error notification sent by the server, and the error notification is used to indicate that the server saves the subscription relationship of the IoT communication device to the target resource.
  • the subscription information, subscription response information, and notification information all include a token identifier, and the token identifier is used to indicate the target resource corresponding to the subscription information, subscription response information, and notification information.
  • the IoT communication device provided by the embodiments of the present application can execute the actions of the IoT communication method on the client side in the foregoing method embodiments, and its implementation principles and technical effects are similar, and will not be repeated here.
  • FIG. 9 is a schematic structural diagram of another Internet of Things communication device provided by an embodiment of this application.
  • the Internet of Things communication device can be implemented by software, hardware or a combination of the two to execute the above-mentioned Internet of Things communication method on the server side.
  • the IoT communication device 900 includes: a sending module 901, a receiving module 902, and a processing module 903.
  • the receiving module 902 is configured to receive subscription information sent by the client, and the subscription information is used to request a subscription to the target resource on the Internet of Things communication device;
  • the sending module 901 is configured to send subscription response information to the client.
  • the subscription response information is used to indicate that the client successfully subscribes to the target resource, and the subscription response information includes the validity period of the current state of the target resource;
  • the receiving module 902 is configured to receive the subscription information of the target resource resent by the client after the validity period of the current state of the target resource expires.
  • the sending module 901 is further configured to send notification information of the target resource to the client.
  • the notification information is used to indicate the change state of the target resource, and the notification information contains the updated value of the validity period of the current state of the target resource. .
  • the sending module 901 is further configured to send an error prompt to the client if there is a subscription relationship of the client to the target resource.
  • the device further includes:
  • the processing module 903 is configured to generate a subscription relationship of the client to the target resource if there is no subscription relationship of the client to the target resource.
  • the subscription information, subscription response information, and notification information all include a token identifier, and the token identifier is used to indicate the target resource corresponding to the subscription information, subscription response information, and notification information.
  • the IoT communication device provided in the embodiments of the present application can execute the actions of the IoT communication method on the server side in the foregoing method embodiments, and its implementation principles and technical effects are similar, and will not be repeated here.
  • the present application also provides an Internet of Things communication device, which can be implemented by software, hardware or a combination of the two to implement the above-mentioned client-side Internet of Things communication method.
  • the IoT communication device includes:
  • a processing module for determining to release the subscription relationship between the client and the target resource on the IoT communication device
  • the sending module is used to send unsubscribe information to the client, and the unsubscribe information is used to notify the client server to cancel the subscription relationship of the target resource;
  • the receiving module is also used to receive the subscription information of the target resource re-sent by the client.
  • the unsubscription information includes the status of the target resource and the subscription identifier of the target resource.
  • the sending module is specifically configured to use the subscription cancellation resource to send unsubscription information to the client, and the subscription cancellation resource is used to cancel the subscription relationship of the target resource.
  • the subscription and cancellation resource includes the identifier of the target resource and the identifier of the client.
  • the receiving module is further configured to receive subscription information sent by the client, and the subscription information is used to request a subscription to the target resource on the Internet of Things communication device;
  • the sending module is also used to send subscription response information to the client, and the subscription response information is used to indicate that the client successfully subscribes to the target resource.
  • the present application also provides an Internet of Things communication device, which can be implemented by software, hardware, or a combination of both, to execute the above-mentioned server-side Internet of Things communication method.
  • the IoT communication device includes:
  • the receiving module is used to receive the unsubscribe information sent by the server, and the unsubscribe information is used to notify the client to cancel the subscription relationship of the target resource;
  • the sending module is used to resend the subscription information of the target resource to the server according to the unsubscription information.
  • the unsubscription information includes the status of the target resource and the subscription identifier of the target resource.
  • the sending module is also used to send subscription information to the server, and the subscription information is used to request a subscription to the target resource on the server;
  • the receiving module is also used to receive subscription response information sent by the server, and the subscription response information is used to characterize the successful subscription of the target resource by the IoT communication device.
  • the IoT communication device provided in the embodiments of the present application can execute the actions of the IoT communication method on the server side in the foregoing method embodiments, and its implementation principles and technical effects are similar, and will not be repeated here.
  • FIG. 10 is a schematic structural diagram of a client provided by an embodiment of this application.
  • the client may include: a processor 201 (for example, a CPU), a memory 202, a receiver 203, and a transmitter 204; the receiver 203 and the transmitter 204 are coupled to the processor 201, and the processor 201 controls the receiver In the receiving action of 203, the processor 201 controls the sending action of the transmitter 204.
  • the memory 202 may include a high-speed RAM memory, or may also include a non-volatile memory NVM, such as at least one disk memory.
  • the memory 202 may store various information for completing various processing functions and implementing the methods of the embodiments of the present application. step.
  • the client involved in the embodiment of the present application may further include: a power supply 205, a communication bus 206, and a communication port 207.
  • the receiver 203 and the transmitter 204 may be integrated in the transceiver of the client, or may be independent transceiver antennas on the client.
  • the communication bus 206 is used to implement communication connections between components.
  • the aforementioned communication port 207 is used to implement connection and communication between the client and other peripherals.
  • the above-mentioned memory 202 is used to store computer executable program code, and the program code includes information; when the processor 201 executes the information, the information causes the processor 201 to execute the processing actions of the client in the above-mentioned method embodiment, so as to send
  • the device 204 executes the sending action of the client in the foregoing method embodiment, and causes the receiver 203 to execute the receiving action of the client in the foregoing method embodiment.
  • the implementation principles and technical effects are similar, and will not be repeated here.
  • FIG. 11 is a schematic structural diagram of a server provided by an embodiment of this application.
  • the server may include: a processor 211 (such as a CPU), a memory 212, a receiver 213, and a transmitter 214; the receiver 213 and the transmitter 214 are coupled to the processor 211, and the processor 211 controls the receiver In the receiving action of 213, the processor 211 controls the sending action of the transmitter 214.
  • the memory 212 may include a high-speed RAM memory, or may also include a non-volatile memory NVM, such as at least one disk memory.
  • the memory 212 may store various information to complete various processing functions and implement the methods of the embodiments of the present application. step.
  • the server involved in the embodiment of the present application may further include: a power supply 215, a communication bus 216, and a communication port 217.
  • the receiver 213 and the transmitter 214 may be integrated in the transceiver of the server, or may be independent transceiver antennas on the server.
  • the communication bus 216 is used to implement communication connections between components.
  • the aforementioned communication port 217 is used to implement connection and communication between the server and other peripherals.
  • the above-mentioned memory 212 is used to store computer executable program code, and the program code includes information; when the processor 211 executes the information, the information causes the processor 211 to perform the processing actions of the server in the above-mentioned method embodiment, so as to send
  • the device 214 executes the sending action of the server in the foregoing method embodiment, and causes the receiver 213 to execute the receiving action of the server in the foregoing method embodiment.
  • the implementation principles and technical effects are similar, and will not be repeated here.
  • the embodiment of the present application also provides an Internet of Things system, including a client and a server, and the client and the server execute the above-mentioned Internet of Things communication method.
  • the embodiment of the present application also provides a chip including a processor and an interface.
  • the interface is used to input and output data or instructions processed by the processor.
  • the processor is used to execute the method provided in the above method embodiment.
  • the chip can be used in the server, and can also be used in the client.
  • the present invention also provides a computer-readable storage medium.
  • the computer-readable storage medium may include: a U disk, a mobile hard disk, a read-only memory (ROM, Read-Only Memory), and a random access memory (RAM, Random Access Memory). ), magnetic disks or optical disks and other media that can store program codes.
  • the computer-readable storage medium stores program information, and the program information is used in the above-mentioned Internet of Things communication method.
  • the embodiment of the present application also provides a program, which is used to execute the Internet of Things communication method provided in the above method embodiment when the program is executed by the processor.
  • the embodiments of the present application also provide a program product, such as a computer-readable storage medium, where instructions are stored in the program product, which when run on a computer, cause the computer to execute the Internet of Things communication method provided by the foregoing method embodiment.
  • a program product such as a computer-readable storage medium
  • the above-mentioned embodiments it may be implemented in whole or in part by software, hardware, firmware, or any combination thereof.
  • software it can be implemented in the form of a computer program product in whole or in part.
  • the computer program product includes one or more computer instructions.
  • the computer program instructions When the computer program instructions are loaded and executed on the computer, the processes or functions according to the embodiments of the present invention are generated in whole or in part.
  • the computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices.
  • Computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium.
  • computer instructions can be transmitted from a website, computer, server, or data center through a wired (for example, coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (such as infrared, wireless, microwave, etc.) means to transmit to another website site, computer, server or data center.
  • the computer-readable storage medium may be any available medium that can be accessed by a computer or a data storage device such as a server or data center integrated with one or more available media.
  • the usable medium may be a magnetic medium (for example, a floppy disk, a hard disk, and a magnetic tape), an optical medium (for example, a DVD), or a semiconductor medium (for example, a solid state disk (SSD)).

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computing Systems (AREA)
  • Computer Security & Cryptography (AREA)
  • Economics (AREA)
  • Accounting & Taxation (AREA)
  • Development Economics (AREA)
  • Business, Economics & Management (AREA)
  • General Business, Economics & Management (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Telephonic Communication Services (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

本发明提供一种物联网通信方法及装置,方法包括:向服务端发送订阅信息,订阅信息用于请求订阅服务端上的目标资源;接收服务端发送的订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源,订阅响应信息中包含有目标资源当前状态的有效期;当目标资源当前状态的有效期过期后,向服务端重新发送目标资源的订阅信息。通过上述方式,由于服务端在反馈订阅响应信息时会附带有目标资源的有效期,当目标资源当前状态的有效期过期后,客户端可以向服务端重新订阅目标资源,从而在服务端因故清除目标资源与客户端的订阅关系后,客户端可以及时重新订阅目标资源。

Description

物联网通信方法及装置 技术领域
本发明涉及通信技术领域,尤其涉及一种物联网通信方法及装置。
背景技术
随着技术的发展,物联网以及智能家居应用逐渐进入人们的生活之中。物联网系统中的订阅/推送技术不但可以应用于设备与云平台通信(device to cloud,D2C)的信息传输,还可以应用在应用层下的业务处理层以及设备与设备通信(device to device,D2D)领域。例如,手机订阅了家中温度计的温度,当温度计的温度超过设定值时,开启空调。
在现有技术中,发出订阅信息的可以作为客户端,提供目标资源的可以作为服务端。当客户端订阅服务端的目标资源后,客户端可能会主动取消对目标资源的订阅关系。在一些情况下,客户端可以主动忘记对目标资源的订阅关系。在另一些情况下,客户端向服务端发送请求消息,该请求消息中的订阅标识(obs)可以设定为取消订阅,从而使服务端取消客户端对目标资源的订阅关系。
然而,在实际场景中,服务端由于重新启动(reboot)等情况,可能因故清除目标资源与客户端的订阅关系,此时客户端由于不知道服务端清除了目标资源与客户端的订阅关系,从而无法及时重新订阅目标资源。
发明内容
本发明实施例提供一种物联网通信方法及装置,以解决现有技术中服务端清除目标资源与客户端的订阅关系后客户端无法及时重新订阅目标资源的问题。
本发明的第一个方面提供一种物联网通信方法,应用于客户端,包括:
向服务端发送订阅信息,所述订阅信息用于请求订阅所述服务端上的目标资源;
接收所述服务端发送的订阅响应信息,所述订阅响应信息用于表征客户端成功订阅所述目标资源,所述订阅响应信息中包含有所述目标资源当前状态的有效期;
当所述目标资源当前状态的有效期过期后,向所述服务端重新发送所述目标资源的订阅信息。
本发明的第二个方面提供一种物联网通信方法,应用于服务端,包括:
接收客户端发送的订阅信息,所述订阅信息用于请求订阅服务端上的 目标资源;
向所述客户端发送订阅响应信息,所述订阅响应信息用于表征所述客户端成功订阅所述目标资源,所述订阅响应信息中包含有所述目标资源当前状态的有效期;
当所述目标资源当前状态的有效期过期后,接收所述客户端重新发送的所述目标资源的订阅信息。
本发明的第三个方面提供一种物联网通信方法,应用于服务端,包括:
确定释放客户端与服务端上的目标资源的订阅关系;
向所述客户端发送取消订阅信息,所述取消订阅信息用于通知所述客户端所述服务端取消所述目标资源的订阅关系;
接收所述客户端重新发送的所述目标资源的订阅信息。
本发明的第四个方面提供一种物联网通信方法,应用于客户端,包括:
接收服务端发送的取消订阅信息,所述取消订阅信息用于通知客户端所述服务端取消所述目标资源的订阅关系;
根据所述取消订阅信息,向所述服务端重新发送所述目标资源的订阅信息。
本发明的第五个方面提供一种物联网通信装置,包括:
发送模块,用于向服务端发送订阅信息,所述订阅信息用于请求订阅所述服务端上的目标资源;
接收模块,用于接收所述服务端发送的订阅响应信息,所述订阅响应信息用于表征物联网通信装置成功订阅所述目标资源,所述订阅响应信息中包含有所述目标资源的有效期;
所述发送模块,还用于当所述目标资源的订阅时间超过所述目标资源的有效期后,向所述服务端重新发送所述目标资源的订阅信息。
本发明的第六个方面提供一种物联网通信装置,包括:
接收模块,用于接收客户端发送的订阅信息,所述订阅信息用于请求订阅物联网通信装置上的目标资源;
发送模块,用于向所述客户端发送订阅响应信息,所述订阅响应信息用于表征所述客户端成功订阅所述目标资源,所述订阅响应信息中包含有所述目标资源的有效期;
接收模块,用于当所述目标资源的订阅时间超过所述目标资源的有效期后,接收所述客户端重新发送的所述目标资源的订阅信息。
本发明的第七个方面提供一种物联网通信装置,包括:
处理模块,用于确定释放客户端与物联网通信装置上的目标资源的订阅关系;
发送模块,用于向所述客户端发送取消订阅信息,所述取消订阅信息用于通知所述客户端所述服务端取消所述目标资源的订阅关系;
接收模块,还用于接收所述客户端重新发送的所述目标资源的订阅信息。
本发明的第八个方面提供一种物联网通信装置,包括:
接收模块,用于接收服务端发送的取消订阅信息,所述取消订阅信息用于通知客户端所述服务端取消所述目标资源的订阅关系;
发送模块,用于根据所述取消订阅信息,向所述服务端重新发送所述目标资源的订阅信息。
本发明第九个方面提供一种客户端,所述客户端包括:处理器、存储器、发送器和接收器;所述发送器和所述接收器耦合至所述处理器,所述处理器控制所述发送器的发送动作,所述处理器控制所述接收器的接收动作;
其中,存储器用于存储计算机可执行程序代码,程序代码包括信息;当处理器执行信息时,信息使所述网络设备执行如第一方面和第四方面所提供的物联网通信方法。
本发明第十个方面提供一种服务端,所述客户端包括:处理器、存储器、发送器和接收器;所述发送器和所述接收器耦合至所述处理器,所述处理器控制所述发送器的发送动作,所述处理器控制所述接收器的接收动作;
其中,存储器用于存储计算机可执行程序代码,程序代码包括信息;当处理器执行信息时,信息使所述网络设备执行如第二面和第三方面所提供的物联网通信方法。
本发明第十一个方面提供一种芯片,包括:处理器,用于从存储器中调用并运行计算机程序,使得安装有所述芯片的设备执行如第一方面和第四方面所提供的物联网通信方法。
本发明第十二个方面提供一种芯片,包括:处理器,用于从存储器中调用并运行计算机程序,使得安装有所述芯片的设备执行如第二方面和第三方面所提供的物联网通信方法。
本发明第十三个方面提供一种计算机可读存储介质,用于存储计算机程序,所述计算机程序使得计算机执行如第一方面和第四方面所提供的物联网通信方法。
本发明第十四个方面提供一种计算机可读存储介质,用于存储计算机程序,所述计算机程序使得计算机执行如第二方面和第三方面所提供的物联网通信方法。
本发明第十五个方面提供一种计算机程序产品,包括计算机程序信息,该计算机程序信息使得计算机执行如第一方面和第四方面所提供的物联网通信方法。
本发明第十六个方面提供一种计算机程序产品,包括计算机程序信息,该计算机程序信息使得计算机执行如第二方面和第三方面所提供的物联网通信方法。
本发明第十七个方面提供一种计算机程序,所述计算机程序使得计算机执行如第一方面和第四方面所提供的物联网通信方法。
本发明第十八个方面提供一种计算机程序,所述计算机程序使得计算机执行如第二方面和第三方面所提供的物联网通信方法。
本申请实施例提供的物联网通信方法及装置,客户端向服务端发送订阅信息,订阅信息用于请求订阅服务端上的目标资源,随后,客户端接收服务端发送的订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源,订阅响应信息中包含有目标资源当前状态的有效期。当目标资源当前状态的有效期过期后,客户端向服务端重新发送目标资源的订阅信息。通过上述方式,由于服务端在反馈订阅响应信息时会附带有目标资源当前状态的有效期,当目标资源当前状态的有效期过期后,客户端可以向服务端重新订阅目标资源,从而在服务端因故清除目标资源与客户端的订阅关系后,客户端可以及时重新订阅目标资源。
附图说明
为了更清楚地说明本发明或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作一简单地介绍,显而易见地,下面描述中的附图是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1为本申请实施例提供的一种物联网通信方法的场景示意图;
图2为本申请实施例提供的一种物联网通信方法的信令交互图;
图3为本申请实施例提供的另一种物联网通信方法的信令交互图;
图4为本申请实施例提供的再一种物联网通信方法的信令交互图;
图5为本申请实施例提供的又一种物联网通信方法的信令交互图;
图6为本申请实施例提供的又一种物联网通信方法的信令交互图;
图7为本申请实施例提供的又一种物联网通信方法的信令交互图;
图8为本申请实施例提供的一种物联网通信装置的结构示意图;
图9为本申请实施例提供的另一种物联网通信装置的结构示意图;
图10为本申请实施例提供的一种客户端的结构示意图;
图11为本申请实施例提供的一种服务端的结构示意图。
具体实施方式
为使本发明的目的、技术方案和优点更加清楚,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
在现有技术中,发出订阅信息的可以作为客户端,提供目标资源的可以作为服务端。当客户端订阅服务端的目标资源后,客户端可能会主动取消对目标资源的订阅关系。在一些情况下,客户端可以主动忘记对目标资源的订阅关系。在另一些情况下,客户端向服务端发送请求消息,该请求消息中的订阅标识(obs)可以设定为取消订阅,从而使服务端取消客户端对目标资源 的订阅关系。
然而,在实际场景中,服务端由于重新启动(reboot)等情况,可能因故清除目标资源与客户端的订阅关系,此时客户端由于不知道服务端清除了目标资源与客户端的订阅关系,从而无法及时重新订阅目标资源。
为解决上述问题,使服务端清除目标资源与客户端的订阅关系后客户端无法及时重新订阅目标资源。本申请中,第一种方式是采用为目标资源的订阅关系附加有效期的方式,当目标资源当前状态的有效期过期后,客户端向服务端重新发送目标资源的订阅信息。第二种方式是在服务端释放客户端与服务端上的目标资源的订阅关系后,主动告知客服端,从而使客户端向服务端重新发送目标资源的订阅信息。
图1为本申请实施例提供的一种物联网通信方法的场景示意图。如图1所示,客户端101和服务端102互相连接,构成物联网。用户操作客户端101向服务端102发送订阅信息,在服务端102中订阅目标资源。在完成目标资源的订阅后,服务端102会向客户端发送订阅响应信息,反馈客户端101成功订阅目标资源。随后,客户端101会持续监测目标资源的通知信息,以确定目标资源的变化情况。
其中,客户端101和服务端102,可以称为终端Terminal、用户设备(user equipment,UE)、移动台(mobile station,MS)、移动终端(mobile terminal,MT)等,还可以是手机(mobile phone)、平板电脑(pad)、带无线收发功能的电脑、虚拟现实(virtual reality,VR)终端设备、增强现实(augmented reality,AR)终端设备、工业控制(industrial control)中的无线终端、无人驾驶(self driving)中的无线终端、远程手术(remote medical surgery)中的无线终端、智能电网(smart grid)中的无线终端、智慧家庭(smart home)中的无线终端等。
目标资源可以为服务端102中的物理对象或功能对象。示例性的,服务端为冰箱,则引用资源可以为冰箱的开关、冰箱内的灯等。示例性的,服务端为电视,则引用资源可以为电视的开关、电视的音量大小按钮等。
需要说明的是,图1所示的场景仅为物联网通信方法的一种可实现场景,本申请实施例中涉及的物联网通信方法可以运用于多种物联网系统中,本申请实施对于可运用的物联网系统不做限制。
下面以客户端和服务端为例,以具体地实施例对本申请实施例的技术方案进行详细说明。下面这几个具体的实施例可以相互结合,对于相同或相似的概念或过程可能在某些实施例不再赘述。
图2为本申请实施例提供的一种物联网通信方法的信令交互图。本申请实施例的涉及的客户端和服务端如何交互的过程。如图2所示,该方法包括:
S201、客户端向服务端发送订阅信息,订阅信息用于请求订阅服务端上的目标资源。
其中,本申请实施例对于订阅信息的类型不做限制,示例性的,订阅信息的类型可以为Retrieve。订阅信息可以包括Fr参数、To参数、Ri参 数和Obs参数。Fr参数为客户端所在设备的标识;To参数为客户端订阅的资源标识;Ri为请求标识,用来完成请求和应答的绑定;Obs参数为订阅标识,当Obs参数设定为0时表示是订阅请求,当Obs参数设定为1时表示是取消订阅请求,当无Obs参数时表示是普通的获取请求。
本申请实施例对于目标资源不做限制,可以根据实际情况具体设置。示例性的,若服务端为智能电视,目标资源可以为智能电视的电源开关,也可以为智能电视的音量开关等。
S202、服务端向客户端发送订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源,订阅响应信息中包含有目标资源当前状态的有效期。
在本步骤中,当客户端向服务端发送订阅信息后,服务端可以向客户端发送订阅响应信息。
在一些实施例中,服务端收到上述订阅信息之后,服务端可以在对订阅信息认证后建立客户端对目标资源的订阅关系,并建立该客户端的监测机制。随后,服务端回复一个订阅响应信息给客户端,从而告知客户端成功订阅目标资源。
其中,订阅响应信息可以包含目标资源当前状态的有效期。示例性的,目标资源的有效期可以由maxage参数表征。
S203、当目标资源当前状态的有效期过期后,客户端向服务端重新发送目标资源的订阅信息。
本步骤中,客户端接收到服务端的订阅响应信息,当目标资源当前状态的有效期过期后,客户端可以向服务端重新发送目标资源的订阅信息。
示例性的,订阅响应信息包括有maxage参数,maxage参数的含义是目标资源的有效期。当目标资源的订阅时间超过超过maxage参数的时限后,则目标资源当前状态的有效期过期,客户端不能再信任该订阅关系,向服务端重新发送目标资源的订阅信息。
在一些实施例中,客户端可以结合其订阅的其他的服务端上面的资源,去综合考虑重新发送目标资源的订阅信息。例如在当前订阅的目标资源的订阅时长超过有效期,但其他资源的订阅时长还未超过有效期,则可以在所有资源的订阅时长都超过有效期后,再统一重新发送订阅信息。
在一种可选的实施方式中,服务端接收到客户端重新发送目标资源的订阅信息后,若服务端中存在客户端对目标资源的订阅关系,则向服务端发送错误提示。
在一种可选的实施方式中,服务端接收到客户端重新发送目标资源的订阅信息后,若不存在客户端对目标资源的订阅关系,则生成客户端对目标资源的订阅关系。
在一些可选的实施方式中,订阅信息、订阅响应信息和通知信息均包括有令牌标识,令牌标识用于指示订阅信息、订阅响应信息和通知信息对应的目标资源。
本申请实施例提供的物联网通信方法,客户端向服务端发送订阅信息,订阅信息用于请求订阅服务端上的目标资源,随后,客户端接收服务端发送的订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源,订阅响应信息中包含有目标资源当前状态的有效期。当目标资源当前状态的有效期过期后,客户端向服务端重新发送目标资源的订阅信息。通过上述方式,由于服务端在反馈订阅响应信息时会附带有目标资源当前状态的有效期,当目标资源当前状态的有效期过期后,客户端可以向服务端重新订阅目标资源,从而在服务端因故清除目标资源与客户端的订阅关系后,客户端可以及时重新订阅目标资源。
在上述实施例的基础上,服务端还可以向客户端发送通知信息来更新目标资源的有效期。图3为本申请实施例提供的另一种物联网通信方法的信令交互图,物联网通信方法,包括:
S301、客户端向服务端发送订阅信息,订阅信息用于请求订阅服务端上的目标资源。
S302、服务端向客户端发送订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源,订阅响应信息中包含有目标资源的有效期。
S301-S302的技术名词、技术效果、技术特征,以及可选实施方式,可参照图2所示的S201-S202理解,对于重复的内容,在此不再累述。
S303、服务端向客户端发送目标资源的通知信息,通知信息用于指示目标资源的变化状态,通知信息包含有目标资源当前状态的有效期的更新值。
在本步骤中,服务端向客户端发送订阅响应信息后,当目标资源的状态发生变化时,可以向客户端发送目标资源的通知信息,来告知目标资源的变化情况。
其中,通知信息包含有目标资源当前状态的有效期的更新值。该有效期的更新值可以由服务端确定,可以用来更新目标资源当前状态的有效期。示例性的,有效期的更新值也可以用Maxage参数来表征。
在一些实施例中,当在最新的通知信息的maxage参数到期前,若没有更新的通知信息到来,则客户端可以判定服务端已经不再保存该客户端对目标资源的订阅关系,此时客户端可以向服务端重新发送目标资源的订阅信息,从而重新订阅目标资源。
在一种可选的实施方式中,目标资源当前状态的有效期可以由服务端进行调整。
S304、客户端使用目标资源当前状态的有效期的更新值,更新目标资源当前状态的有效期。
在本步骤中,客户端接收到服务端发送的通知信息后,可以使用其中的有效期的更新值来更新目标资源当前状态的有效期。
示例性的,当新的通知信息到来时,可以用新的maxage参数更新目标资源的有效期,上一个通知消息的maxage参数自动失效。
S305、当目标资源当前状态的有效期过期后,客户端向服务端重新发送目标资源的订阅信息。
S305的技术名词、技术效果、技术特征,以及可选实施方式,可参照图2所示的S203理解,对于重复的内容,在此不再累述。
本申请实施例提供的物联网通信方法,客户端向服务端发送订阅信息,订阅信息用于请求订阅服务端上的目标资源,随后,客户端接收服务端发送的订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源,订阅响应信息中包含有目标资源的当前状态有效期。当目标资源当前状态的有效期过期后,客户端停止监测目标资源的通知信息,通知信息包含有目标资源的变化情况。通过上述方式,由于服务端在反馈订阅响应信息时会附带有目标资源的有效期,当目标资源当前状态的有效期过期后,客户端可以向服务端重新订阅目标资源,从而在服务端因故清除目标资源与客户端的订阅关系后,客户端可以及时重新订阅目标资源。
下面介绍第二种避免服务端清除目标资源与客户端的订阅关系后及时重新订阅目标资源的方式。图4为本申请实施例提供的再一种物联网通信方法的信令交互图,本申请实施例涉及的是服务端如何向客户端发送取消订阅信息的具体过程,如图4所示,物联网通信方法,包括:
S401、服务端确定释放客户端与服务端上的目标资源的订阅关系。
本申请实施例对于何时确定客户端与服务端上的目标资源的订阅关系不做限制,实例性的,当服务端重新启动(reboot)后,可以确定释放客户端与服务端上的目标资源的订阅关系。
S402、服务端向客户端发送取消订阅信息,取消订阅信息用于通知客户端服务端取消目标资源的订阅关系。
在本步骤种,当服务端确定释放客户端与服务端上的目标资源的订阅关系后,可以向客户端发送取消订阅信息。
示例性的,当服务端重新启动(reboot)后,服务器可以遍历服务端上的所有订阅关系,确定每个订阅关系对应的客户端,再向每个客户端发送对应的取消订阅信息,来通知客户端服务端已经取消目标资源的订阅关系。
S403、客户端根据取消订阅信息,向服务端重新发送目标资源的订阅信息。
在本步骤中,当服务端接收到服务端发送的取消订阅信息后,向服务端重新发送目标资源的订阅信息。
本申请实施例提供的物联网通信方法,服务端确定释放客户端与服务端上的目标资源的订阅关系。随后,服务端向客户端发送取消订阅信息,取消订阅信息用于通知客户端服务端取消目标资源的订阅关系。最后,客户端根据取消订阅信息,向服务端重新发送目标资源的订阅信息。通过该方式,可以主动通知客户端,使客户端可以更准确的感知订阅关系的注销,在服务端因故清除目标资源与客户端的订阅关系后,客户端可以及时重新订阅目标资源。
在上述实施例的基础上,下面介绍两种方式发送取消订阅信息。第一种方式通过目标资源的订阅标识来告知客户端取消订阅关系。图5为本申请实施例提供的又一种物联网通信方法的信令交互图,如图5所示,物联网通信方法包括:
S501、客户端向服务端发送订阅信息,订阅信息用于请求订阅服务端上的目标资源。
S502、服务端向客户端发送订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源。
S501-S502的技术名词、技术效果、技术特征,以及可选实施方式,可参照图2所示的S201-S302理解,对于重复的内容,在此不再累述。
S503、服务端确定释放客户端与服务端上的目标资源的订阅关系。
S503的技术名词、技术效果、技术特征,以及可选实施方式,可参照图4所示的S401理解,对于重复的内容,在此不再累述。
S504、服务端向客户端发送取消订阅信息,取消订阅信息用于通知客户端服务端取消目标资源的订阅关系,取消订阅信息包括有目标资源的状态和目标资源的订阅标识。
S505、客户端根据取消订阅信息,向服务端重新发送目标资源的订阅信息。
在步骤S504和S505中,服务端需要释放客户端与服务端上的目标资源的订阅关系后,可以向客户端发送取消订阅信息。由于取消订阅信息包括有目标资源的状态和目标资源的订阅标识,终端设备在接受到取消订阅信息后,由于目标资源的订阅标识显示取消订阅,则客户端可以及时获知服务端取消了目标资源的订阅关系,从而可以及时向服务端重新发送目标资源的订阅信息,重新建立目标资源的明月关系。
其中,该订阅标识可以为Obs参数,取消订阅信息中Obs参数设置为1。
在上述实施例的基础上,下面介绍第二种方式通过订阅注销资源发送取消订阅信息来告知客户端取消订阅关系。图6为本申请实施例提供的又一种物联网通信方法的信令交互图,如图6所示,物联网通信方法包括:
S601、客户端向服务端发送订阅信息,订阅信息用于请求订阅服务端上的目标资源。
S602、服务端向客户端发送订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源。
S601-S602的技术名词、技术效果、技术特征,以及可选实施方式,可参照图2所示的S201-S202理解,对于重复的内容,在此不再累述。
S603、服务端确定释放客户端与服务端上的目标资源的订阅关系。
S603的技术名词、技术效果、技术特征,以及可选实施方式,可参照图4所示的S401理解,对于重复的内容,在此不再累述。
S604、服务端使用订阅注销资源,向客户端发送取消订阅信息,取消 订阅信息用于通知客户端服务端取消目标资源的订阅关系,订阅注销资源用于注销目标资源的订阅关系。
其中,订阅注销资源可以由服务端定义。示例性,服务端可以定义一个订阅注销资源oic.r.unobserve资源。该订阅注销资源的作用就是用于服务端通知客户端注销订阅关系。该订阅注销资源包含targetClient属性和targetResource属性。targetClient用于标识通知的客户端,targetResource属性标识取消订阅的目标资源。在一些实施例中,如果服务端中的所有资源全部取消,则可以将targetResource属性设定该值为“all”。
S605、客户端根据取消订阅信息,向服务端重新发送目标资源的订阅信息。
S605的技术名词、技术效果、技术特征,以及可选实施方式,可参照图4所示的S403理解,对于重复的内容,在此不再累述。
在一些实施例中,由于取消订阅信息不一定能够被客户端及时接收到,则可以由云端缓冲该取消订阅信息,再由云端将取消订阅信息发送给客户端。图7为本申请实施例提供的又一种物联网通信方法的信令交互图,如图7所示,物联网通信方法包括:
S701、客户端向服务端发送订阅信息,订阅信息用于请求订阅服务端上的目标资源。
S702、服务端向客户端发送订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源。
S703、服务端确定释放客户端与服务端上的目标资源的订阅关系。
S704、服务端使用订阅注销资源,向云端发送取消订阅信息,取消订阅信息用于通知客户端服务端取消目标资源的订阅关系,订阅注销资源用于注销目标资源的订阅关系。
S705、云端向客户端发送取消订阅信息。
S706、客户端根据取消订阅信息,向服务端重新发送目标资源的订阅信息。
本申请实施例提供的物联网通信方法,服务端确定释放客户端与服务端上的目标资源的订阅关系。随后,服务端向客户端发送取消订阅信息,取消订阅信息用于指示客户端取消对服务端上目标资源的订阅。最后,客户端根据取消订阅信息,停止监测目标资源的通知信息,通知信息包含有目标资源的变化情况。通过该方式,可以主动通知客户端,使客户端可以更准确的感知订阅关系的注销,在服务端因故清除目标资源与客户端的订阅关系后,客户端可以及时重新订阅目标资源。
本领域普通技术人员可以理解:实现上述方法实施例的全部或部分步骤可以通过程序信息相关的硬件来完成,前述的程序可以存储于一计算机可读取存储介质中,该程序在执行时,执行包括上述方法实施例的步骤;而前述的存储介质包括:ROM、RAM、磁碟或者光盘等各种可以存储程序代码的介质。
图8为本申请实施例提供的一种物联网通信装置的结构示意图。该物联网通信装置可以通过软件、硬件或者两者的结合实现,以执行上述客户端侧的物联网通信方法。如图8所示,该物联网通信装置800包括:发送模块801、接收模块802、处理模块803。
发送模块801,用于向服务端发送订阅信息,订阅信息用于请求订阅服务端上的目标资源;
接收模块802,用于接收服务端发送的订阅响应信息,订阅响应信息用于表征物联网通信装置成功订阅目标资源,订阅响应信息中包含有目标资源当前状态的有效期;
发送模块801,还用于当目标资源当前状态的有效期过期后,向服务端重新发送目标资源的订阅信息。
一种可选的实施方式中,接收模块802,还用于接收服务端发送的目标资源的通知信息,通知信息用于指示目标资源的变化状态,通知信息包含有目标资源当前状态的有效期的更新值;
处理模块803,用于使用目标资源当前状态的有效期的更新值,更新目标资源当前状态的有效期。
一种可选的实施方式中,接收模块802,还用于接收服务端发送的错误提示,错误提示用于指示服务端保存有物联网通信装置对目标资源的订阅关系。
一种可选的实施方式中,订阅信息、订阅响应信息和通知信息均包括有令牌标识,令牌标识用于指示订阅信息、订阅响应信息和通知信息对应的目标资源。
本申请实施例提供的物联网通信装置,可以执行上述方法实施例中客户端侧的的物联网通信方法的动作,其实现原理和技术效果类似,在此不再赘述。
图9为本申请实施例提供的另一种物联网通信装置的结构示意图。该物联网通信装置可以通过软件、硬件或者两者的结合实现,以执行服务端侧的上述物联网通信方法。如图9所示,该物联网通信装置900包括:发送模块901、接收模块902、处理模块903。
接收模块902,用于接收客户端发送的订阅信息,订阅信息用于请求订阅物联网通信装置上的目标资源;
发送模块901,用于向客户端发送订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源,订阅响应信息中包含有目标资源当前状态的有效期;
接收模块902,用于当目标资源当前状态的有效期过期后,接收客户端重新发送的目标资源的订阅信息。
一种可选的实施方式中,发送模块901,还用于向客户端发送目标资源的通知信息,通知信息用于指示目标资源的变化状态,通知信息包含有目标资源当前状态的有效期的更新值。
一种可选的实施方式中,发送模块901,还用于若存在客户端对目标资源的订阅关系,则向客户端发送错误提示。
一种可选的实施方式中,装置,还包括:
处理模块903,用于若不存在客户端对目标资源的订阅关系,则生成客户端对目标资源的订阅关系。
一种可选的实施方式中,订阅信息、订阅响应信息和通知信息均包括有令牌标识,令牌标识用于指示订阅信息、订阅响应信息和通知信息对应的目标资源。
本申请实施例提供的物联网通信装置,可以执行上述方法实施例中服务端侧的的物联网通信方法的动作,其实现原理和技术效果类似,在此不再赘述。
本申请还提供一种物联网通信装置,该物联网通信装置可以通过软件、硬件或者两者的结合实现,以执行上述客户端侧的物联网通信方法。该物联网通信装置包括:
处理模块,用于确定释放客户端与物联网通信装置上的目标资源的订阅关系;
发送模块,用于向客户端发送取消订阅信息,取消订阅信息用于通知客户端服务端取消目标资源的订阅关系;
接收模块,还用于接收客户端重新发送的目标资源的订阅信息。
一种可选的实施方式中,取消订阅信息包括有目标资源的状态和目标资源的订阅标识。
一种可选的实施方式中,发送模块,具体用于使用订阅注销资源,向客户端发送取消订阅信息,订阅注销资源用于注销目标资源的订阅关系。
一种可选的实施方式中,订阅注销资源包括有目标资源的标识和客户端的标识。
一种可选的实施方式中,接收模块,还用于接收客户端发送的订阅信息,订阅信息用于请求订阅物联网通信装置上的目标资源;
发送模块,还用于向客户端发送订阅响应信息,订阅响应信息用于表征客户端成功订阅目标资源。
本申请还提供一种物联网通信装置,该物联网通信装置可以通过软件、硬件或者两者的结合实现,以执行上述服务端侧的物联网通信方法。该物联网通信装置包括:
接收模块,用于接收服务端发送的取消订阅信息,取消订阅信息用于通知客户端服务端取消目标资源的订阅关系;
发送模块,用于根据取消订阅信息,向服务端重新发送目标资源的订阅信息。
一种可选的实施方式中,取消订阅信息包括有目标资源的状态和目标资源的订阅标识。
一种可选的实施方式中,发送模块,还用于向服务端发送订阅信息, 订阅信息用于请求订阅服务端上的目标资源;
接收模块,还用于接收服务端发送的订阅响应信息,订阅响应信息用于表征物联网通信装置成功订阅目标资源。
本申请实施例提供的物联网通信装置,可以执行上述方法实施例中服务端侧的的物联网通信方法的动作,其实现原理和技术效果类似,在此不再赘述。
图10为本申请实施例提供的一种客户端的结构示意图。如图10所示,该客户端可以包括:处理器201(例如CPU)、存储器202、接收器203和发送器204;接收器203和发送器204耦合至处理器201,处理器201控制接收器203的接收动作、处理器201控制发送器204的发送动作。存储器202可能包含高速RAM存储器,也可能还包括非易失性存储器NVM,例如至少一个磁盘存储器,存储器202中可以存储各种信息,以用于完成各种处理功能以及实现本申请实施例的方法步骤。可选的,本申请实施例涉及的客户端还可以包括:电源205、通信总线206以及通信端口207。接收器203和发送器204可以集成在客户端的收发信机中,也可以为客户端上独立的收发天线。通信总线206用于实现元件之间的通信连接。上述通信端口207用于实现客户端与其他外设之间进行连接通信。
在本申请实施例中,上述存储器202用于存储计算机可执行程序代码,程序代码包括信息;当处理器201执行信息时,信息使处理器201执行上述方法实施例中客户端的处理动作,使发送器204执行上述方法实施例中客户端的发送动作,使接收器203执行上述方法实施例中客户端的接收动作,其实现原理和技术效果类似,在此不再赘述。
图11为本申请实施例提供的一种服务端的结构示意图。如图11所示,该服务端可以包括:处理器211(例如CPU)、存储器212、接收器213和发送器214;接收器213和发送器214耦合至处理器211,处理器211控制接收器213的接收动作、处理器211控制发送器214的发送动作。存储器212可能包含高速RAM存储器,也可能还包括非易失性存储器NVM,例如至少一个磁盘存储器,存储器212中可以存储各种信息,以用于完成各种处理功能以及实现本申请实施例的方法步骤。可选的,本申请实施例涉及的服务端还可以包括:电源215、通信总线216以及通信端口217。接收器213和发送器214可以集成在服务端的收发信机中,也可以为服务端上独立的收发天线。通信总线216用于实现元件之间的通信连接。上述通信端口217用于实现服务端与其他外设之间进行连接通信。
在本申请实施例中,上述存储器212用于存储计算机可执行程序代码,程序代码包括信息;当处理器211执行信息时,信息使处理器211执行上述方法实施例中服务端的处理动作,使发送器214执行上述方法实施例中服务端的发送动作,使接收器213执行上述方法实施例中服务端的接收动作,其实现原理和技术效果类似,在此不再赘述。
本申请实施例还提供一种物联网系统,包括客户端和服务端,客户端和 服务端执行上述物联网通信方法。
本申请实施例还提供了一种芯片,包括处理器和接口。其中接口用于输入输出处理器所处理的数据或指令。处理器用于执行以上方法实施例中提供的方法。该芯片可以应用于服务端中,也可以应用于客户端中。
本发明还提供了一种计算机可读存储介质,该计算机可读存储介质可以包括:U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、磁盘或者光盘等各种可以存储程序代码的介质,具体的,该计算机可读存储介质中存储有程序信息,程序信息用于上述物联网通信方法。
本申请实施例还提供一种程序,该程序在被处理器执行时用于执行以上方法实施例提供的物联网通信方法。
本申请实施例还提供一种程序产品,例如计算机可读存储介质,该程序产品中存储有指令,当其在计算机上运行时,使得计算机执行上述方法实施例提供的物联网通信方法。
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行计算机程序指令时,全部或部分地产生根据本发明实施例的流程或功能。计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,计算机指令可以从一个网站站点、计算机、服务端或数据中心通过有线(例如同轴电缆、光纤、数字用户线(DSL))或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务端或数据中心进行传输。计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可用介质集成的服务端、数据中心等数据存储设备。可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如,DVD)、或者半导体介质(例如固态硬盘Solid State Disk(SSD))等。
最后应说明的是:以上各实施例仅用以说明本发明的技术方案,而非对其限制;尽管参照前述各实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分或者全部技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的范围。

Claims (40)

  1. 一种物联网通信方法,应用于客户端,其特征在于,包括:
    向服务端发送订阅信息,所述订阅信息用于请求订阅所述服务端上的目标资源;
    接收所述服务端发送的订阅响应信息,所述订阅响应信息用于表征客户端成功订阅所述目标资源,所述订阅响应信息中包含有所述目标资源当前状态的有效期;
    当所述目标资源当前状态的有效期过期后,向所述服务端重新发送所述目标资源的订阅信息。
  2. 根据权利要求1所述的方法,其特征在于,在所述目标资源当前状态的有效期过期前,所述方法还包括:
    接收所述服务端发送的所述目标资源的通知信息,所述通知信息用于指示所述目标资源的变化状态,所述通知信息包含有所述目标资源当前状态的有效期的更新值;
    使用所述目标资源当前状态的有效期的更新值,更新所述目标资源当前状态的有效期。
  3. 根据权利要求2所述的方法,其特征在于,在所述向所述服务端重新发送所述目标资源的订阅信息之后,所述方法还包括:
    接收所述服务端发送的错误提示,所述错误提示用于指示所述服务端保存有所述客户端对所述目标资源的订阅关系。
  4. 根据权利要求2或3所述的方法,其特征在于,所述订阅信息、所述订阅响应信息和所述通知信息均包括有令牌标识,所述令牌标识用于指示所述订阅信息、所述订阅响应信息和所述通知信息对应的目标资源。
  5. 一种物联网通信方法,应用于服务端,其特征在于,包括:
    接收客户端发送的订阅信息,所述订阅信息用于请求订阅服务端上的目标资源;
    向所述客户端发送订阅响应信息,所述订阅响应信息用于表征所述客户端成功订阅所述目标资源,所述订阅响应信息中包含有所述目标资源当前状态的有效期;
    当所述目标资源当前状态的有效期过期后,接收所述客户端重新发送的所述目标资源的订阅信息。
  6. 根据权利要求5所述的方法,其特征在于,在所述目标资源当前状态的有效期过期前,所述方法还包括:
    向所述客户端发送所述目标资源的通知信息,所述通知信息用于指示所述目标资源的变化状态,所述通知信息包含有所述目标资源当前状态的有效期的更新值。
  7. 根据权利要求6所述的方法,其特征在于,在所述接收所述客户 端重新发送的所述目标资源的订阅信息之后,所述方法还包括:
    若存在所述客户端对所述目标资源的订阅关系,则向所述客户端发送错误提示。
  8. 根据权利要求6所述的方法,其特征在于,在所述接收所述客户端重新发送的所述目标资源的订阅信息之后,所述方法还包括:
    若不存在所述客户端对所述目标资源的订阅关系,则生成所述客户端对所述目标资源的订阅关系。
  9. 根据权利要求6-8任一项所述的方法,其特征在于,所述订阅信息、所述订阅响应信息和所述通知信息均包括有令牌标识,所述令牌标识用于指示所述订阅信息、所述订阅响应信息和所述通知信息对应的目标资源。
  10. 一种物联网通信方法,应用于服务端,其特征在于,包括:
    确定释放客户端与服务端上的目标资源的订阅关系;
    向所述客户端发送取消订阅信息,所述取消订阅信息用于通知所述客户端所述服务端取消所述目标资源的订阅关系;
    接收所述客户端重新发送的所述目标资源的订阅信息。
  11. 根据权利要求10所述的方法,其特征在于,所述取消订阅信息包括有所述目标资源的状态和所述目标资源的订阅标识。
  12. 根据权利要求10所述的方法,其特征在于,所述向所述客户端发送取消订阅信息,包括:
    使用订阅注销资源,向客户端发送取消订阅信息,所述订阅注销资源用于注销所述目标资源的订阅关系。
  13. 根据权利要求12所述的方法,其特征在于,所述订阅注销资源包括有所述目标资源的标识和所述客户端的标识。
  14. 根据权利要求10-13任一项所述的方法,其特征在于,在所述确定释放客户端与服务端上的目标资源的订阅关系之前,所述方法还包括:
    接收所述客户端发送的订阅信息,所述订阅信息用于请求订阅所述服务端上的目标资源;
    向所述客户端发送订阅响应信息,所述订阅响应信息用于表征所述客户端成功订阅所述目标资源。
  15. 一种物联网通信方法,应用于客户端,其特征在于,包括:
    接收服务端发送的取消订阅信息,所述取消订阅信息用于通知客户端所述服务端取消目标资源的订阅关系;
    根据所述取消订阅信息,向所述服务端重新发送所述目标资源的订阅信息。
  16. 根据权利要求15所述的方法,其特征在于,所述取消订阅信息包括有所述目标资源的状态和所述目标资源的订阅标识。
  17. 根据权利要求15或16所述的方法,其特征在于,在所述接收所述客户端发送的订阅信息之前,所述方法还包括:
    向服务端发送订阅信息,所述订阅信息用于请求订阅所述服务端上的 目标资源;
    接收服务端发送的订阅响应信息,所述订阅响应信息用于表征所述客户端成功订阅所述目标资源。
  18. 一种物联网通信装置,其特征在于,包括:
    发送模块,用于向服务端发送订阅信息,所述订阅信息用于请求订阅所述服务端上的目标资源;
    接收模块,用于接收所述服务端发送的订阅响应信息,所述订阅响应信息用于表征物联网通信装置成功订阅所述目标资源,所述订阅响应信息中包含有所述目标资源当前状态的有效期;
    所述发送模块,还用于当所述目标资源当前状态的有效期过期后,向所述服务端重新发送所述目标资源的订阅信息。
  19. 根据权利要求18所述的装置,其特征在于,所述接收模块,还用于接收所述服务端发送的所述目标资源的通知信息,所述通知信息用于指示所述目标资源的变化状态,所述通知信息包含有所述目标资源当前状态的有效期的更新值;
    所述装置还包括:处理模块,用于使用所述目标资源当前状态的有效期的更新值,更新所述目标资源当前状态的有效期。
  20. 根据权利要求19所述的装置,其特征在于,所述接收模块,还用于接收所述服务端发送的错误提示,所述错误提示用于指示所述服务端保存有所述物联网通信装置对所述目标资源的订阅关系。
  21. 根据权利要求19或20所述的装置,其特征在于,所述订阅信息、所述订阅响应信息和所述通知信息均包括有令牌标识,所述令牌标识用于指示所述订阅信息、所述订阅响应信息和所述通知信息对应的目标资源。
  22. 一种物联网通信装置,其特征在于,包括:
    接收模块,用于接收客户端发送的订阅信息,所述订阅信息用于请求订阅物联网通信装置上的目标资源;
    发送模块,用于向所述客户端发送订阅响应信息,所述订阅响应信息用于表征所述客户端成功订阅所述目标资源,所述订阅响应信息中包含有所述目标资源当前状态的有效期;
    接收模块,用于当所述目标资源当前状态的有效期过期后,接收所述客户端重新发送的所述目标资源的订阅信息。
  23. 根据权利要求22所述的装置,其特征在于,所述发送模块,还用于向所述客户端发送所述目标资源的通知信息,所述通知信息用于指示所述目标资源的变化状态,所述通知信息包含有所述目标资源当前状态的有效期的更新值。
  24. 根据权利要求23所述的装置,其特征在于,所述发送模块,还用于若存在所述客户端对所述目标资源的订阅关系,则向所述客户端发送错误提示。
  25. 根据权利要求23所述的装置,其特征在于,所述装置,还包括:
    处理模块,用于若不存在所述客户端对所述目标资源的订阅关系,则生成所述客户端对所述目标资源的订阅关系。
  26. 根据权利要求23-25任一项所述的装置,其特征在于,所述订阅信息、所述订阅响应信息和所述通知信息均包括有令牌标识,所述令牌标识用于指示所述订阅信息、所述订阅响应信息和所述通知信息对应的目标资源。
  27. 一种物联网通信装置,其特征在于,包括:
    处理模块,用于确定释放客户端与物联网通信装置上的目标资源的订阅关系;
    发送模块,用于向所述客户端发送取消订阅信息,所述取消订阅信息用于通知服务端取消所述目标资源的订阅关系;
    接收模块,还用于接收所述客户端重新发送的所述目标资源的订阅信息。
  28. 根据权利要求27所述的装置,其特征在于,所述取消订阅信息包括有所述目标资源的状态和所述目标资源的订阅标识。
  29. 根据权利要求27所述的装置,其特征在于,所述发送模块,具体用于使用订阅注销资源,向客户端发送取消订阅信息,所述订阅注销资源用于注销所述目标资源的订阅关系。
  30. 根据权利要求29所述的装置,其特征在于,所述订阅注销资源包括有所述目标资源的标识和所述客户端的标识。
  31. 根据权利要求27-30任一项所述的装置,其特征在于,所述接收模块,还用于接收所述客户端发送的订阅信息,所述订阅信息用于请求订阅所述物联网通信装置上的目标资源;
    所述发送模块,还用于向所述客户端发送订阅响应信息,所述订阅响应信息用于表征所述客户端成功订阅所述目标资源。
  32. 一种物联网通信装置,其特征在于,包括:
    接收模块,用于接收服务端发送的取消订阅信息,所述取消订阅信息用于通知客户端所述服务端取消目标资源的订阅关系;
    发送模块,用于根据所述取消订阅信息,向所述服务端重新发送所述目标资源的订阅信息。
  33. 根据权利要求32所述的装置,其特征在于,所述取消订阅信息包括有所述目标资源的状态和所述目标资源的订阅标识。
  34. 根据权利要求32或33所述的装置,其特征在于,所述发送模块,还用于向服务端发送订阅信息,所述订阅信息用于请求订阅所述服务端上的目标资源;
    所述接收模块,还用于接收服务端发送的订阅响应信息,所述订阅响应信息用于表征所述物联网通信装置成功订阅所述目标资源。
  35. 一种客户端,其特征在于,包括:处理器、存储器、发送器和接收器;
    所述存储器用于存储计算机程序,所述处理器用于调用并运行所述存储器中存储的计算机程序,执行如权利要求1至4或15-17中任一项所述的方法;
    所述发送器用于执行所述客户端的发送动作,所述接收器用于执行所述客户端的接收动作。
  36. 一种服务端,其特征在于,包括:处理器、存储器、发送器和接收器;
    所述存储器用于存储计算机程序,所述处理器用于调用并运行所述存储器中存储的计算机程序,执行如权利要求5至14中任一项所述的方法;
    所述发送器用于执行所述服务端的发送动作,所述接收器用于执行所述服务端的接收动作。
  37. 一种芯片,其特征在于,包括:处理器,用于从存储器中调用并运行计算机程序,使得安装有所述芯片的设备执行如权利要求1至17中任一项所述的方法。
  38. 一种计算机可读存储介质,其特征在于,用于存储计算机程序,所述计算机程序使得计算机执行如权利要求1至17中任一项所述的方法。
  39. 一种计算机程序产品,其特征在于,包括计算机程序信息,该计算机程序信息使得计算机执行如权利要求1至17中任一项所述的方法。
  40. 一种计算机程序,其特征在于,所述计算机程序使得计算机执行如权利要求1至21中任一项所述的方法。
PCT/CN2020/079776 2020-03-17 2020-03-17 物联网通信方法及装置 WO2021184216A1 (zh)

Priority Applications (6)

Application Number Priority Date Filing Date Title
KR1020227032596A KR20220155307A (ko) 2020-03-17 2020-03-17 사물 인터넷의 통신 방법 및 장치
JP2022556458A JP2023524367A (ja) 2020-03-17 2020-03-17 モノのインターネットの通信方法及び装置
PCT/CN2020/079776 WO2021184216A1 (zh) 2020-03-17 2020-03-17 物联网通信方法及装置
EP20926201.3A EP4109835A4 (en) 2020-03-17 2020-03-17 INTERNET OF THINGS COMMUNICATION METHOD AND DEVICE
CN202080095226.8A CN115053507A (zh) 2020-03-17 2020-03-17 物联网通信方法及装置
US17/945,294 US20230017797A1 (en) 2020-03-17 2022-09-15 Internet of things communication method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2020/079776 WO2021184216A1 (zh) 2020-03-17 2020-03-17 物联网通信方法及装置

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US17/945,294 Continuation US20230017797A1 (en) 2020-03-17 2022-09-15 Internet of things communication method and apparatus

Publications (1)

Publication Number Publication Date
WO2021184216A1 true WO2021184216A1 (zh) 2021-09-23

Family

ID=77769956

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/079776 WO2021184216A1 (zh) 2020-03-17 2020-03-17 物联网通信方法及装置

Country Status (6)

Country Link
US (1) US20230017797A1 (zh)
EP (1) EP4109835A4 (zh)
JP (1) JP2023524367A (zh)
KR (1) KR20220155307A (zh)
CN (1) CN115053507A (zh)
WO (1) WO2021184216A1 (zh)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101064692A (zh) * 2006-04-27 2007-10-31 华为技术有限公司 一种呈现信息的发布方法、设备及系统
CN101119325A (zh) * 2006-08-04 2008-02-06 华为技术有限公司 一种提供观察者信息的方法和呈现服务器
CN101754486A (zh) * 2008-10-10 2010-06-23 华为终端有限公司 订阅、去订阅移动广告业务的方法及装置
CN103491100A (zh) * 2013-09-30 2014-01-01 中国科学院计算技术研究所 一种在多方间构建令牌关联关系的系统
US10074115B1 (en) * 2013-08-14 2018-09-11 Amazon Technologies, Inc. Subscription management service

Family Cites Families (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7474741B2 (en) * 2003-01-20 2009-01-06 Avaya Inc. Messaging advise in presence-aware networks
US8060640B2 (en) * 2005-05-27 2011-11-15 Microsoft Corporation Combining SIP requests with SIP responses
WO2007009396A1 (fr) * 2005-07-22 2007-01-25 Huawei Technologies Co., Ltd. Méthode et dispositif d’abonnement
CN101325563B (zh) * 2007-06-13 2011-10-05 华为技术有限公司 一种呈现互连网关和互连方法
US7912969B2 (en) * 2008-01-09 2011-03-22 International Business Machines Corporation Methods and apparatus for randomization of periodic behavior in communication network
WO2010000314A1 (en) * 2008-07-01 2010-01-07 Telefonaktiebolaget Lm Ericsson (Publ) Signalling optimisation in a presence service
CN105580327B (zh) * 2013-09-27 2018-12-18 Lg电子株式会社 用于在m2m系统中传送通知消息的方法及其装置
US10148665B2 (en) * 2016-05-10 2018-12-04 Microsoft Technology Licensing, Llc Self-service acquisition of subscriptions to online services
EP3485656B1 (en) * 2016-07-14 2021-06-16 Convida Wireless, LLC Subscription and notification service
EP3662638B1 (en) * 2017-08-04 2021-09-22 Nokia Technologies Oy Transport method selection for delivery of server notifications
WO2019194242A1 (en) * 2018-04-06 2019-10-10 Nec Corporation Security procedures for common api framework in next generation networks

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101064692A (zh) * 2006-04-27 2007-10-31 华为技术有限公司 一种呈现信息的发布方法、设备及系统
CN101119325A (zh) * 2006-08-04 2008-02-06 华为技术有限公司 一种提供观察者信息的方法和呈现服务器
CN101754486A (zh) * 2008-10-10 2010-06-23 华为终端有限公司 订阅、去订阅移动广告业务的方法及装置
US10074115B1 (en) * 2013-08-14 2018-09-11 Amazon Technologies, Inc. Subscription management service
CN103491100A (zh) * 2013-09-30 2014-01-01 中国科学院计算技术研究所 一种在多方间构建令牌关联关系的系统

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP4109835A4 *

Also Published As

Publication number Publication date
US20230017797A1 (en) 2023-01-19
JP2023524367A (ja) 2023-06-12
EP4109835A1 (en) 2022-12-28
CN115053507A (zh) 2022-09-13
EP4109835A4 (en) 2023-04-12
KR20220155307A (ko) 2022-11-22

Similar Documents

Publication Publication Date Title
US11750702B2 (en) Subscription and notification service
US20210227367A1 (en) Cross-resource subscription for m2m service layer
US20220141311A1 (en) Resource subscription method, device and server, and computer storage medium
US9729651B2 (en) Method for delivering push notification and push notification server for performing the same
US20170223128A1 (en) Intermediary for multiple-transport client-device communications
US11108837B2 (en) Media downlink transmission control method and related device
CN110808948B (zh) 远程过程调用方法、装置及系统
KR102238111B1 (ko) 디바이스의 업로드 크기를 제어하는 방법 및 장치
US11658870B2 (en) Method and apparatus for restoring network device to factory defaults, and network device
US11617063B2 (en) Method, apparatus, and system for changing association relationship between MCPTT user and MCPTT group
KR20150031170A (ko) 푸시 알림 전송 방법 및 이를 수행하는 푸시 알림 서버
KR20220150346A (ko) 차량 내 시스템에 로그인하기 위한 방법 및 관련 장치
CN110324384B (zh) 数据推送的方法和装置
US20160100021A1 (en) Information processing device, destination information updating method, and record medium
WO2021184216A1 (zh) 物联网通信方法及装置
US10904746B2 (en) Implementation method, apparatus and system for remote access
US20200274786A1 (en) Apparatus and method for managing message transmission delay
JP2014041404A (ja) ターミナルサービス監視装置
CN113992740B (zh) 一种基于自主可控的中间件及数据传输方法
CN106230878B (zh) 一种基于AllJoyn框架的设备服务调用方法及装置
KR20170130801A (ko) 프로비저닝 운용 방법 및 이를 지원하는 전자 장치
KR101274774B1 (ko) 재접속 메시지를 이용한 푸쉬 서비스 제공 시스템 및 그 방법
US20190312929A1 (en) Information synchronization method and device
CN115086263B (zh) Ios终端的im消息发送方法、系统、存储介质、计算机设备
EP4383858A1 (en) Electronic device for processing large amount of data in open radio access network and method for operating same

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: 20926201

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2022556458

Country of ref document: JP

Kind code of ref document: A

ENP Entry into the national phase

Ref document number: 2020926201

Country of ref document: EP

Effective date: 20220920

NENP Non-entry into the national phase

Ref country code: DE