NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.
-
Upload
dortha-goodman -
Category
Documents
-
view
213 -
download
0
Transcript of NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.
![Page 1: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/1.jpg)
1
NFD forwarding pipelines
Junxiao Shi, 2015-07-09
![Page 2: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/2.jpg)
2
Overview
• Forwarding consists of pipelines and strategies• Pipeline: a series of steps that operate on a packet
or a PIT entry• Strategy: a decision maker on whether, when, and
where to forward an Interest
![Page 3: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/3.jpg)
3
Pipelines
• incoming Interest• ContentStore miss• ContentStore hit• Interest loop• outgoing Interest• Interest reject• Interest unsatisfied• Interest finalize• incoming Data• Data unsolicited• outgoing Data
![Page 4: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/4.jpg)
4
Legend in diagrams
building block
pipeline
tables feature
strategy
face feature
![Page 5: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/5.jpg)
5
incoming Interest
incoming Data
outgoing Interest
outgoing Data
strategy API
ncc strategy
broadcast strategy
Interest reject
Interest unsatisfied
Interest loop
best route strategy
Data unsolicited
Interest finalize
ContentStore miss
ContentStore hit
access strategy
![Page 6: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/6.jpg)
6
Pipelines Overall Workflow
incoming Interest
incoming Data
outgoing Interest
outgoing Data
after receive Interest
Interest reject
Interest unsatisfied
Interest loop
Data unsolicited
before satisfy Interest
before expire Interest
unsatisfytimer
stragglertimer
Interest finalize
ContentStore miss
ContentStore hit
![Page 7: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/7.jpg)
7
incoming Interest pipeline
CS lookup
PIT insert
cancel unsatisfy & straggler timer
Y
receive Interest
detect duplicate
Nonce
Interest loopY
is pending?
Y
violates /localhost?
Y (drop)
ContentStore miss
ContentStore hit
N
N
N
N
![Page 8: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/8.jpg)
8
detect duplicate Nonce
• If any InRecord or OutRecord contains the same Nonce as the incoming Interest, or the Name and Nonce of the incoming Interest appear in Dead Nonce List, a duplicate Nonce is detected.• If the duplicate Nonce is found in InRecord only, this is a
multi-path arrival, and not a loop.• If the duplicate Nonce is found in OutRecord or Dead
Nonce Table, this is either a multi-path arrival or a loop, and these two reasons are indistinguishable.
• Nonce is later recorded on an InRecord.
![Page 9: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/9.jpg)
9
Interest loop pipeline
• Process an Interest that has been considered looped• This pipeline is currently empty, which means Interest
packet is dropped. NACK could be added here
![Page 10: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/10.jpg)
10
ContentStore miss pipeline
• This pipeline is entered when an incoming Interest• is pending (so ContentStore lookup is unnecessary), or• is miss from ContentStore
• This pipeline will start forwarding the Interest
![Page 11: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/11.jpg)
11
ContentStore miss pipeline
FIB lookup with Interest Name
dispatch to strategy
insert InRecordset PIT
unsatisfy timerInterest
unsatisfiedtimer event
in producer region?
has Selected
Delegation?
FIB lookup with SelectedDelegation
choose and set SelectedDelegation
Y
N N
Y
FIB lookup with first Delegation Name
in default-free zone?
YN
![Page 12: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/12.jpg)
12
set PIT unsatisfy timer
• Given PIT entry, set an unsatisfy timer which fires when InterestLifetime expires for all unexpired InRecords• When the unsatisfy timer fires, Interest unsatisfied
pipeline is entered
![Page 13: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/13.jpg)
13
determine whether in producer region• Input:
• routerName: the router's Name, from configuration• interest
• Algorithm:1. if the Interest does not have a Link object, return true and abort
these steps2. foreach delegation in Link:
1. if delegation Name is a prefix of routerName, return true and abort these steps
3. return false
• Note:• We consider all delegations, not just SelectedDelegation, to
maximize flexibility. This is cheap because there's no table lookup.
![Page 14: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/14.jpg)
14
determine whether in default-free zone• Input:
• interest, with Link but without SelectedDelegation• FIB lookup result for the first delegation
• Algorithm:1. if FIB lookup result is the root entry (ndn:/), and the entry has
at least one nexthop record, return true2. return false
• Note:• FIB lookup will never return "no match", because the FIB always
has a root entry, but this entry can have no nexthop record.• We consider only the first delegation, to minimize table lookup
cost. Checking all delegations probably gives better results, but it requires too many lookups.
![Page 15: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/15.jpg)
15
choose and set SelectedDelegation• Input:
• interest, with Link but without SelectedDelegation• FIB
• Algorithm:1. foreach delegation in Link, sorted by increasing Preference
1. lookup FIB with delegation Name2. if a match (with non-zero nexthop records) is found, insert
SelectedDelegation field with the index of this delegation, return the match, and abort these steps
2. lookup FIB with Interest Name
• Note:• This is the only operation that requires multiple table lookups, but it
happens only once on an Interest's path at the first default-free router.
![Page 16: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/16.jpg)
16
outgoing Data
set PIT straggler timer
timer event
Interest finalize
ContentStore hit pipeline
![Page 17: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/17.jpg)
17
dispatch incoming Interest to strategy• Given FIB entry and incoming Interest, determine
which strategy should process this Interest, and trigger that strategy
![Page 18: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/18.jpg)
18
outgoing Interest pipeline
insert OutRecordpick Interest send Interest
violates /localhost?
Y
(drop)
violates /localhop?
(drop)
Y
N N
![Page 19: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/19.jpg)
19
pick outgoing Interest packet• Given PIT entry and nexthop, decide the guiders on
the outgoing Interest• Nonce and InterestLifetime come from an InRecord with
longest remaining lifetime, however InRecord with same Face as the nexthop cannot be used• InterestLifetime is carried from the original packet
without deducting the time elapsed• Scope is the most relaxed among all unexpired InRecords• The last incoming Interest is picked
• This is a simple choice until we understand the effect of guiders better
![Page 20: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/20.jpg)
20
Interest reject pipeline
• Process an Interest that has been decided that it has nowhere to go
set PIT straggler timer
timer event
cancel unsatisfy & straggler timer
Interest finalize
![Page 21: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/21.jpg)
21
Interest unsatisfied pipeline
invoke PIT unsatisfied callback
Interest finalize
![Page 22: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/22.jpg)
22
Interest finalize pipeline
PIT delete
Dead Nonce List insert
need Dead Nonce List
insert?
Y
N
![Page 23: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/23.jpg)
23
Dead Nonce List insert
• Dead Nonce List insertion is needed if:• Interest is unsatisified, OR• Interest has MustBeFresh=yes and Data FreshnessPeriod
is shorter than 6 seconds
• Nonces in OutRecords are inserted to Dead Nonce List.
![Page 24: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/24.jpg)
24
incoming Data pipeline
PIT match
receive Data
Y CS insert
outgoing Data
cancel unsatisfy & straggler timer
mark PIT satisfied
set PIT straggler timer
foreachPIT entry
foreachpendingdownstream
Data unsolicited
timer event
violates /localhost?
Y(drop)
invoke PIT satisfy callback
Interest finalize
Dead Nonce List insert
need Dead Nonce List
insert?
Y
N
N
N
![Page 25: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/25.jpg)
25
set PIT straggler timer
• Given PIT entry, set a straggler timer which fires after a short time• Tstraggler = 100ms
• When the straggler timer fires, PIT entry is deleted
• The purpose of retaining PIT entry for a short time is to facilitate loop detection and to collect measurement for non-fastest upstreams
![Page 26: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/26.jpg)
26
Data unsolicited pipeline
accept to cache?
Y
CS insert
N
![Page 27: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/27.jpg)
27
outgoing Data pipeline
traffic manager send Data
violates /localhost?
Y(drop)
N
![Page 28: NFD forwarding pipelines Junxiao Shi, 2015-07-09 1.](https://reader030.fdocuments.in/reader030/viewer/2022032606/56649e915503460f94b96d11/html5/thumbnails/28.jpg)
28
Pass-through traffic manager• Provide a traffic manager that does nothing and
merely passes Data packet to the next step