-
Notifications
You must be signed in to change notification settings - Fork 16
Repo Integration
This is draft for integrate NDN Repo into ndn-lite framework. NDN Repo's integration can largely improve the data reliability of a local ndn-lite system.
NDN Repo should serve as a data repository running at either at local or remotely. Data published can be inserted into Repo and kept persistently. Either controller or devices can insert data, while only controller have the right to delete data. NDN Repo should be able to discovered as a ndn-lite service and insertion should be called as ndn-lite service invocation.
Routable prefix and connetivity info of this NDN Repo should also be discovered through the service query. If not all device can reach to this NDN Repo via equipped communication technologies, controller or hub should serve as a relay to forward the interest-data exchange between device and NDN Repo.
Controller: If the NDN Repo and controller locate on the same host (i.e., repo and controller share one NFD), Controller will respond devices' service discovery query related to the repo. Query response should contain repo's prefix, face available, and ports in working
If the NDN Repo and controller locate on different hosts (e.g., repo served on icear.cs.ucla.edu while controller is at local), controller have two options in response to devices' service query.
- Reply with detailed real information (IP address, Port, Prefix)
- Reply with self working port and serve as the proxy to bridge the communication between devices and repo. In this case, repo's prefix facing to local network is
/<home-prefix>/repo
.
Device:
After security bootstrapping, devices add NDN_SD_REPO
into interested service list and begin discovery. Based on the query result, different approaches will be chosen.
- If there's available repo, and flags of
ENABLE_NDN_REPO
is set, redirect data publish of Pub/Sub to a repo insertion. If the repo insertion fails, fall back to a normal publishing - If there's no available repo, or flags of
ENBALE_NDN_REPO
is not set, data publishing goes as normal.
Consideration of Pub/Sub Redirection:
Based on NDN Repo documentation, after receiving insertion request, repo will express an Interest with insertion awating Data's exact Name if there's no start_block_id
and end_block_id
given in insertion command. Thus there will be a complete Interest-Data exchange of insertion awaiting Data. Other nodes in the network can catch this information and infer the potential data publication. If one has an active PIT entry related at data publishing time, its Pub/Sub module will receive the Data from the forwarder. As a result, whether data publishing is redirected to a repo insertion will not affect Pub/Sub's functionality.