CN110741361A - Resource query processing method and device, computer equipment and storage medium - Google Patents

Resource query processing method and device, computer equipment and storage medium Download PDF

Info

Publication number
CN110741361A
CN110741361A CN201880037186.4A CN201880037186A CN110741361A CN 110741361 A CN110741361 A CN 110741361A CN 201880037186 A CN201880037186 A CN 201880037186A CN 110741361 A CN110741361 A CN 110741361A
Authority
CN
China
Prior art keywords
resource
query
rcd
request message
response message
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.)
Granted
Application number
CN201880037186.4A
Other languages
Chinese (zh)
Other versions
CN110741361B (en
Inventor
唐海
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Publication of CN110741361A publication Critical patent/CN110741361A/en
Application granted granted Critical
Publication of CN110741361B publication Critical patent/CN110741361B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2455Query execution
    • G06F16/24564Applying rules; Deductive queries
    • G06F16/24566Recursive queries
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/955Retrieval from the web using information identifiers, e.g. uniform resource locators [URL]

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application relates to resource query processing methods, devices, computer equipment and storage media, wherein an RD searches resource information meeting query conditions in a resource file according to a query mode in a th resource query request message, if the query mode is recursive query and the queried resource information comprises resource links of resource-limited equipment, a preset processing mechanism is adopted to process the th resource query request message, in the method, because various processing modes of the RD when the query mode is recursive query and the queried corresponding resource information comprises the resource links of the resource-limited equipment are preset, the RD can process the th resource query request message by adopting a corresponding processing mode according to the preset processing mechanism, and the efficiency of processing the resource query request by the RD is improved.

Description

Resource query processing method and device, computer equipment and storage medium
Technical Field
The application relates to the technical field of internet of things, in particular to resource query processing methods and devices, computer equipment and storage media.
Background
With the development of the internet of things and smart home technology and industry, intelligent household appliances begin to enter the lives of ordinary residents, and intelligent household appliance devices can be divided into ordinary devices (NDs) and Resource Constrained Devices (RCDs). The common device is a device with strong capability in the aspects of processing speed, continuous work, networking and the like, the resource-limited device is relatively deficient in hardware resources compared with the common device, so that the service processing capability and the cruising capability of the resource-limited device are poor, and the resource-limited device may periodically enter a sleep state (saving power) in a network or cannot process a large batch of service requests in real time and the like.
At present, solutions of proxy devices exist in the industry, which mainly help Resource-constrained devices to process Resource query requests, a proxy device (RD) is generally a device with strong processing capability and networked in real time, is generally a device that an RCD selects an RD and issues its own Resource link (Resource Links) to the RD, and after the RCD receives a Resource query request again, the RCD may not respond to the Resource query request any more, but the RD responds to the Resource query request.
However, when there is a resource link of RCD device resources in the RD and the query method is set as recursive query, it is problems to be solved urgently how the RD should handle.
Disclosure of Invention
Based on this, it is necessary to provide resource query processing methods, apparatuses, computer devices, and storage media for the above technical problem of how an RD should process when a resource link of an RCD device resource exists in the RD and the query method is set as a recursive query.
, an embodiment of the invention provides resource query processing methods, the method comprising:
receiving th resource query request message, wherein the th resource query request message comprises a query mode and a query condition;
inquiring a resource file according to the resource inquiry request, and acquiring resource information corresponding to the resource inquiry request; the resource file comprises release resource information of the agent device RD and release resource information of the RCD;
and if the query mode is recursive query and the resource information comprises the resource link of the RCD, processing the th resource query request message by adopting a preset processing mechanism.
In embodiments, the processing the resource query request message by using a preset processing mechanism includes:
according to the resource information, response message is obtained;
and sending the th response message to a query end.
In embodiments, the obtaining response message according to the resource information includes:
changing the query mode into a link query;
acquiring the resource link of the RCD according to the resource information by adopting the link query mode;
and carrying the resource link of the RCD in the th response message.
In embodiments, the response message is a redirection message, and the redirection message is used to instruct the querying end to acquire the required resources from the RCD.
In embodiments, the obtaining response message according to the resource information includes:
determining a target RCD according to the resource information;
sending a second resource query request message to the target RCD; the second resource query request message is used for indicating the target RCD to query the resources required by the query terminal;
receiving a second response message sent by the target RCD; the second response message comprises resources required by the query end;
generating th response message according to the second response message.
In embodiments, if there are multiple target RCDs, the generating the response message from the second response message includes:
and generating th response messages according to the second response messages sent by the target RCDs.
In embodiments, the processing the resource query request message by using a preset processing mechanism includes:
discarding the th resource query request message.
In embodiments, if the query manner is a recursive query and the resource information includes the issued resource information of the RD, the resource meeting the query condition is obtained in the recursive query manner.
In embodiments, the method further comprises:
receiving a resource release request sent by an RCD of a resource to be released; the resource publishing request comprises the equipment identification and attribute information of the RCD of the resource to be published;
authenticating the RCD of the resource to be issued according to the resource issuing request;
and if the authentication is passed, storing the release resource information of the RCD of the resource to be released into the resource file according to the resource release request.
In a second aspect, an embodiment of the present invention provides resource query processing apparatuses, including:
a th receiving module, configured to receive th resource query request message, where the th resource query request message includes a query mode and a query condition;
the acquisition module is used for inquiring the resource file according to the resource inquiry request and acquiring the resource information corresponding to the resource inquiry request; the resource file comprises release resource information of the agent device RD and release resource information of the RCD;
and the processing module is used for processing the th resource query request message by adopting a preset processing mechanism if the query mode is recursive query and the resource information comprises the resource link of the RCD.
In a third aspect, an embodiment of the present invention provides computer devices, including a memory and a processor, the memory storing a computer program, the processor implementing the following steps when executing the computer program:
receiving th resource query request message, wherein the th resource query request message comprises a query mode and a query condition;
inquiring a resource file according to the resource inquiry request, and acquiring resource information corresponding to the resource inquiry request; the resource file comprises release resource information of the agent device RD and release resource information of the RCD;
and if the query mode is recursive query and the resource information comprises the resource link of the RCD, processing the th resource query request message by adopting a preset processing mechanism.
In a fourth aspect, embodiments of the present invention provide computer readable storage media having stored thereon a computer program that, when executed by a processor, performs the steps of:
receiving th resource query request message, wherein the th resource query request message comprises a query mode and a query condition;
inquiring a resource file according to the resource inquiry request, and acquiring resource information corresponding to the resource inquiry request; the resource file comprises release resource information of the agent device RD and release resource information of the RCD;
and if the query mode is recursive query and the resource information comprises the resource link of the RCD, processing the th resource query request message by adopting a preset processing mechanism.
According to resource query processing methods, apparatuses, computer devices and storage media provided by the present application, an RD queries in a resource file including RD published resource information and RCD published resource information according to a received th resource query request message including a query mode and a query condition, obtains resource information corresponding to the th resource query request message therefrom, and processes a th resource query request message by using a preset processing mechanism when the query mode is recursive query and the queried corresponding resource information includes a resource link of the RCD.
Drawings
FIG. 1 is an application environment diagram of resource query processing methods provided by embodiments;
FIG. 2 is a schematic flowchart of a processing method for resource queries provided by embodiments;
FIG. 3 is a schematic flowchart of a resource query processing method provided by embodiments;
FIG. 4 is a schematic flowchart of a resource query processing method provided by embodiments;
FIG. 5 is a schematic flowchart of a resource query processing method provided by embodiments;
FIG. 6 is a block diagram illustrating the structure of a resource query processing device according to exemplary embodiments;
FIG. 7 is a block diagram illustrating the structure of a resource query processing device according to exemplary embodiments;
FIG. 8 is a block diagram illustrating the structure of a resource query processing device according to exemplary embodiments;
FIG. 9 is a block diagram illustrating the structure of a resource query processing device according to exemplary embodiments;
fig. 10 is an internal structural view of a computer device in embodiments.
Detailed Description
For purposes of making the present application, its objects, aspects and advantages more apparent, the present application is described in further detail with reference to the drawings and the examples.
The resource query processing method provided by the application can be applied to the application environment shown in fig. 1. The Device a and the Device D are Resource Constrained Devices (RCDs), the Device B is a proxy Device (RD), and the Device C is a query end, where the communication modes between the query end and the RD and between the RCDs and the RDs may be wireless communication, for example: the modes of infrared communication, bluetooth communication, 2G, 3G, 4G, 5G, etc. may also be wired communication, for example: a communication cable, etc., but this embodiment is not limited thereto. The device a and the device D (i.e., RCD) may publish their own resources to the device B (i.e., RD), and the device C (query end) may query the resources on the device a and the device D (i.e., RCD) through the device B (i.e., RD). The query end can be, but is not limited to, various personal computers, notebook computers, smart phones, tablet computers and portable wearable devices.
The embodiments of the present application provide resource query processing methods, apparatuses, computer devices, and storage media, which are intended to solve the technical problem how an RD should process when a resource link of an RCD device resource exists in the RD and the query method is set as a recursive query.
To make the objects, technical solutions and advantages of the embodiments of the present invention clearer and more complete, the technical solutions in the embodiments of the present invention will be described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are partial embodiments of of the present invention, rather than all embodiments.
In embodiments, fig. 2 provides resource query processing methods, and this embodiment relates to a specific process in which an RD processes a th resource query request message when a query manner in a th resource request is recursive query, as shown in fig. 2, the method includes:
s101, receiving th resource query request message, wherein the th resource query request message comprises a query mode and a query condition.
For example, if the RCD is lamps, the resource query request message may be to obtain attribute information of the lamps, such as color rendering index, color rendering color temperature, and light stroboscopic information of the lamps, where the resource query request message may include a query manner and a query condition, the query manner may be a characteristic attribute query, a recursive query, a link query, and the like, where the characteristic attribute query only obtains values of characteristic value attributes in the resources, such as only obtains values of temperature attributes when querying thermometer resources, and other public attributes do not make queries.
For example, The th resource query request message may be in a format of a restricted application Protocol (CoAP) request message, and a query manner and a query condition may be set in a query part of The th resource query request message.
S102, inquiring a resource file according to the th resource inquiry request message, and acquiring resource information corresponding to the th resource inquiry request message, wherein the resource file comprises the published resource information of the RD and the published resource information of the RCD.
The resource file is stored in the RD and includes a file of the release resource information of the RD and the release resource information of the RCD, where the release resource information of the RD and the release resource information of the RCD may be resource information that can be queried by each device, and the release resource information may include a resource type, an address, and the like of the device, which is not limited in this embodiment. The resource file may be in an oic/res format, the resource type of the RD issuing the resource information may be oic.
In this embodiment, the RD searches the resource information meeting the query condition in the resource file according to the query mode in the th resource query request message, for example, the query mode in the th resource query request message is recursive query, and the query condition is a lamp, the RD searches the resource information of all resource types as lamps in the resource file in the recursive query mode.
And S103, if the query mode is recursive query and the resource information comprises the resource link of the RCD, processing the th resource query request message by adopting a preset processing mechanism.
In this embodiment, if the query manner carried in the th resource query request message is recursive query and the acquired resource information corresponding to the th resource query request message includes a resource link of an RCD, a preset processing mechanism is used to process the th resource query request message, where the resource link of the RCD represents an acquisition path of the resource information issued by the RCD, for example, the resource link of the RCD may include a resource address, a type, an available interface, an IP address, and the like, which is not limited in this embodiment.
In this embodiment, a corresponding processing mechanism may be specified in advance, and when the query mode is recursive query and the resource information includes a resource link of the RCD, processing may be performed according to the processing mechanism, for example, the processing mechanism may be the query mode is recursive query, and when the resource information includes the resource link of the RCD, the -th resource query request message is directly ignored, or the resource link of the RCD is fed back to the query end, or the corresponding RCD is directly accessed to obtain a query resource, and the like.
In the resource query processing method provided by this embodiment, the RD searches resource information meeting the query condition in the resource file according to the query mode in the th resource query request message, and if the query mode is recursive query and the queried resource information includes resource links of RCDs, the th resource query request message is processed by using a preset processing mechanism.
Optionally, in embodiments, the processing the resource query request message with a preset processing mechanism in step S103 includes discarding the resource query request message.
In this embodiment, if the RD processes the th resource query request message according to the preset processing mechanism, and if the query mode is recursive query and the queried resource information includes the resource link of the RCD, the RD discards the th resource query request message, that is, directly ignores the th resource query request message.
In embodiments, fig. 3 provides resource query processing methods, and this embodiment relates to processing mechanisms of an RD if the query mode is recursive query and the queried resource information includes a resource link of an RCD, as shown in fig. 3, the above "processing the th resource query request message by using a preset processing mechanism" includes:
s201, according to the resource information, obtaining th response message.
Wherein the th response message is used for representing the resource query result.
In this embodiment, if the resource information includes the resource connection of the RCD, the resource connection of the RCD may be used as a query result to generate an th response message, or if the resource information includes the specific information of the query resource, the specific information of the query resource may be used as a resource query result to generate an th response message, for example, the th resource query request message is to obtain the color rendering index and the color rendering color temperature of the luminaire, the th response message may include the specific color rendering index and the color rendering color temperature of the luminaire, or the th response message may include the identifier, the address, the query interface, and the like of the luminaire, which is not limited in this embodiment.
Optionally, the implementation manners of the step S201 include changing the query manner to a link query manner, obtaining the resource link of the RCD according to the resource information in the link query manner, and carrying the resource link of the RCD in the response message.
In this embodiment, since the resource link cannot be obtained through the recursive query method, the query method needs to be changed to a link query method, for example, the recursive query method (oic.if.b) may be changed to a link query method (oic.if.ll), the resource link of the RCD is obtained through the link query method, and the resource link of the RCD is carried in the -th response message, where the resource link of the RCD represents a link path of the RCD issuing resource information, for example, the RCD is the luminaire a, the resource link of the RCD may be the luminaire a device identifier, the resource address, the type, the available interface, the IP address, and the like, and the RD may generate the -th response message according to the luminaire a device identifier, the resource address, the type, the available interface, the IP address, and the like.
Optionally, the th response message is a redirection message, and the redirection message is used to instruct the querying end to acquire the required resources from the RCD, wherein, after receiving the th response message, the querying end acquires the required resources from the corresponding RCD according to the th response message.
S202, the th response message is sent to the inquiry end.
For example, if the th response message includes the resource link of the resource-restricted device a and the th response message is a normal response message, the query end may continue to query the resource-restricted device a for the required resource, or may not query the resource-restricted device a for the required resource, and if the th response message includes the resource link of the resource-restricted device a and the th response message is a redirection message, the query end must query the resource-restricted device a for the required resource.
In the resource query processing method provided by this embodiment, the RD acquires the th response message according to the resource information corresponding to the th resource query request message, sends the th response message to the querying end, and informs the querying end of the query result, which solves the technical problem of how to process the RD when resource links of RCD device resources exist in the RD and the query method is set as recursive query.
In embodiments, fig. 4 provides resource query processing methods, and this embodiment relates to a specific process in which an RD acquires a th response message according to resource information, as shown in fig. 4, the foregoing S201 includes:
s301, determining the target RCD according to the resource information.
In this embodiment, since the resource information includes the resource link of the RCD, the RD may determine the target RCD according to the resource link of the RCD, for example, if the resource link of the RCD includes information such as an identifier, an address, and an interface of the RCD, the target RCD may be determined according to the identifier, the address, and the interface of the RCD.
It should be noted that the resource information may include resource links of RCDs, or may include resource links of multiple RCDs, and the determined target RCD may include RCDs, or may include multiple RCDs.
S302, sending a second resource query request message to the target RCD; the second resource query request message is used for instructing the target RCD to query the resources required by the query end.
Based on the target RCD determined in the step S301, the RD sends a second resource query request message to the target RCD, where the second resource request is used to instruct the target RCD to query the resource required by the query end, that is, to query the resource requested by the th resource query request message.
For example: assuming that the target RCD is the lamp a, the RD sends a second resource query request message to the lamp a to obtain the color rendering index of the lamp a, and the lamp a returns the display index of itself to the RD when receiving the request.
It should be noted that, if the target RCD includes multiple RCDs, the RD sends a second resource query request message to each RCD.
S303, receiving a second response message sent by the target RCD; the second response message includes resources required by the querying end.
In this step, after receiving the second resource query request message, the target RCD feeds back the second response message carried by the required resource information to the RD according to the second resource query request message. For example, the target RCD is a refrigerator, the second resource query request message is used to query the temperature of the refrigerator, and the refrigerator feeds back the current temperature of the refrigerator to the RD by carrying the current temperature in the second response message.
S304, generating the th response message according to the second response message.
Based on the above step S302, the RD receives the second response message sent by the target RCD, and generates th response message according to the second response message, and since the second response message is the result of the target RCD querying the second resource query request message sent by the RD, th response message generated according to the second response message includes the resource required by the querying end, wherein the manner of generating th response message according to the second response message may be, for example, converting the second response message into the format required by th response message, or other manners, which is not limited in this embodiment.
Considering that the resource query request sent by the query end is not only to ask RCDs for resources in some cases, optionally, if there are a plurality of target RCDs, the generating the th response message according to the second response message includes generating the th response message according to the second response message sent by each target RCD, where when there are a plurality of target RCDs, the RD sends corresponding second resource query request messages to the plurality of target RCDs, and after each target RCD receives the second resource query request message, the result queried according to the second resource query request message is returned to the RD as the second response message, and then the RD integrates the second response messages sent by all the target RCDs to generate the th response message.
In the resource query request method provided by this embodiment, the RD determines the target RCD according to the resource information, then sends a second resource query request message for instructing the target RCD to query the resource required by the query end to the target RCD, and generates the th response message according to the second response message including the resource required by the query end fed back by the target RCD, which can ensure that the RD can still obtain the resource required by the query end when the query mode is recursive query and the resource information includes the resource link of the RCD, thereby improving the query efficiency.
The embodiment of the present application further provides methods for processing the issued resource information of the RD, and optionally, if the query mode is recursive query, and the resource information includes the issued resource information of the RD, the resource meeting the query condition is obtained by using the recursive query mode.
In this embodiment, if the query portion of the -th resource query request message is if, and ic.wk.rd, the query method is a recursive query, and the corresponding resource information includes the issued resource information of the RD, a recursive query method is adopted to obtain a resource that meets the query condition.
In embodiments, fig. 5 provides resource query processing methods, and this embodiment relates to a specific process of issuing a queryable resource of an RCD to an RD, as shown in fig. 5, the method further includes:
s401, receiving a resource publishing request sent by an RCD of a resource to be published; the resource publishing request comprises the equipment identification and the attribute information of the RCD of the resource to be published.
In this embodiment, when the RCD of the resource to be issued needs to issue the resource, the RD may be selected first, and the resource issue request is sent to the RD. The resource publishing request sent by the RCD of the resource to be published includes its own device identifier and attribute information, where the device attribute information includes a resource address, a type, an available interface, an IP address, and the like, which is not limited in this embodiment.
Optionally, when the RCD of the resource to be published selects an RD, a broadcast request may be sent first, where the broadcast request is used to indicate that the RCD needs the resource to be published, and a response message of the received RD, where or more than RD. are selected from the responding RD, RCDs may determine or more than RD, &lttttransition = one "&ttt-l/t &tttrd may also correspond to or more than RCD.
S402, according to the resource issuing request, the RCD of the resource to be issued is authenticated.
In this embodiment, the RD authenticates the RCD that sends the requested resource to be issued according to the resource issuing request, where the authentication indicates that the RD wants to identify whether the RCD that sends the requested resource to be issued has the right to issue the resource on the RD, where a manner in which the RD authenticates the RCD that sends the resource to be issued may be, for example, by identifying whether the RCD that sends the resource to be issued is a device that has already been bound to the RD, or other manners of identification, which is not limited in this embodiment.
And S403, if the authentication is passed, storing the release resource information of the RCD of the resource to be released into the resource file according to the resource release request.
Based on the result obtained after the RD authenticates the RCD of the resource to be issued in the step S402, if the authentication result is passed, the RD stores the resource information issued by the RCD of the resource to be issued in its own resource file, where the resource information issued by the RCD of the resource to be issued may be any information of the RCD of the resource to be issued, for example: parameter information, usage details information, and the like, which are not limited in this embodiment.
In the resource query processing methods provided by this embodiment, an RD receives a resource publishing request including a device identifier and attribute information of an RCD of a resource to be published, which is sent by the RCD of the resource to be published, authenticates the RCD of the corresponding resource to be published according to the resource publishing request, and stores the resource publishing information of the RCD of the resource to be published in a resource file if the authentication is passed.
It should be understood that although the various steps in the flow charts of fig. 2-5 are shown in sequence as indicated by the arrows, the steps are not necessarily performed in the order indicated by the arrows, unless explicitly stated herein, the steps may be performed in other sequences without strict order limitations, and further, at least the portion of the step of in fig. 2-5 may include multiple sub-steps or stages that are not necessarily performed at the same time , but may be performed at different times, the order of performance of the sub-steps or stages may not necessarily be performed in sequence, but may be rotated or alternated with at least portions of other steps or sub-steps or stages of other steps.
In embodiments, as shown in fig. 6, resource query processing apparatuses are provided, which include a receiving module 10, an obtaining module 11, and a processing module 12, wherein:
is a receiving module 10 for receiving resource query request message, wherein the resource query request message includes query mode and query condition;
an obtaining module 11, configured to query a resource file according to the resource query request, and obtain resource information corresponding to the resource query request; the resource file comprises release resource information of the agent device RD and release resource information of the RCD;
and a processing module 12, configured to, if the query manner is recursive query and the resource information includes the resource link of the RCD, process the th resource query request message by using a preset processing mechanism.
The implementation principle and technical effect of the resource query processing apparatuses provided in the above embodiments are similar to those of the above method embodiments, and are not described herein again.
In embodiments, as shown in fig. 7, resource query processing apparatuses are provided, where the processing module 12 includes an obtaining unit 121 and a sending unit 122, where:
an obtaining unit 121, configured to obtain an th response message according to the resource information;
a sending unit 122, configured to send the th response message to the querying end.
The implementation principle and technical effect of the resource query processing apparatuses provided in the above embodiments are similar to those of the above method embodiments, and are not described herein again.
In embodiments, the obtaining unit 121 is specifically configured to change the query manner to a link query manner, obtain the resource link of the RCD according to the resource information in the link query manner, and carry the resource link of the RCD in the response message.
The implementation principle and technical effect of the resource query processing apparatuses provided in the above embodiments are similar to those of the above method embodiments, and are not described herein again.
In embodiments, if the th response message is a redirection message, the redirection message is used to instruct the querying end to acquire the required resource from the RCD.
The implementation principle and technical effect of the resource query processing apparatuses provided in the above embodiments are similar to those of the above method embodiments, and are not described herein again.
In embodiments, as shown in fig. 8, resource query processing apparatuses are provided, where the obtaining unit 121 includes a determining subunit 1211, a sending subunit 1212, a receiving subunit 1213, and a generating subunit 1214, where:
a determining subunit 1211, configured to determine a target RCD according to the resource information.
A sending subunit 1212, configured to send a second resource query request message to the target RCD; the second resource query request message is used for instructing the target RCD to query the resources required by the query end.
A receiving subunit 1213, configured to receive the second response message sent by the target RCD; the second response message includes resources required by the querying end.
A generating subunit 1214, configured to generate the th response message according to the second response message.
The implementation principle and technical effect of the resource query processing apparatuses provided in the above embodiments are similar to those of the above method embodiments, and are not described herein again.
In embodiments, the generating subunit 1214 is specifically configured to, if there are multiple target RCDs, generate the th response message according to the second response message sent by each of the target RCDs.
In embodiments, the processing module 12 is further configured to discard the resource query request message.
The implementation principle and technical effect of the resource query processing apparatuses provided in the above embodiments are similar to those of the above method embodiments, and are not described herein again.
In embodiments, the processing module 12 is further configured to, if the query manner is a recursive query and the resource information includes the issued resource information of the RD, acquire a resource meeting the query condition in the recursive query manner.
In embodiments, as shown in fig. 9, resource query processing devices are provided, the method further includes a second receiving module 13, an authenticating module 14 and a storing module 15, wherein:
a second receiving module 13, configured to receive a resource publishing request sent by an RCD of a resource to be published; the resource publishing request comprises the equipment identification and attribute information of the RCD of the resource to be published;
the authentication module 14 is configured to authenticate the RCD of the resource to be issued according to the resource issuing request;
and the storage module 15 is configured to, if the authentication is passed, store the release resource information of the RCD of the resource to be released into the resource file according to the resource release request.
The implementation principle and technical effect of the resource query processing apparatuses provided in the above embodiments are similar to those of the above method embodiments, and are not described herein again.
For the specific limitation of the resource query processing device, reference may be made to the above limitation on the resource query processing method, which is not described herein again. The modules in the resource query processing device can be wholly or partially implemented by software, hardware and a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In embodiments, there are provided kinds of computer devices, which may be servers, the internal structure of which may be as shown in FIG. 10, the computer devices include a processor, a memory, a network interface and a database connected by a system bus, wherein the processor of the computer device is used to provide computing and control capabilities.
Those skilled in the art will appreciate that the architecture shown in fig. 10 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In embodiments, computer devices are provided, comprising a memory and a processor, the memory having stored therein a computer program, the processor when executing the computer program implementing the steps of:
receiving th resource query request message, wherein the th resource query request message comprises a query mode and a query condition;
inquiring a resource file according to the resource inquiry request, and acquiring resource information corresponding to the resource inquiry request; the resource file comprises release resource information of the agent device RD and release resource information of the RCD;
and if the query mode is recursive query and the resource information comprises the resource link of the RCD, processing the th resource query request message by adopting a preset processing mechanism.
The implementation principle and technical effect of the computer devices provided by the above embodiments are similar to those of the above method embodiments, and are not described herein again.
In embodiments, computer readable storage media are provided, on which a computer program is stored which, when executed by a processor, performs the steps of:
receiving th resource query request message, wherein the th resource query request message comprises a query mode and a query condition;
inquiring a resource file according to the resource inquiry request, and acquiring resource information corresponding to the resource inquiry request; the resource file comprises release resource information of the agent device RD and release resource information of the RCD;
and if the query mode is recursive query and the resource information comprises the resource link of the RCD, processing the th resource query request message by adopting a preset processing mechanism.
The implementation principle and technical effect of the computer-readable storage media provided by the above embodiments are similar to those of the above method embodiments, and are not described herein again.
It will be understood by those of ordinary skill in the art that all or a portion of the processes of the methods of the embodiments described above may be implemented by a computer program that may be stored in a non-volatile computer-readable storage medium, which when executed, may include the processes of the embodiments of the methods described above, wherein any reference to memory, storage, database, or other medium used in the embodiments provided herein may include non-volatile and/or volatile memory.
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features. The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (12)

1, resource query processing method, characterized in that, the method includes:
receiving th resource query request message, wherein the th resource query request message comprises a query mode and a query condition;
inquiring a resource file according to the th resource inquiry request message to acquire resource information corresponding to the th resource inquiry request message, wherein the resource file comprises issued resource information of a proxy device RD and issued resource information of a resource limited device RCD;
and if the query mode is recursive query and the resource information comprises the resource link of the RCD, processing the th resource query request message by adopting a preset processing mechanism.
2. The method according to claim 1, wherein the processing the th resource query request message by using a preset processing mechanism comprises:
according to the resource information, response message is obtained;
and sending the th response message to a query end.
3. The method of claim 2, wherein the obtaining an th response message according to the resource information comprises:
changing the query mode into a link query;
acquiring the resource link of the RCD according to the resource information by adopting the link query mode;
and carrying the resource link of the RCD in the th response message.
4. The method according to claim 3, wherein the th response message is a redirect message, and the redirect message is used to instruct the querying end to obtain the required resources from the RCD.
5. The method of claim 2, wherein the obtaining an th response message according to the resource information comprises:
determining a target RCD according to the resource information;
sending a second resource query request message to the target RCD; the second resource query request message is used for indicating the target RCD to query the resources required by the query terminal;
receiving a second response message sent by the target RCD; the second response message comprises resources required by the query end;
generating th response message according to the second response message.
6. The method of claim 5, wherein if there are a plurality of said target RCDs, said generating said th reply message according to said second reply message comprises:
and generating th response messages according to the second response messages sent by the target RCDs.
7. The method according to claim 1, wherein the processing the th resource query request message by using a preset processing mechanism comprises:
discarding the th resource query request message.
8. The method according to claim 1, wherein if the query manner is a recursive query and the resource information includes issued resource information of the RD, the resource meeting the query condition is obtained in the recursive query manner.
9. The method of claims 1-7, further comprising:
receiving a resource release request sent by an RCD of a resource to be released; the resource publishing request comprises the equipment identification and attribute information of the RCD of the resource to be published;
authenticating the RCD of the resource to be issued according to the resource issuing request;
and if the authentication is passed, storing the release resource information of the RCD of the resource to be released into the resource file according to the resource release request.
10, kinds of resource inquiry processing device, characterized in that, the device includes:
a th receiving module, configured to receive th resource query request message, where the th resource query request message includes a query mode and a query condition;
the acquisition module is used for inquiring the resource file according to the resource inquiry request and acquiring the resource information corresponding to the resource inquiry request; the resource file comprises release resource information of the agent device RD and release resource information of the resource-limited device RCD;
and the processing module is used for processing the th resource query request message by adopting a preset processing mechanism if the query mode is recursive query and the resource information comprises the resource link of the RCD.
Computer device of , comprising a memory and a processor, the memory storing a computer program, wherein the processor when executing the computer program is configured to carry out the steps of the method of any of claims 1 to 9 as claimed in .
12, computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of any of claims 1 to 9, wherein represents a set of instructions for carrying out the method.
CN201880037186.4A 2018-11-08 2018-11-08 Resource query processing method, device, computer equipment and storage medium Active CN110741361B (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2018/114601 WO2020093318A1 (en) 2018-11-08 2018-11-08 Resource query processing method and apparatus, and computer device and storage medium

Publications (2)

Publication Number Publication Date
CN110741361A true CN110741361A (en) 2020-01-31
CN110741361B CN110741361B (en) 2024-02-06

Family

ID=69236616

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201880037186.4A Active CN110741361B (en) 2018-11-08 2018-11-08 Resource query processing method, device, computer equipment and storage medium

Country Status (2)

Country Link
CN (1) CN110741361B (en)
WO (1) WO2020093318A1 (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150043428A1 (en) * 2012-02-16 2015-02-12 Koninklijke Philips N.V. Method for managing a proxy table in a wireless network using proxy devices
WO2016082274A1 (en) * 2014-11-27 2016-06-02 中国科学院计算机网络信息中心 Dane extended query method and system supporting carrying of service address information
CN106134159A (en) * 2014-03-11 2016-11-16 康维达无线有限责任公司 Strengthen distributive resources list
CN108664613A (en) * 2018-05-11 2018-10-16 中国平安人寿保险股份有限公司 Data query method, apparatus, computer equipment and storage medium

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102694849B (en) * 2012-05-14 2015-07-08 中国科学院计算机网络信息中心 IOT (Internet of Things) resource information acquiring method, terminal equipment and system
CN103561083B (en) * 2013-10-31 2017-01-18 广州视源电子科技股份有限公司 Data processing method for Internet of things
WO2015158613A1 (en) * 2014-04-15 2015-10-22 Koninklijke Philips N.V. Method and apparatus for controlling handshake in a packet transmission network

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150043428A1 (en) * 2012-02-16 2015-02-12 Koninklijke Philips N.V. Method for managing a proxy table in a wireless network using proxy devices
CN106134159A (en) * 2014-03-11 2016-11-16 康维达无线有限责任公司 Strengthen distributive resources list
WO2016082274A1 (en) * 2014-11-27 2016-06-02 中国科学院计算机网络信息中心 Dane extended query method and system supporting carrying of service address information
CN108664613A (en) * 2018-05-11 2018-10-16 中国平安人寿保险股份有限公司 Data query method, apparatus, computer equipment and storage medium

Also Published As

Publication number Publication date
CN110741361B (en) 2024-02-06
WO2020093318A1 (en) 2020-05-14

Similar Documents

Publication Publication Date Title
US11750486B2 (en) Device state management
US11122023B2 (en) Device communication environment
US10547710B2 (en) Device gateway
CN105471686B (en) Terminal control method, device and system
US9973593B2 (en) Device gateway
US10637794B2 (en) Resource subscription method, resource subscription apparatus, and resource subscription system
CN113099440A (en) Network configuration method, device, equipment and system
CN107094102B (en) Information transmission method and equipment
CN112751699A (en) OTA upgrade and upgrade management method, device, network and storage medium
US20150358428A1 (en) Information processing system, information processing method, information processing apparatus, and control methods and control programs thereof
JP2022513769A (en) How to process subscription messages, devices, computer devices and storage media
WO2020177020A1 (en) Internet of things device discovery method, apparatus, and terminal device
CN113132967A (en) Fusion networking method, device, system and computer readable storage medium
TW201740759A (en) Resource allocation method, equipment and system
CN108199933B (en) Household appliance operation control method, system, router and computer readable storage medium
CN110875945B (en) Method, apparatus and medium for task processing on a generic service entity
EP3148133B1 (en) Load control method and apparatus for notification messages
US11916970B2 (en) Security information exchange between a client and a server
US9712993B2 (en) System and method of trigger service
CN110741361A (en) Resource query processing method and device, computer equipment and storage medium
CN113596105B (en) Content acquisition method, edge node and computer readable storage medium
CN111970358B (en) Decentralized cloud computing platform, service deployment method and service access method and service deployment and service access assembly
CN113794610A (en) Gateway communication method, device, equipment and storage medium
CN104486252A (en) Method and device for thin clients to have access to standard clients
KR101760630B1 (en) Method and apparatus for processing interactions between devices

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant