Свойство | Тип | Описание | |
---|---|---|---|
TimeBetweenCleanup | int |
Свойство | Тип | Описание | |
---|---|---|---|
_base_dir | string | ||
count | int |
Метод | Описание | |
---|---|---|
AddEntry ( |
This adds an entry and should only be called if no such entry exists, as it does not look to see if a duplicate entry already exists. This creates a new LinkedList if this is the first entry for the specific key and stores it in the _data hashtable. This increments count. Because data is stored by non-decreasing end time, we must place this at the correct position, which by starting at the last entry is right after the first entry that has a shorter end time. |
|
CacheEviction ( Object o, |
||
CacheMiss ( Object o, |
||
CheckEntries ( ) : void |
Deletes any of the expired entries by traversing the entire data store. This is done only once every 24 hours to reduce heavy memory access due to short lived unused entries.
|
|
CleanUp ( Object o, |
Called to clean up the disk data left behind by the dht
|
|
DeleteExpired ( |
Deletes all expired entries for the specified key. For each entry deleted, count is decremented. This should be called before accessing the data stored in this table.
|
|
Dump ( ) : |
Converts all the entries into Adr compatible types so that they can be sent over BrunetRpc and XmlRpc
|
|
GeneratePath ( MemBlock key ) : string |
Generates a path given a key.
|
|
GeneratePath ( MemBlock key, string &path, string &filename ) : string |
Generates a path given a key.
|
|
GetEntries ( MemBlock key ) : LinkedList |
Retrieves the entries for the specified key.
|
|
GetKeys ( ) : LinkedList |
Returns the list of keys.
|
|
GetKeysBetween ( AHAddress add1, AHAddress add2 ) : LinkedList |
Returns a list of keys stored at this node that exist between the two addresses. Such keys returned are the storest path between the two addresses.
|
|
RemoveEntry ( MemBlock key, MemBlock value ) : void |
This removes an entry from the TableServerData, the current dht does not support deletes, but if the second stage of a put (the remote PutHandler) fails, the entry needs to be deleted from this node.
|
|
TableServerData ( ) : System | ||
TableServerData ( Node node ) : System |
Creates a new data store for the dht.
|
|
TableServerData ( String dir ) : System | ||
UpdateEntry ( MemBlock key, MemBlock value, DateTime end_time ) : void |
This should be called if an entry already exists as it will find the entry and update its lease time. If an entry does not exist nothing happens.
|
Метод | Описание | |
---|---|---|
Test0 ( ) : void | ||
Test1 ( ) : void | ||
Test2 ( ) : void |
public AddEntry ( |
||
entry | The data to store. | |
Результат | void |
public CacheEviction ( Object o, |
||
o | Object | |
args | ||
Результат | void |
public CacheMiss ( Object o, |
||
o | Object | |
args | ||
Результат | void |
public CleanUp ( Object o, |
||
o | Object | Unused. |
args | Unused. | |
Результат | void |
public DeleteExpired ( |
||
key | The index to check for expired entries. | |
Результат | int |
public GeneratePath ( MemBlock key ) : string | ||
key | MemBlock | The key to generate a path for. |
Результат | string |
public GeneratePath ( MemBlock key, string &path, string &filename ) : string | ||
key | MemBlock | The key to generate a path for. |
path | string | Returns the directory portion of the path. |
filename | string | Returns the filename portion of the path. |
Результат | string |
public GetEntries ( MemBlock key ) : LinkedList |
||
key | MemBlock | |
Результат | LinkedList |
public GetKeysBetween ( AHAddress add1, AHAddress add2 ) : LinkedList |
||
add1 | AHAddress | One of the address end points. |
add2 | AHAddress | Another of the address end points. |
Результат | LinkedList |
public RemoveEntry ( MemBlock key, MemBlock value ) : void | ||
key | MemBlock | The index the data is stored at. |
value | MemBlock | The data to remove. |
Результат | void |
public TableServerData ( Node node ) : System | ||
node | Node | For uncache data, we use the node to alert us to delete the entries as well the address to define a path to store them. |
Результат | System |
public TableServerData ( String dir ) : System | ||
dir | String | |
Результат | System |
public UpdateEntry ( MemBlock key, MemBlock value, DateTime end_time ) : void | ||
key | MemBlock | The index to store the value. |
value | MemBlock | The data to store. |
end_time | DateTime | The lease time for the data. |
Результат | void |