DHTTestAPP & DHT work together where DHTTestAPP utilizes the DHT to store & retrieve (key, value) pairs. DHT utilize the underlying overlay to route queries.
DHTTestAPP
Is a Tier2 application that periodically issue DHT put, get, & modify queries. The implementation consist of 2 modules:
Maintain the DHT with the support of the underlying overlay. The implementation consist of 2 modules:
DHTTestAPP
Is a Tier2 application that periodically issue DHT put, get, & modify queries. The implementation consist of 2 modules:
- GlobalDhtTestMap - Provides a data structure & functions to maintain a global list of (key, value) pairs. Random keys are taken from this list to issue DHT get & modify queries.
- DHTTestApp - Issues DHT put, get, & modify queries after some delay derived from a truncnormal distribution.
- Put messages - Use to add a random (key, value) pair into the DHT. A put message (represented as DHTputCAPICall) consists of a random key, random value, expiration time (ttl), & whether (key, value) pair can be modified. Then the message is send to the Tier1 application using sendInternalRpcCall() method, which will store (key, value) pair in the DHT. When a successful response is received (key, value) pair is added to the GlobalDhtTestMap.
- Get messages - Pick a random key from the GlobalDhtTestMap & then issue a DHT get query to the Tier1 application using DHTgetCAPICall() method. Tier1 application sends the appropriate value if it exists. If the key's validity has expired delete it from GlobalDhtTestMap otherwise consider get query as success.
- Modify messages - Pick a random key from the GlobalDhtTestMap & then issue a DHT put query to the Tier1 application. DHT entries are modified using a put message that will place an updated version of the (key, value) pair into DHT.
Maintain the DHT with the support of the underlying overlay. The implementation consist of 2 modules:
- DHTDataStorage - Provides a data structure & functions to maintain DHT storage of a node.
- DHT - Capable of storing & retrieving multiple (key, value) pairs (e.g., same file in multiple peers) given that they have distinct kinds or IDs. Each entry has an expiration time & removed from the DHT when it expires.
Comments
You can set it using **.overlayType in omnetpp.ini. For e.g.,
**.overlayType = "oversim.overlay.mychord.MyChordModules"
Here I use modified version of Chord called 'mychord'
Then you need to set other relevant parameters for your overlay. See examples on omnetpp.ini & default.ini
Thank you.
Alban MOREAU
Thanks