CN109257276B - Efficient named data network implementation method - Google Patents

Efficient named data network implementation method Download PDF

Info

Publication number
CN109257276B
CN109257276B CN201811075184.2A CN201811075184A CN109257276B CN 109257276 B CN109257276 B CN 109257276B CN 201811075184 A CN201811075184 A CN 201811075184A CN 109257276 B CN109257276 B CN 109257276B
Authority
CN
China
Prior art keywords
interface
message
name
router
table entry
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.)
Active
Application number
CN201811075184.2A
Other languages
Chinese (zh)
Other versions
CN109257276A (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.)
Changshu Institute of Technology
Original Assignee
Changshu Institute of Technology
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 Changshu Institute of Technology filed Critical Changshu Institute of Technology
Priority to CN201811075184.2A priority Critical patent/CN109257276B/en
Publication of CN109257276A publication Critical patent/CN109257276A/en
Application granted granted Critical
Publication of CN109257276B publication Critical patent/CN109257276B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/02Topology update or discovery
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/14Routing performance; Theoretical aspects

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention provides a high-efficiency named data network implementation method, wherein the network consists of a controller, more than two routers and more than two devices; the controller is provided with more than two wired interfaces, and each wired interface is connected with one router; the device can rapidly acquire data through the implementation method of the invention, thereby greatly reducing data communication delay and improving data communication quality. The invention can be applied to various fields such as traffic road condition detection and control, agricultural engineering and the like, and has wide application prospect.

Description

Efficient named data network implementation method
Technical Field
The invention relates to an implementation method, in particular to an efficient named data network implementation method.
Background
Communication between devices in a named data network is achieved through forwarding and routing by intermediate devices, and therefore, one of the key technologies to be solved for implementing a named data network is to reduce data transmission delay so as to enable a user to quickly obtain network services. With the development of network technology, named data networks will become a mode for providing services for future networks.
At present, the implementation mode of the named data network is realized through broadcasting, so that both delay and cost are large, and the network service performance is reduced. Therefore, how to reduce the delay and cost of providing services by a named data network has become a hot issue of research in recent years.
Disclosure of Invention
The purpose of the invention is as follows: the invention aims to solve the technical problem of providing an efficient named data network implementation method aiming at the defects of the prior art.
The technical scheme is as follows: the invention discloses a high-efficiency named data network implementation method, wherein the network consists of a controller, more than two routers and more than two devices; the controller is provided with more than two wired interfaces, and each wired interface is connected with one router; the router is provided with more than two upstream wired interfaces, more than two downstream wired interfaces and more than two downstream wireless interfaces, each upstream wired interface is connected with a controller or the router, the downstream wired interface of the router is connected with a router or equipment, and the downstream wireless interface of the router is connected with the equipment; configuring a wired interface or a wireless interface for a device, wherein the interface is connected with a router which is called an associated router of the device;
each wired interface or wireless interface is uniquely identified by an interface ID, which is preconfigured, e.g., 1; the interface with the interface ID of i is abbreviated as interface i;
one type of data is uniquely identified by a name, such as: /TVplay/Video 1; a message is composed of a name, a message type, an interface ID set and a load; the message type values are as follows:
Figure BDA0001800594420000011
Figure BDA0001800594420000021
each router stores a controller table, the controller table at most comprises a controller table entry, and the controller table entry comprises an interface ID set and a life cycle domain; the controller periodically executes the following operations to maintain the controller table:
step 101: starting;
step 102: the controller constructs a release message, the name of the release message is null, the message type value is 1, the interface ID set is null, and the load is null; the controller sends the publication message from each interface;
step 103: after receiving the publish message from the upstream interface u1, the router adds the upstream interface u1 to the publish message interface ID set and uses the publish message as the last element; the router checks the controller table, if a controller table entry exists and the number of elements of the interface ID set domain of the controller table entry is smaller than that of the interface ID set of the issued message, step 110 is executed, otherwise step 104 is executed;
step 104: the router receiving the publish message from the upstream interface u1 checks the controller table, if there is a controller entry and the interface ID set field of the controller entry is equal to the interface ID set of the publish message, execute step 105, otherwise execute step 106;
step 105: the router receiving the distribution message from the upstream interface u1 sets the life cycle of the controller table entry in the control table to the maximum value, forwards the distribution message from each downstream interface, and executes step 103;
step 106: the router receiving the publish message from the upstream interface u1 checks the controller table, if there is a controller table entry and the number of elements in the interface ID set field of the controller table entry is equal to the number of elements in the interface ID set of the publish message, execute step 110, otherwise execute step 107;
step 107: the router receiving the publish message from the upstream interface u1 looks at the controller table, if there is one controller table entry, then step 108 is executed, otherwise step 109 is executed;
step 108: the router receiving the publish message from the upstream interface u1 deletes the controller entry in the control table;
step 109: the router receiving the distribution message from the upstream interface u1 creates a controller table entry, the interface ID set of the controller table entry is equal to the interface ID set of the distribution message, the life cycle is set to the maximum value, and step 103 is executed;
step 110: finishing;
if the router detects that the life cycle of the controller table entry is expired, the controller table entry is deleted.
The controller establishes an optimal routing path to each router through the process, and the process ensures that the path from the controller to each router is shortest through the number of elements of the interface ID set, thereby reducing the communication cost and delay between the routers and the controller.
In the method, a router or a controller maintains a forwarding table, and each forwarding table item comprises a name domain, an interface ID (identity) set domain, a timer set domain and a life cycle domain;
each router maintains a provider table, one provider table entry comprising a name, an interface, and a lifecycle domain;
after the device D1 has generated the data C1 or the change of the router associated with the device D1, on the condition that the router associated with the device D1 is the router R1 and the data C1 is uniquely identified by the name N1, the device D1 performs the following operations:
step 201: starting;
step 202: the device D1 sends a registration message, the name of which is name N1, the interface ID set is null, the message type value is 2, and the load is null;
step 203: the router R1 checks the provider table after receiving the registration message from the downstream interface f1, if there is a provider table entry, the name field value of the provider table entry is N1, and the interface ID is f1, then step 204 is executed, otherwise step 205 is executed;
step 204: after receiving the registration message from the downstream interface f1, the router R1 selects a provider table entry, the name field value of which is N1, the interface ID is f1, sets the lifetime of the provider table entry to the maximum value, for example, 100ms, and then executes step 206;
step 205: after receiving the registration message from the downstream interface f1, the router R1 creates a provider table entry, the name domain value of which is N1, the interface ID is f1, and the lifetime is set to the maximum value;
step 206: and (6) ending.
The device establishes the provider table through the process, so that the router can acquire the data provided by the device according to the name field value in the provider table entry and realize the correct forwarding of the data request according to the interface field value in the provider table entry, thereby realizing the data communication quickly.
In the method of the present invention, the router R1 periodically performs the following operations to maintain the forwarding table:
step 301: starting;
step 302: the router R1 creates a name set parameter NS1, and the initial value of the name set parameter NS1 is null; router R1 looks at the provider table and for each provider table entry, router R1 performs the following operations: if the name of the provider entry is contained in the name set parameter NS1, no action is performed, otherwise the name field value of the provider entry is added to the name set parameter NS 1;
step 303: for each element in the name set parameter NS1, router R1 performs the following operations: the router R1 checks the controller list item, constructs an update message, the name of the update message is N1, the interface ID set is the interface ID set in the controller list item, the message type value is 3, the load is the interface ID set parameter P1, the initial value of the interface ID set parameter P1 is null, the router R1 selects the interface identified by the last element in the update message interface ID set, deletes the last element from the update message interface ID set, and forwards the update message from the selected interface;
step 304: judging whether the controller receives the update message from the interface f2 or the router receives the update message from the interface f3, if the controller receives the update message, executing the step 306, and if the controller receives the update message, executing the step 305;
step 305: the router adds f3 to the parameter P1 in the update message payload and exists as the last element; if a forwarding table entry exists, the name domain value of the forwarding table entry is equal to the name N1, and the interface ID set is equal to the parameter P1 in the update message load, setting the life cycle of the forwarding table entry to the maximum value; otherwise, creating a forwarding table entry, wherein the name domain value of the forwarding table entry is equal to the name N1, the interface ID set is equal to the parameter P1 in the update message load, and the life cycle is set to be the maximum value; the router selects the interface of the last element identification in the update message interface ID set, deletes the last element from the update message interface ID set, forwards the update message from the selected interface, and executes step 304;
step 306: the controller adds f2 to the parameter P1 in the update message payload and exists as the last element; if a forwarding table entry exists, the name domain value of the forwarding table entry is equal to the name N1, and the interface ID set is equal to the parameter P1 in the update message load, setting the life cycle of the forwarding table entry to the maximum value; otherwise, the controller creates a forwarding table entry, the name domain value of the forwarding table entry is equal to the name N1, the interface ID set is equal to the parameter P1 in the update message load, the timer set is null, and the life cycle is set to the maximum value;
step 307: and (6) ending.
The router establishes the forwarding table through the above process, so that the router can correctly forward the data request message according to the name domain value in the forwarding table entry, and simultaneously selects the optimal routing path through the interface ID set domain value and the timer set domain value, thereby reducing data communication delay and cost.
In the method of the present invention, if the associated router of the device D1 is the router R1, the device D1 periodically updates the provider entry by performing the following operations:
step 401: starting;
step 402: the device D1 sends a beacon message with a name of null, a set of interface IDs of null, a message type value of 4, and a payload of a set of names of all data that the device D1 can provide;
step 403: after receiving the beacon message from the interface z1, the router R1 checks the provider table; for each name N' in the set of names in the beacon message payload, router R1 performs the following operations: the router R1 selects a provider entry with a name field value equal to the name N' and an interface ID equal to z1, sets the lifetime of the provider entry to a maximum value;
step 404: and (6) ending.
The equipment updates the provider table periodically through the process to ensure the correctness and the real-time property of the provider table entry, so that the router can realize the correct forwarding of the data request according to the name field value and the interface field value in the provider table entry, thereby realizing the data communication quickly.
In the method of the present invention, if router R1 detects that the life cycle of provider table entry E1 decays to 0, the following operations are performed to update the forwarding table:
step 501: starting;
step 502: the router R1 checks to see if there are at least two provider entries whose name domain values are equal to the name domain value of the provider entry E1, if so, then step 503 is performed, otherwise step 504 is performed;
step 503: the router R1 deletes the provider entry E1, go to step 508;
step 504: the router R1 selects a controller table entry to construct a deletion message, the name domain value of the deletion message is equal to the name domain value in the provider table entry E1, the interface ID set is equal to the interface ID set of the controller table entry, the message type value is 5, the load is an interface ID set parameter P2, and the initial value of the parameter P2 is null; the router R1 selects the interface identified by the last element in the deletion message interface ID set, deletes the last element from the deletion message interface ID set, forwards the deletion message from the selected interface, and the router R1 deletes the provider table entry E1;
step 505: judging whether the controller receives the deletion message from the interface f4 or the router receives the deletion message from the interface f5, if the controller receives the deletion message, executing the step 507, and if the controller receives the deletion message, executing the step 506;
step 506: the router adds f5 to the parameter P2 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the router, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P2, the router deletes the forwarding table entry; the router selects the interface of the last element identification in the deleted message interface ID set, deletes the last element from the deleted message interface ID set, forwards the deleted message from the selected interface, and executes step 505;
step 507: the controller adds f4 to the parameter P2 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the controller, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P2, the controller deletes the forwarding table entry;
step 508: and (6) ending.
The router updates the forwarding table through the process so as to ensure the correctness and the real-time performance of each forwarding table entry, so that the router can realize the correct forwarding of the data request message according to the name domain value in the forwarding table entry, and simultaneously selects an optimal routing path through the interface ID set domain value and the timer set domain value, thereby reducing the data communication delay and the cost.
In the method of the present invention, under the condition that the associated router of the device D1 is the router R1 and the data C1 is defined by the name N1, if the device D1 deletes the data C1, it performs the following operations to update the forwarding table:
step 601: starting;
step 602: the device D1 sends a delete message, the name of which is name N1, the interface ID set is null, the message type value is 5, and the load is null; the router R1 receives the delete message from the interface z2 and checks whether there are at least two provider table entries whose name field values are equal to the name N1, if so, then performs step 603, otherwise performs step 604;
step 603: router R1 deletes the provider entry with the name field value equal to name N1 and the interface ID equal to z2, go to step 608;
step 604: the router R1 selects a controller table entry, updates the interface ID set of the received deletion message into the interface ID set of the controller table entry, updates the load into an interface ID set parameter P3, and has an initial value of parameter P3 being null; router R1 selecting the interface identified by the last element in the delete message interface ID set, deleting the last element from the delete message interface ID set, forwarding the delete message from the selected interface, router R1 deleting the provider table entry whose name field value equals name N1 and interface ID equals z 2;
step 605: judging whether the controller receives the deletion message from the interface f6 or the router receives the deletion message from the interface f7, if the controller receives the deletion message, executing the step 607, and if the controller receives the deletion message, executing the step 606;
step 606: the router adds f7 to the parameter P3 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the router, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P3, the router deletes the forwarding table entry; the router selects the interface of the last element identification in the deleted message interface ID set, deletes the last element from the deleted message interface ID set, forwards the deleted message from the selected interface, and executes step 605;
step 607: the controller adds f6 to the parameter P3 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the controller, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P3, the controller deletes the forwarding table entry;
step 608: and (6) ending.
The router updates the forwarding table through the process so as to ensure the correctness and the real-time performance of each forwarding table entry, and thus the router can calculate the weight according to the interface ID set domain value and the timer set domain value in the forwarding table entry so as to select the optimal routing path and reduce the data communication delay and cost.
In the method, each router or controller stores a request table, and each request table item comprises a name, an interface ID set and a life cycle; the associated router of device D2 is router R1, data C1 is uniquely identified by name N1; if the router R1 has at least one provider entry with a name domain value equal to the name N1, the device D2 obtains data C1 by:
step 701: starting;
step 702: the device D2 sends a request message, the name of the request message is N1, the message type value is 6, the interface ID set is empty, and the load is empty;
step 703: the router R1 receives the request message from the interface x 1; if there is a request entry, the name of the request entry is equal to the name field value of the request message and the set of interface IDs contains x1, go to step 707, otherwise go to step 704;
step 704: the router R1 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 705 is executed, otherwise step 706 is executed;
step 705: the router R1 selects a request table entry, the name of the request table entry is equal to the name of the request message, adds the interface x1 into the interface ID set of the request table entry, sets the life cycle to the maximum value, and executes step 707;
step 706: the router R1 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set domain value is equal to { x1}, namely, the interface ID set only contains one element x1, and the life cycle is set to the maximum value; router R1 selects a provider entry having a name equal to the name field value in the request message, forwards the request message from the interface identified by the interface ID field value of the provider entry; after receiving the request message, the device sends a response message, wherein the name of the response message is the name in the request message, the message type value is 7, the interface ID set is equal to null, and the load is the response message;
step 707: after receiving the response message, the router R1 selects a request table entry, the name field value of the request table entry is equal to the name field value of the response message; for each element in the interface ID set of the request table entry, router R1 performs the following operations: router R1 selects the interface identified by the element and forwards the response message from that interface;
step 708: the router R1 deletes the request entry whose name field value is equal to the name field value of the received response message;
step 709: after receiving the response message, the device D2 saves the data in the response message load;
step 710: and (6) ending.
The equipment acquires data from the local router through the process, and the process realizes the correct forwarding of the request message through the provider table entry, thereby ensuring the correctness and the real-time performance of data communication and reducing the delay and the cost of the data communication.
In the method of the present invention, in a forwarding table entry, if the number of elements in the interface ID set is equal to n1 and the number of elements in the timer set is equal to n2, the weight w1 of the forwarding table entry is as shown in formula (1):
w1=n1+α×n2 (1)
wherein alpha is an adjusting parameter and is a positive number; for example, 1, the larger the α is, the larger the proportion occupied by the timer set is, the larger the influence on the weight is, and the smaller the influence on the weight by the interface ID set is; the smaller alpha is, the smaller the proportion of the timer set is, the smaller the influence on the weight is, the larger the influence of the interface ID set on the weight is, the general range of alpha is (0,3 ]; if one element in the timer set in a forwarding table entry expires, the element is automatically deleted from the timer set; under the condition that the router associated with the device D2 is the router R1, and the data C1 is uniquely identified by the name N1, if the name domain value of any provider table entry in the router R1 is not equal to the name N1, the device D2 executes the following operation to obtain the data C1:
step 801: starting;
step 802: the device D2 sends a request message, the name of the request message is N1, the message type value is 6, the interface ID set is empty, and the load is empty;
step 803: the router R1 receives the request message from the interface y 1; if router R1 has a request entry with a name equal to the name field value of the request message and the set of interface IDs includes interface y1, go to step 824, otherwise go to step 804;
step 804: the router R1 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then executes step 805, otherwise executes step 806;
step 805: the router R1 selects a request table entry, the name of the request table entry is equal to the name of the request message, adds the interface y1 to the interface ID set field of the request table entry, sets the life cycle to the maximum value, and executes step 824;
step 806: the router R1 creates a request table item, the name of the request table item is equal to the name of the request message, the interface ID set domain value is equal to { y1}, and the life cycle is set to the maximum value; the router R1 updates the interface ID set of the request message to the interface ID set of the own controller table entry, selects the interface identified by the last element in the interface ID set of the request message, deletes the last element from the interface ID set of the request message, and forwards the request message from the selected interface;
step 807: judging whether the controller receives the request message from the interface y2 or the router receives the request message from the interface y3, if the controller receives the request message, executing the step 814, and if the controller receives the request message, executing the step 808;
step 808: the router receives the request message from interface y3, if there is a request table entry, the name of the request table entry is equal to the name of the request message and the interface ID set contains interface y3, then step 824 is executed, otherwise step 809 is executed;
step 809: the router receiving the request message from the interface y3 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 810 is executed, otherwise step 811 is executed;
step 810: the router receiving the request message from interface y3 selects a request table entry whose name is equal to the name of the request message, adds interface y3 to the interface ID set field of the request table entry with the lifetime set to the maximum value, and executes step 824;
step 811: the router receiving the request message from the interface y3 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set domain value is equal to { y3}, and the life cycle is set to the maximum value; if the router has at least one forwarding entry, and the name domain value of the forwarding entry is equal to the name domain value of the request message, performing step 812, otherwise performing step 813;
step 812: the router receiving the request message from interface y3 selects a forwarding table entry with the smallest weight value from the forwarding table entries with the name domain value equal to the name domain value of the request message, adds a timer with an initial value preset, for example, 500ms, to the timer set of the forwarding table entry, updates the interface ID set of the request message to the interface ID set of the forwarding table entry, selects the interface identified by the last element in the interface ID set of the request message, deletes the last element from the interface ID set of the request message, forwards the request message from the selected interface, and performs step 818;
step 813: the router receiving the request message from interface y3 selects the interface identified by the last element in the request message interface ID set, deletes the last element from the request message interface ID set, forwards the request message from the selected interface, and performs step 807;
step 814: the controller receives the request message from interface y2, if there is a request table entry whose name is equal to the name of the request message and the interface ID set contains y2, then step 824 is executed, otherwise step 815 is executed;
step 815: the controller receiving the request message from the interface y2 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 816 is executed, otherwise step 817 is executed;
step 816: the controller receiving the request message from the interface y2 selects a request table entry whose name is equal to the name of the request message, adds y2 to the interface ID set field of the request table entry with the life cycle set to the maximum value, and executes step 824;
step 817: the controller receiving the request message from the interface y2 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set field value is equal to { y2}, and the life cycle is set to the maximum value; selecting a forwarding table entry with the minimum weight value from all forwarding table entries with the name domain value equal to the name domain value of the request message, adding a timer into a timer set of the forwarding table entry, and updating an interface ID set of the request message into an interface ID set of the forwarding table entry; the controller selects an interface identified by the last element in the request message interface ID set, deletes the last element from the request message interface ID set, and forwards the request message from the selected interface;
step 818: the router receives the request message from interface y4, if there is a request table entry whose name is equal to the name of the request message and the interface ID set contains interface y4, then step 824 is executed, otherwise step 819 is executed;
step 819: the router receiving the request message from the interface y4 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 820 is executed, otherwise step 821 is executed;
step 820: the router receiving the request message from interface y4 selects a request table entry whose name is equal to the name of the request message, adds interface y4 to the interface ID set field of the request table entry, sets the lifetime of the request table entry to the maximum value, and executes step 824;
step 821: the router receiving the request message from the interface y4 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set domain value is equal to { y4}, and the life cycle is set to the maximum value; the router checks whether the interface ID set of the request message is empty, if so, performs step 823, otherwise performs step 822;
step 822: the router receiving the request message from interface y4 selects the interface identified by the last element in the request message interface ID set, deletes the last element from the request message interface ID set, forwards the request message from the selected interface, and performs step 818;
step 823: the router receiving the request message from interface y4 selects a provider entry having a name equal to the name field value in the request message, forwards the request message from the interface identified by the interface ID field value of the provider entry; after receiving the request message, the device sends a response message, wherein the name of the response message is the name in the request message, the message type value is 7, the interface ID set is equal to null, and the load is response data;
step 824: if the device receives a response message, then step 827 is performed, otherwise step 825 is performed;
step 825: after receiving the response message, the router or the controller selects a request table entry, wherein the name domain value of the request table entry is equal to the name domain value of the response message; for each element in the interface ID set of the request table entry, the router or controller performs the following: selecting the interface identified by the element and forwarding a response message from the interface;
step 826: the router or the controller that received the response message deletes the request entry whose name field value is equal to the name field value of the received response message, and performs step 824;
step 827: after receiving the response message, the equipment stores the data in the response message load;
step 828: and (6) ending.
The equipment obtains data from the remote equipment through the process, and the process calculates the weight through the interface ID set domain value and the timer set domain value in the forwarding table entry so as to select the optimal routing path, thereby greatly reducing the data communication delay and cost.
Has the advantages that: the invention provides an efficient named data network implementation method, and equipment can rapidly acquire data through the implementation method, thereby greatly reducing data communication delay and improving data communication quality. The invention can be applied to various fields such as traffic road condition detection and control, agricultural engineering and the like, and has wide application prospect.
Drawings
The foregoing and/or other advantages of the invention will become further apparent from the following detailed description of the invention when taken in conjunction with the accompanying drawings.
Fig. 1 is a schematic representation of a maintenance controller according to the present invention.
Fig. 2 is a schematic diagram of a registration process according to the present invention.
Fig. 3 is a schematic flow chart of maintaining a forwarding table according to the present invention.
FIG. 4 is a flow chart of an update provider table according to the present invention.
Fig. 5 is a schematic flow chart of deleting a forwarding table according to the present invention.
Fig. 6 is a schematic diagram illustrating a process of updating a forwarding table according to the present invention.
Fig. 7 is a schematic diagram of a local data communication process according to the present invention.
Fig. 8 is a schematic diagram of a remote data communication process according to the present invention.
The specific implementation mode is as follows:
the invention provides an efficient named data network implementation method, and equipment can rapidly acquire data through the implementation method, thereby greatly reducing data communication delay and improving data communication quality. The invention can be applied to various fields such as traffic road condition detection and control, agricultural engineering and the like, and has wide application prospect.
Fig. 1 is a schematic representation of a maintenance controller according to the present invention. The network is composed of a controller, more than two routers and more than two devices; the controller is provided with more than two wired interfaces, and each wired interface is connected with one router; the router is provided with more than two upstream wired interfaces, more than two downstream wired interfaces and more than two downstream wireless interfaces, each upstream wired interface is connected with a controller or the router, the downstream wired interface of the router is connected with a router or equipment, and the downstream wireless interface of the router is connected with the equipment; configuring a wired interface or a wireless interface for a device, wherein the interface is connected with a router which is called an associated router of the device;
each wired interface or wireless interface is uniquely identified by an interface ID, the interface ID is configured in advance, and an interface with the interface ID i is abbreviated as an interface i;
one type of data is uniquely identified by a name; a message is composed of a name, a message type, an interface ID set and a load; the message type values are as follows:
message type name Message type value
Publishing messages 1
Registration message 2
Update messages 3
Beacon message 4
Deleting messages 5
Request message 6
Response message 7
Each router stores a controller table, the controller table at most comprises a controller table entry, and the controller table entry comprises an interface ID set and a life cycle domain; the controller periodically executes the following operations to maintain the controller table:
step 101: starting;
step 102: the controller constructs a release message, the name of the release message is null, the message type value is 1, the interface ID set is null, and the load is null; the controller sends the publication message from each interface;
step 103: after receiving the publish message from the upstream interface u1, the router adds the upstream interface u1 to the publish message interface ID set and uses the publish message as the last element; the router checks the controller table, if a controller table entry exists and the number of elements of the interface ID set domain of the controller table entry is smaller than that of the interface ID set of the issued message, step 110 is executed, otherwise step 104 is executed;
step 104: the router receiving the publish message from the upstream interface u1 checks the controller table, if there is a controller entry and the interface ID set field of the controller entry is equal to the interface ID set of the publish message, execute step 105, otherwise execute step 106;
step 105: the router receiving the distribution message from the upstream interface u1 sets the life cycle of the controller table entry in the control table to the maximum value, forwards the distribution message from each downstream interface, and executes step 103;
step 106: the router receiving the publish message from the upstream interface u1 checks the controller table, if there is a controller table entry and the number of elements in the interface ID set field of the controller table entry is equal to the number of elements in the interface ID set of the publish message, execute step 110, otherwise execute step 107;
step 107: the router receiving the publish message from the upstream interface u1 looks at the controller table, if there is one controller table entry, then step 108 is executed, otherwise step 109 is executed;
step 108: the router receiving the publish message from the upstream interface u1 deletes the controller entry in the control table;
step 109: the router receiving the distribution message from the upstream interface u1 creates a controller table entry, the interface ID set of the controller table entry is equal to the interface ID set of the distribution message, the life cycle is set to the maximum value, and step 103 is executed;
step 110: finishing;
if the router detects that the life cycle of the controller table entry is expired, the controller table entry is deleted.
Fig. 2 is a schematic diagram of a registration process according to the present invention. A router or a controller maintains a forwarding table, and each forwarding table item comprises a name domain, an interface ID set domain, a timer set domain and a life cycle domain;
each router maintains a provider table, one provider table entry comprising a name, an interface, and a lifecycle domain;
after the device D1 has generated the data C1 or the change of the router associated with the device D1, on the condition that the router associated with the device D1 is the router R1 and the data C1 is uniquely identified by the name N1, the device D1 performs the following operations:
step 201: starting;
step 202: the device D1 sends a registration message, the name of which is name N1, the interface ID set is null, the message type value is 2, and the load is null;
step 203: the router R1 checks the provider table after receiving the registration message from the downstream interface f1, if there is a provider table entry, the name field value of the provider table entry is N1, and the interface ID is f1, then step 204 is executed, otherwise step 205 is executed;
step 204: after receiving the registration message from the downstream interface f1, the router R1 selects a provider table entry, the name field value of which is N1, the interface ID is f1, sets the lifetime of the provider table entry to the maximum value, and executes step 206;
step 205: after receiving the registration message from the downstream interface f1, the router R1 creates a provider table entry, the name domain value of which is N1, the interface ID is f1, and the lifetime is set to the maximum value;
step 206: and (6) ending.
Fig. 3 is a schematic flow chart of maintaining a forwarding table according to the present invention. The router R1 periodically performs the following operations to maintain the forwarding table:
step 301: starting;
step 302: the router R1 creates a name set parameter NS1, and the initial value of the name set parameter NS1 is null; router R1 looks at the provider table and for each provider table entry, router R1 performs the following operations: if the name of the provider entry is contained in the name set parameter NS1, no action is performed, otherwise the name field value of the provider entry is added to the name set parameter NS 1;
step 303: for each element in the name set parameter NS1, router R1 performs the following operations: the router R1 checks the controller list item, constructs an update message, the name of the update message is N1, the interface ID set is the interface ID set in the controller list item, the message type value is 3, the load is the interface ID set parameter P1, the initial value of the interface ID set parameter P1 is null, the router R1 selects the interface identified by the last element in the update message interface ID set, deletes the last element from the update message interface ID set, and forwards the update message from the selected interface;
step 304: judging whether the controller receives the update message from the interface f2 or the router receives the update message from the interface f3, if the controller receives the update message, executing the step 306, and if the controller receives the update message, executing the step 305;
step 305: the router adds f3 to the parameter P1 in the update message payload and exists as the last element; if a forwarding table entry exists, the name domain value of the forwarding table entry is equal to the name N1, and the interface ID set is equal to the parameter P1 in the update message load, setting the life cycle of the forwarding table entry to the maximum value; otherwise, creating a forwarding table entry, wherein the name domain value of the forwarding table entry is equal to the name N1, the interface ID set is equal to the parameter P1 in the update message load, and the life cycle is set to be the maximum value; the router selects the interface of the last element identification in the update message interface ID set, deletes the last element from the update message interface ID set, forwards the update message from the selected interface, and executes step 304;
step 306: the controller adds f2 to the parameter P1 in the update message payload and exists as the last element; if a forwarding table entry exists, the name domain value of the forwarding table entry is equal to the name N1, and the interface ID set is equal to the parameter P1 in the update message load, setting the life cycle of the forwarding table entry to the maximum value; otherwise, the controller creates a forwarding table entry, the name domain value of the forwarding table entry is equal to the name N1, the interface ID set is equal to the parameter P1 in the update message load, the timer set is null, and the life cycle is set to the maximum value;
step 307: and (6) ending.
FIG. 4 is a flow chart of an update provider table according to the present invention. If the associated router of device D1 is router R1, device D1 periodically updates the provider table entry by performing the following operations:
step 401: starting;
step 402: the device D1 sends a beacon message with a name of null, a set of interface IDs of null, a message type value of 4, and a payload of a set of names of all data that the device D1 can provide;
step 403: after receiving the beacon message from the interface z1, the router R1 checks the provider table; for each name N' in the set of names in the beacon message payload, router R1 performs the following operations: the router R1 selects a provider entry with a name field value equal to the name N' and an interface ID equal to z1, sets the lifetime of the provider entry to a maximum value;
step 404: and (6) ending.
Fig. 5 is a schematic flow chart of deleting a forwarding table according to the present invention. If router R1 detects that the life cycle of provider entry E1 decays to 0, then the following operations are performed to update the forwarding table:
step 501: starting;
step 502: the router R1 checks to see if there are at least two provider entries whose name domain values are equal to the name domain value of the provider entry E1, if so, then step 503 is performed, otherwise step 504 is performed;
step 503: the router R1 deletes the provider entry E1, go to step 508;
step 504: the router R1 selects a controller table entry to construct a deletion message, the name domain value of the deletion message is equal to the name domain value in the provider table entry E1, the interface ID set is equal to the interface ID set of the controller table entry, the message type value is 5, the load is an interface ID set parameter P2, and the initial value of the parameter P2 is null; the router R1 selects the interface identified by the last element in the deletion message interface ID set, deletes the last element from the deletion message interface ID set, forwards the deletion message from the selected interface, and the router R1 deletes the provider table entry E1;
step 505: judging whether the controller receives the deletion message from the interface f4 or the router receives the deletion message from the interface f5, if the controller receives the deletion message, executing the step 507, and if the controller receives the deletion message, executing the step 506;
step 506: the router adds f5 to the parameter P2 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the router, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P2, the router deletes the forwarding table entry; the router selects the interface of the last element identification in the deleted message interface ID set, deletes the last element from the deleted message interface ID set, forwards the deleted message from the selected interface, and executes step 505;
step 507: the controller adds f4 to the parameter P2 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the controller, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P2, the controller deletes the forwarding table entry;
step 508: and (6) ending.
Fig. 6 is a schematic diagram illustrating a process of updating a forwarding table according to the present invention. On the condition that the associated router of the device D1 is the router R1 and the data C1 is defined by the name N1, if the device D1 deletes the data C1, it updates the forwarding table by performing the following operations:
step 601: starting;
step 602: the device D1 sends a delete message, the name of which is name N1, the interface ID set is null, the message type value is 5, and the load is null; the router R1 receives the delete message from the interface z2 and checks whether there are at least two provider table entries whose name field values are equal to the name N1, if so, then performs step 603, otherwise performs step 604;
step 603: router R1 deletes the provider entry with the name field value equal to name N1 and the interface ID equal to z2, go to step 608;
step 604: the router R1 selects a controller table entry, updates the interface ID set of the received deletion message into the interface ID set of the controller table entry, updates the load into an interface ID set parameter P3, and has an initial value of parameter P3 being null; router R1 selecting the interface identified by the last element in the delete message interface ID set, deleting the last element from the delete message interface ID set, forwarding the delete message from the selected interface, router R1 deleting the provider table entry whose name field value equals name N1 and interface ID equals z 2;
step 605: judging whether the controller receives the deletion message from the interface f6 or the router receives the deletion message from the interface f7, if the controller receives the deletion message, executing the step 607, and if the controller receives the deletion message, executing the step 606;
step 606: the router adds f7 to the parameter P3 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the router, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P3, the router deletes the forwarding table entry; the router selects the interface of the last element identification in the deleted message interface ID set, deletes the last element from the deleted message interface ID set, forwards the deleted message from the selected interface, and executes step 605;
step 607: the controller adds f6 to the parameter P3 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the controller, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P3, the controller deletes the forwarding table entry;
step 608: and (6) ending.
Fig. 7 is a schematic diagram of a local data communication process according to the present invention. Each router or controller stores a request table, and each request table item comprises a name, an interface ID set and a life cycle; the associated router of device D2 is router R1, data C1 is uniquely identified by name N1; if the router R1 has at least one provider entry with a name domain value equal to the name N1, the device D2 obtains data C1 by:
step 701: starting;
step 702: the device D2 sends a request message, the name of the request message is N1, the message type value is 6, the interface ID set is empty, and the load is empty;
step 703: the router R1 receives the request message from the interface x 1; if there is a request entry, the name of the request entry is equal to the name field value of the request message and the set of interface IDs contains x1, go to step 707, otherwise go to step 704;
step 704: the router R1 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 705 is executed, otherwise step 706 is executed;
step 705: the router R1 selects a request table entry, the name of the request table entry is equal to the name of the request message, adds the interface x1 into the interface ID set of the request table entry, sets the life cycle to the maximum value, and executes step 707;
step 706: the router R1 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set domain value is equal to { x1}, namely, the interface ID set only contains one element x1, and the life cycle is set to the maximum value; router R1 selects a provider entry having a name equal to the name field value in the request message, forwards the request message from the interface identified by the interface ID field value of the provider entry; after receiving the request message, the device sends a response message, wherein the name of the response message is the name in the request message, the message type value is 7, the interface ID set is equal to null, and the load is the response message;
step 707: after receiving the response message, the router R1 selects a request table entry, the name field value of the request table entry is equal to the name field value of the response message; for each element in the interface ID set of the request table entry, router R1 performs the following operations: router R1 selects the interface identified by the element and forwards the response message from that interface;
step 708: the router R1 deletes the request entry whose name field value is equal to the name field value of the received response message;
step 709: after receiving the response message, the device D2 saves the data in the response message load;
step 710: and (6) ending.
Fig. 8 is a schematic diagram of a remote data communication process according to the present invention. In a forwarding table entry, if the number of elements in the interface ID set is equal to n1 and the number of elements in the timer set is equal to n2, the weight w1 of the forwarding table entry is as shown in formula (1):
w1=n1+α×n2 (1)
wherein alpha is an adjusting parameter and is a positive number; if one element in a timer set in one forwarding table item is expired, automatically deleting the element from the timer set; under the condition that the associated router of the device D2 is the router R1 and the data C1 is uniquely identified by the name N1, if the name field value of any provider entry in the router R1 is not equal to the name N1, the device D2 performs the following operations to obtain the data C1:
step 801: starting;
step 802: the device D2 sends a request message, the name of the request message is N1, the message type value is 6, the interface ID set is empty, and the load is empty;
step 803: the router R1 receives the request message from the interface y 1; if router R1 has a request entry with a name equal to the name field value of the request message and the set of interface IDs includes interface y1, go to step 824, otherwise go to step 804;
step 804: the router R1 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then executes step 805, otherwise executes step 806;
step 805: the router R1 selects a request table entry, the name of the request table entry is equal to the name of the request message, adds the interface y1 to the interface ID set field of the request table entry, sets the life cycle to the maximum value, and executes step 824;
step 806: the router R1 creates a request table item, the name of the request table item is equal to the name of the request message, the interface ID set domain value is equal to { y1}, and the life cycle is set to the maximum value; the router R1 updates the interface ID set of the request message to the interface ID set of the own controller table entry, selects the interface identified by the last element in the interface ID set of the request message, deletes the last element from the interface ID set of the request message, and forwards the request message from the selected interface;
step 807: judging whether the controller receives the request message from the interface y2 or the router receives the request message from the interface y3, if the controller receives the request message, executing the step 814, and if the controller receives the request message, executing the step 808;
step 808: the router receives the request message from interface y3, if there is a request table entry, the name of the request table entry is equal to the name of the request message and the interface ID set contains interface y3, then step 824 is executed, otherwise step 809 is executed;
step 809: the router receiving the request message from the interface y3 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 810 is executed, otherwise step 811 is executed;
step 810: the router receiving the request message from interface y3 selects a request table entry whose name is equal to the name of the request message, adds interface y3 to the interface ID set field of the request table entry with the lifetime set to the maximum value, and executes step 824;
step 811: the router receiving the request message from the interface y3 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set domain value is equal to { y3}, and the life cycle is set to the maximum value; if the router has at least one forwarding entry, and the name domain value of the forwarding entry is equal to the name domain value of the request message, performing step 812, otherwise performing step 813;
step 812: the router receiving the request message from interface y3 selects a forwarding table entry with the smallest weight value from the forwarding table entries with the name domain value equal to the name domain value of the request message, adds a timer with a preset initial value to the timer set of the forwarding table entry, updates the interface ID set of the request message to the interface ID set of the forwarding table entry, selects the interface identified by the last element in the interface ID set of the request message, deletes the last element from the interface ID set of the request message, forwards the request message from the selected interface, and executes step 818;
step 813: the router receiving the request message from interface y3 selects the interface identified by the last element in the request message interface ID set, deletes the last element from the request message interface ID set, forwards the request message from the selected interface, and performs step 807;
step 814: the controller receives the request message from interface y2, if there is a request table entry whose name is equal to the name of the request message and the interface ID set contains y2, then step 824 is executed, otherwise step 815 is executed;
step 815: the controller receiving the request message from the interface y2 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 816 is executed, otherwise step 817 is executed;
step 816: the controller receiving the request message from the interface y2 selects a request table entry whose name is equal to the name of the request message, adds y2 to the interface ID set field of the request table entry with the life cycle set to the maximum value, and executes step 824;
step 817: the controller receiving the request message from the interface y2 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set field value is equal to { y2}, and the life cycle is set to the maximum value; selecting a forwarding table entry with the minimum weight value from all forwarding table entries with the name domain value equal to the name domain value of the request message, adding a timer into a timer set of the forwarding table entry, and updating an interface ID set of the request message into an interface ID set of the forwarding table entry; the controller selects an interface identified by the last element in the request message interface ID set, deletes the last element from the request message interface ID set, and forwards the request message from the selected interface;
step 818: the router receives the request message from interface y4, if there is a request table entry whose name is equal to the name of the request message and the interface ID set contains interface y4, then step 824 is executed, otherwise step 819 is executed;
step 819: the router receiving the request message from the interface y4 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 820 is executed, otherwise step 821 is executed;
step 820: the router receiving the request message from interface y4 selects a request table entry whose name is equal to the name of the request message, adds interface y4 to the interface ID set field of the request table entry, sets the lifetime of the request table entry to the maximum value, and executes step 824;
step 821: the router receiving the request message from the interface y4 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set domain value is equal to { y4}, and the life cycle is set to the maximum value; the router checks whether the interface ID set of the request message is empty, if so, performs step 823, otherwise performs step 822;
step 822: the router receiving the request message from interface y4 selects the interface identified by the last element in the request message interface ID set, deletes the last element from the request message interface ID set, forwards the request message from the selected interface, and performs step 818;
step 823: the router receiving the request message from interface y4 selects a provider entry having a name equal to the name field value in the request message, forwards the request message from the interface identified by the interface ID field value of the provider entry; after receiving the request message, the device sends a response message, wherein the name of the response message is the name in the request message, the message type value is 7, the interface ID set is equal to null, and the load is response data;
step 824: if the device receives a response message, then step 827 is performed, otherwise step 825 is performed;
step 825: after receiving the response message, the router or the controller selects a request table entry, wherein the name domain value of the request table entry is equal to the name domain value of the response message; for each element in the interface ID set of the request table entry, the router or controller performs the following: selecting the interface identified by the element and forwarding a response message from the interface;
step 826: the router or the controller that received the response message deletes the request entry whose name field value is equal to the name field value of the received response message, and performs step 824;
step 827: after receiving the response message, the equipment stores the data in the response message load;
step 828: and (6) ending.
Example 1
Based on the simulation parameters in table 1, this embodiment simulates an efficient named data network implementation method in the present invention, and the performance analysis is as follows: when the data transmission amount is increased, the success rate of data communication is reduced, and when the data transmission amount is reduced, the success rate of data communication is increased and reduced, and the average success rate of data communication is 96.7%.
TABLE 1 simulation parameters
Figure BDA0001800594420000211
The present invention provides an efficient method for implementing a named data network, and the method and the way for implementing the technical scheme are many, and the above description is only a preferred embodiment of the present invention, it should be noted that, for those skilled in the art, a plurality of improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be regarded as the protection scope of the present invention. The components not specified in this embodiment can be implemented by the prior art.

Claims (8)

1. An efficient named data network implementation method is characterized in that the network is composed of a controller, more than two routers and more than two devices; the controller is provided with more than two wired interfaces, and each wired interface is connected with one router; the router is provided with more than two upstream wired interfaces, more than two downstream wired interfaces and more than two downstream wireless interfaces, each upstream wired interface is connected with a controller or the router, the downstream wired interface of the router is connected with a router or equipment, and the downstream wireless interface of the router is connected with the equipment; configuring a wired interface or a wireless interface for a device, wherein the interface is connected with a router which is called an associated router of the device;
each wired interface or wireless interface is uniquely identified by an interface ID, the interface ID is configured in advance, and an interface with the interface ID i is abbreviated as an interface i;
one type of data is uniquely identified by a name; a message is composed of a name, a message type, an interface ID set and a load; the message type values are as follows:
message type name Message type value Publishing messages 1 Registration message 2 Update messages 3 Beacon message 4 Deleting messages 5 Request message 6 Response message 7
Each router stores a controller table, the controller table at most comprises a controller table entry, and the controller table entry comprises an interface ID set and a life cycle domain; the controller periodically executes the following operations to maintain the controller table:
step 101: starting;
step 102: the controller constructs a release message, the name of the release message is null, the message type value is 1, the interface ID set is null, and the load is null; the controller sends the publication message from each interface;
step 103: after receiving the publish message from the upstream interface u1, the router adds the upstream interface u1 to the publish message interface ID set and uses the publish message as the last element; the router checks the controller table, if a controller table entry exists and the number of elements of the interface ID set domain of the controller table entry is smaller than that of the interface ID set of the issued message, step 110 is executed, otherwise step 104 is executed;
step 104: the router receiving the publish message from the upstream interface u1 checks the controller table, if there is a controller entry and the interface ID set field of the controller entry is equal to the interface ID set of the publish message, execute step 105, otherwise execute step 106;
step 105: the router receiving the distribution message from the upstream interface u1 sets the life cycle of the controller table entry in the control table to the maximum value, forwards the distribution message from each downstream interface, and executes step 103;
step 106: the router receiving the publish message from the upstream interface u1 checks the controller table, if there is a controller table entry and the number of elements in the interface ID set field of the controller table entry is equal to the number of elements in the interface ID set of the publish message, execute step 110, otherwise execute step 107;
step 107: the router receiving the publish message from the upstream interface u1 looks at the controller table, if there is one controller table entry, then step 108 is executed, otherwise step 109 is executed;
step 108: the router receiving the publish message from the upstream interface u1 deletes the controller entry in the control table;
step 109: the router receiving the distribution message from the upstream interface u1 creates a controller table entry, the interface ID set of the controller table entry is equal to the interface ID set of the distribution message, the life cycle is set to the maximum value, and step 103 is executed;
step 110: finishing;
if the router detects that the life cycle of the controller table entry is expired, the controller table entry is deleted.
2. The method of claim 1, wherein a router or controller maintains a forwarding table, each forwarding table entry comprises a name field, an interface ID set field, a timer set field, and a lifetime field;
each router maintains a provider table, one provider table entry comprising a name, an interface, and a lifecycle domain;
after the device D1 has generated the data C1 or the change of the router associated with the device D1, on the condition that the router associated with the device D1 is the router R1 and the data C1 is uniquely identified by the name N1, the device D1 performs the following operations:
step 201: starting;
step 202: the device D1 sends a registration message, the name of which is name N1, the interface ID set is null, the message type value is 2, and the load is null;
step 203: the router R1 checks the provider table after receiving the registration message from the downstream interface f1, if there is a provider table entry, the name field value of the provider table entry is N1, and the interface ID is f1, then step 204 is executed, otherwise step 205 is executed;
step 204: after receiving the registration message from the downstream interface f1, the router R1 selects a provider table entry, sets the lifetime of the provider table entry to the maximum value, and executes step 206;
step 205: after receiving the registration message from the downstream interface f1, the router R1 creates a provider table entry, the name domain value of which is N1, the interface ID is f1, and the lifetime is set to the maximum value;
step 206: and (6) ending.
3. The efficient named data networking implementation of claim 2, wherein router R1 periodically maintains forwarding tables by performing the following operations:
step 301: starting;
step 302: the router R1 creates a name set parameter NS1, and the initial value of the name set parameter NS1 is null; router R1 looks at the provider table and for each provider table entry, router R1 performs the following operations: if the name of the provider entry is contained in the name set parameter NS1, no action is performed, otherwise the name field value of the provider entry is added to the name set parameter NS 1;
step 303: for each element in the name set parameter NS1, router R1 performs the following operations: the router R1 checks the controller list item, constructs an update message, the name of the update message is N1, the interface ID set is the interface ID set in the controller list item, the message type value is 3, the load is the interface ID set parameter P1, the initial value of the interface ID set parameter P1 is null, the router R1 selects the interface identified by the last element in the update message interface ID set, deletes the last element from the update message interface ID set, and forwards the update message from the selected interface;
step 304: judging whether the controller receives the update message from the interface f2 or the router receives the update message from the interface f3, if the controller receives the update message, executing the step 306, and if the controller receives the update message, executing the step 305;
step 305: the router adds f3 to the parameter P1 in the update message payload and exists as the last element; if a forwarding table entry exists, the name domain value of the forwarding table entry is equal to the name N1, and the interface ID set is equal to the parameter P1 in the update message load, setting the life cycle of the forwarding table entry to the maximum value; otherwise, creating a forwarding table entry, wherein the name domain value of the forwarding table entry is equal to the name N1, the interface ID set is equal to the parameter P1 in the update message load, and the life cycle is set to be the maximum value; the router selects the interface of the last element identification in the update message interface ID set, deletes the last element from the update message interface ID set, forwards the update message from the selected interface, and executes step 304;
step 306: the controller adds f2 to the parameter P1 in the update message payload and exists as the last element; if a forwarding table entry exists, the name domain value of the forwarding table entry is equal to the name N1, and the interface ID set is equal to the parameter P1 in the update message load, setting the life cycle of the forwarding table entry to the maximum value; otherwise, the controller creates a forwarding table entry, the name domain value of the forwarding table entry is equal to the name N1, the interface ID set is equal to the parameter P1 in the update message load, the timer set is null, and the life cycle is set to the maximum value;
step 307: and (6) ending.
4. The method of claim 3, wherein if the router associated with device D1 is router R1, device D1 updates the provider table entry by periodically:
step 401: starting;
step 402: the device D1 sends a beacon message with a name of null, a set of interface IDs of null, a message type value of 4, and a payload of a set of names of all data that the device D1 can provide;
step 403: after receiving the beacon message from the interface z1, the router R1 checks the provider table; for each name N' in the set of names in the beacon message payload, router R1 performs the following operations: the router R1 selects a provider entry with a name field value equal to the name N' and an interface ID equal to z1, sets the lifetime of the provider entry to a maximum value;
step 404: and (6) ending.
5. The efficient named data networking implementation of claim 3, wherein if router R1 detects that the life cycle of provider table entry E1 decays to 0, then it updates the forwarding table by:
step 501: starting;
step 502: the router R1 checks to see if there are at least two provider entries whose name domain values are equal to the name domain value of the provider entry E1, if so, then step 503 is performed, otherwise step 504 is performed;
step 503: the router R1 deletes the provider entry E1, go to step 508;
step 504: the router R1 selects a controller table entry to construct a deletion message, the name domain value of the deletion message is equal to the name domain value in the provider table entry E1, the interface ID set is equal to the interface ID set of the controller table entry, the message type value is 5, the load is an interface ID set parameter P2, and the initial value of the parameter P2 is null; the router R1 selects the interface identified by the last element in the deletion message interface ID set, deletes the last element from the deletion message interface ID set, forwards the deletion message from the selected interface, and the router R1 deletes the provider table entry E1;
step 505: judging whether the controller receives the deletion message from the interface f4 or the router receives the deletion message from the interface f5, if the controller receives the deletion message, executing the step 507, and if the controller receives the deletion message, executing the step 506;
step 506: the router adds f5 to the parameter P2 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the router, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P2, the router deletes the forwarding table entry; the router selects the interface of the last element identification in the deleted message interface ID set, deletes the last element from the deleted message interface ID set, forwards the deleted message from the selected interface, and executes step 505;
step 507: the controller adds f4 to the parameter P2 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the controller, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P2, the controller deletes the forwarding table entry;
step 508: and (6) ending.
6. The method as claimed in claim 3, wherein if device D1 deletes data C1, it updates the forwarding table according to the following operation, under the condition that the associated router of device D1 is router R1 and data C1 is defined by name N1:
step 601: starting;
step 602: the device D1 sends a delete message, the name of which is name N1, the interface ID set is null, the message type value is 5, and the load is null; the router R1 receives the delete message from the interface z2 and checks whether there are at least two provider table entries whose name field values are equal to the name N1, if so, then performs step 603, otherwise performs step 604;
step 603: router R1 deletes the provider entry with the name field value equal to name N1 and the interface ID equal to z2, go to step 608;
step 604: the router R1 selects a controller table entry, updates the interface ID set of the received deletion message into the interface ID set of the controller table entry, updates the load into an interface ID set parameter P3, and has an initial value of parameter P3 being null; router R1 selecting the interface identified by the last element in the delete message interface ID set, deleting the last element from the delete message interface ID set, forwarding the delete message from the selected interface, router R1 deleting the provider table entry whose name field value equals name N1 and interface ID equals z 2;
step 605: judging whether the controller receives the deletion message from the interface f6 or the router receives the deletion message from the interface f7, if the controller receives the deletion message, executing the step 607, and if the controller receives the deletion message, executing the step 606;
step 606: the router adds f7 to the parameter P3 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the router, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P3, the router deletes the forwarding table entry; the router selects the interface of the last element identification in the deleted message interface ID set, deletes the last element from the deleted message interface ID set, forwards the deleted message from the selected interface, and executes step 605;
step 607: the controller adds f6 to the parameter P3 in the delete message payload as the last element; if a forwarding table entry exists in the forwarding table of the controller, the name of the forwarding table entry is equal to the name of the deletion message, and the interface ID set is equal to the parameter P3, the controller deletes the forwarding table entry;
step 608: and (6) ending.
7. An efficient named data networking implementation as claimed in claim 3 wherein each router or controller maintains a request table, each request table entry containing a name, a set of interface IDs and a lifecycle; the associated router of device D2 is router R1, data C1 is uniquely identified by name N1; if the router R1 has at least one provider entry with a name domain value equal to the name N1, the device D2 obtains data C1 by:
step 701: starting;
step 702: the device D2 sends a request message, the name of the request message is N1, the message type value is 6, the interface ID set is empty, and the load is empty;
step 703: the router R1 receives the request message from the interface x 1; if there is a request entry, the name of the request entry is equal to the name field value of the request message and the set of interface IDs contains x1, go to step 707, otherwise go to step 704;
step 704: the router R1 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 705 is executed, otherwise step 706 is executed;
step 705: the router R1 selects a request table entry, the name of the request table entry is equal to the name of the request message, adds the interface x1 into the interface ID set of the request table entry, sets the life cycle to the maximum value, and executes step 707;
step 706: the router R1 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set domain value is equal to { x1}, namely, the interface ID set only contains one element x1, and the life cycle is set to the maximum value; router R1 selects a provider entry having a name equal to the name field value in the request message, forwards the request message from the interface identified by the interface ID field value of the provider entry; after receiving the request message, the device sends a response message, wherein the name of the response message is the name in the request message, the message type value is 7, the interface ID set is equal to null, and the load is the response message;
step 707: after receiving the response message, the router R1 selects a request table entry, the name field value of the request table entry is equal to the name field value of the response message; for each element in the interface ID set of the request table entry, router R1 performs the following operations: router R1 selects the interface identified by the element and forwards the response message from that interface;
step 708: the router R1 deletes the request entry whose name field value is equal to the name field value of the received response message;
step 709: after receiving the response message, the device D2 saves the data in the response message load;
step 710: and (6) ending.
8. The method as claimed in claim 3, wherein in a forwarding table entry, if the number of elements in the interface ID set is equal to n1 and the number of elements in the timer set is equal to n2, the weight w1 of the forwarding table entry is as shown in formula (1):
w1=n1+α×n2 (1)
wherein alpha is an adjusting parameter and is a positive number; if one element in a timer set in one forwarding table item is expired, automatically deleting the element from the timer set; under the condition that the associated router of the device D2 is the router R1 and the data C1 is uniquely identified by the name N1, if the name field value of any provider entry in the router R1 is not equal to the name N1, the device D2 performs the following operations to obtain the data C1:
step 801: starting;
step 802: the device D2 sends a request message, the name of the request message is N1, the message type value is 6, the interface ID set is empty, and the load is empty;
step 803: the router R1 receives the request message from the interface y 1; if router R1 has a request entry with a name equal to the name field value of the request message and the set of interface IDs includes interface y1, go to step 824, otherwise go to step 804;
step 804: the router R1 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then executes step 805, otherwise executes step 806;
step 805: the router R1 selects a request table entry, adds the interface y1 into the interface ID set domain of the request table entry, sets the life cycle to the maximum value, and executes the step 824;
step 806: the router R1 creates a request table item, the name of the request table item is equal to the name of the request message, the interface ID set domain value is equal to { y1}, and the life cycle is set to the maximum value; the router R1 updates the interface ID set of the request message to the interface ID set of the own controller table entry, selects the interface identified by the last element in the interface ID set of the request message, deletes the last element from the interface ID set of the request message, and forwards the request message from the selected interface;
step 807: judging whether the controller receives the request message from the interface y2 or the router receives the request message from the interface y3, if the controller receives the request message, executing the step 814, and if the controller receives the request message, executing the step 808;
step 808: the router receives the request message from interface y3, if there is a request table entry, the name of the request table entry is equal to the name of the request message and the interface ID set contains interface y3, then step 824 is executed, otherwise step 809 is executed;
step 809: the router receiving the request message from the interface y3 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 810 is executed, otherwise step 811 is executed;
step 810: the router receiving the request message from interface y3 selects a request table entry whose name is equal to the name of the request message, adds interface y3 to the interface ID set field of the request table entry with the lifetime set to the maximum value, and executes step 824;
step 811: the router receiving the request message from the interface y3 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set domain value is equal to { y3}, and the life cycle is set to the maximum value; if the router has at least one forwarding entry, and the name domain value of the forwarding entry is equal to the name domain value of the request message, performing step 812, otherwise performing step 813;
step 812: the router receiving the request message from interface y3 selects a forwarding table entry with the smallest weight value from the forwarding table entries with the name domain value equal to the name domain value of the request message, adds a timer with a preset initial value to the timer set of the forwarding table entry, updates the interface ID set of the request message to the interface ID set of the forwarding table entry, selects the interface identified by the last element in the interface ID set of the request message, deletes the last element from the interface ID set of the request message, forwards the request message from the selected interface, and executes step 818;
step 813: the router receiving the request message from interface y3 selects the interface identified by the last element in the request message interface ID set, deletes the last element from the request message interface ID set, forwards the request message from the selected interface, and performs step 807;
step 814: the controller receives the request message from interface y2, if there is a request table entry whose name is equal to the name of the request message and the interface ID set contains y2, then step 824 is executed, otherwise step 815 is executed;
step 815: the controller receiving the request message from the interface y2 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 816 is executed, otherwise step 817 is executed;
step 816: the controller receiving the request message from the interface y2 selects a request table entry whose name is equal to the name of the request message, adds y2 to the interface ID set field of the request table entry with the life cycle set to the maximum value, and executes step 824;
step 817: the controller receiving the request message from the interface y2 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set field value is equal to { y2}, and the life cycle is set to the maximum value; selecting a forwarding table entry with the minimum weight value from all forwarding table entries with the name domain value equal to the name domain value of the request message, adding a timer into a timer set of the forwarding table entry, and updating an interface ID set of the request message into an interface ID set of the forwarding table entry; the controller selects an interface identified by the last element in the request message interface ID set, deletes the last element from the request message interface ID set, and forwards the request message from the selected interface;
step 818: the router receives the request message from interface y4, if there is a request table entry whose name is equal to the name of the request message and the interface ID set contains interface y4, then step 824 is executed, otherwise step 819 is executed;
step 819: the router receiving the request message from the interface y4 checks the request table, if there is a request table entry whose name is equal to the name of the request message, then step 820 is executed, otherwise step 821 is executed;
step 820: the router receiving the request message from interface y4 selects a request table entry whose name is equal to the name of the request message, adds interface y4 to the interface ID set field of the request table entry, sets the lifetime of the request table entry to the maximum value, and executes step 824;
step 821: the router receiving the request message from the interface y4 creates a request table entry, the name of the request table entry is equal to the name of the request message, the interface ID set domain value is equal to { y4}, and the life cycle is set to the maximum value; the router checks whether the interface ID set of the request message is empty, if so, performs step 823, otherwise performs step 822;
step 822: the router receiving the request message from interface y4 selects the interface identified by the last element in the request message interface ID set, deletes the last element from the request message interface ID set, forwards the request message from the selected interface, and performs step 818;
step 823: the router receiving the request message from interface y4 selects a provider entry having a name equal to the name field value in the request message, forwards the request message from the interface identified by the interface ID field value of the provider entry; after receiving the request message, the device sends a response message, wherein the name of the response message is the name in the request message, the message type value is 7, the interface ID set is equal to null, and the load is response data;
step 824: if the device receives a response message, then step 827 is performed, otherwise step 825 is performed;
step 825: after receiving the response message, the router or the controller selects a request table entry, wherein the name domain value of the request table entry is equal to the name domain value of the response message; for each element in the interface ID set of the request table entry, the router or controller performs the following: selecting the interface identified by the element and forwarding a response message from the interface;
step 826: the router or the controller that received the response message deletes the request entry whose name field value is equal to the name field value of the received response message, and performs step 824;
step 827: after receiving the response message, the equipment stores the data in the response message load;
step 828: and (6) ending.
CN201811075184.2A 2018-09-14 2018-09-14 Efficient named data network implementation method Active CN109257276B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811075184.2A CN109257276B (en) 2018-09-14 2018-09-14 Efficient named data network implementation method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811075184.2A CN109257276B (en) 2018-09-14 2018-09-14 Efficient named data network implementation method

Publications (2)

Publication Number Publication Date
CN109257276A CN109257276A (en) 2019-01-22
CN109257276B true CN109257276B (en) 2020-10-27

Family

ID=65048383

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811075184.2A Active CN109257276B (en) 2018-09-14 2018-09-14 Efficient named data network implementation method

Country Status (1)

Country Link
CN (1) CN109257276B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109768932B (en) * 2019-03-04 2020-12-11 常熟理工学院 Method for implementing named data network

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104104614A (en) * 2014-06-13 2014-10-15 中国科学院计算技术研究所 Software defined network controller system in named data networking and method thereof
CN105763438A (en) * 2016-04-29 2016-07-13 清华大学 Content delivery method based on software defined network and name routing technology
CN106502993A (en) * 2016-11-28 2017-03-15 北京交通大学 The multidimensional name support method of name data network

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10680922B2 (en) * 2015-07-09 2020-06-09 Panasonic Intellectual Property Corporation Of America Communication control apparatus and communication control method

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104104614A (en) * 2014-06-13 2014-10-15 中国科学院计算技术研究所 Software defined network controller system in named data networking and method thereof
CN105763438A (en) * 2016-04-29 2016-07-13 清华大学 Content delivery method based on software defined network and name routing technology
CN106502993A (en) * 2016-11-28 2017-03-15 北京交通大学 The multidimensional name support method of name data network

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
命名数据网络中的一种双模式转发模型;姜一鸣等;《重庆邮电大学学报(自然科学版)》;20180131;全文 *

Also Published As

Publication number Publication date
CN109257276A (en) 2019-01-22

Similar Documents

Publication Publication Date Title
CN109088778B (en) Data communication implementation method for future mobile network
CN110113264B (en) Method for realizing cache and route of named data network
CN109246785B (en) Method for realizing future mobile network
CN109150723B (en) Routing communication implementation method of Internet of things
CN106941449B (en) A kind of network data communication method based on on-demand mechanism
CN109462549B (en) Method for implementing new generation wireless mobile network
CN109167728B (en) Big data communication implementation method based on named data network
CN106993321B (en) Network data communication method based on cluster
CN110138663A (en) A kind of data-centered new generation network implementation method
CN107979645B (en) Internet of things implementation method
CN106911570A (en) A kind of reliable network data communication method
CN109257276B (en) Efficient named data network implementation method
CN109089241B (en) Data communication implementation method for vehicle-mounted network
CN110401911B (en) Vehicle-mounted cloud implementation method based on named data network
CN111245725B (en) Future network implementation method based on distribution
CN111277497B (en) Method for realizing network service deployment and discovery based on distribution
CN108494595B (en) High-efficiency new-generation big data network implementation method
CN109039901B (en) High-efficiency data network routing implementation method
CN110233889B (en) Network data communication implementation method based on cache mechanism
CN109089293B (en) Route communication realization method for future mobile network
CN108462623B (en) High-efficiency data center network implementation method
CN107949000B (en) Low-delay opportunistic network implementation method
CN110380971B (en) Network data communication method based on buffer mechanism
CN108965138B (en) Method for implementing new generation multimedia sensor network
CN110719208B (en) Method for implementing new generation network based on shortest path

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