Commit adb0e53c authored by Nils Goroll's avatar Nils Goroll

dev doc

parent 0f30a816
...@@ -6,15 +6,29 @@ digraph bytes_node_state { ...@@ -6,15 +6,29 @@ digraph bytes_node_state {
node_insert -> ST_PRIVATE node_insert -> ST_PRIVATE
vdp_pesi_init -> ST_PRIVATE vdp_pesi_init -> ST_PRIVATE
ST_PRIVATE -> ST_OPEN tree_free [label="tree_free()"]
subgraph cluster_T_NEXUS {
label="T_NEXUS"
ST_PRIVATE -> ST_OPEN [label="set_open()"]
ST_PRIVATE -> ST_CLOSED [label="set_closed()"] ST_PRIVATE -> ST_CLOSED [label="set_closed()"]
ST_OPEN -> ST_CLOSED [label="set_closed()"] ST_OPEN -> ST_CLOSED [label="set_closed()"]
}
subgraph cluster_leaf {
label="leaf nodes:\nT_DATA\nT_CRC\nT_SUBREQ\nT_FINAL"
ST_DATA -> ST_UNPENDING [label="set_unpending()"] ST_DATA -> ST_UNPENDING [label="set_unpending()"]
}
ST_DATA -> ST_DELIVERED [label="set_delivered()\nOnly for magic nodes"] ST_CLOSED -> ST_DELIVERED [label="set_delivered()\n"]
ST_UNPENDING -> ST_DELIVERED [label="set_delivered()"] ST_UNPENDING -> ST_DELIVERED [label="set_delivered()"]
ST_CLOSED -> ST_DELIVERED [label="set_delivered()\nAll children must be delivered"]
ST_DATA -> ST_DELIVERED [label="set_delivered()\nif NULL data"]
ST_DELIVERED -> tree_free
ST_PRIVATE -> ST_DATA [label="node_mutate_*()"]
} }
\ No newline at end of file
digraph tree { digraph tree {
subgraph cluster_ex {
label="Example"
root [shape=diamond] root [shape=diamond]
root -> a root -> a
...@@ -24,14 +27,28 @@ digraph tree { ...@@ -24,14 +27,28 @@ digraph tree {
db [shape=box] db [shape=box]
dc [shape=triangle] dc [shape=triangle]
dd [shape=triangle] dd [shape=triangle]
}
subgraph cluster_types {
label="Types"
subgraph cluster {
/* legend */ /* legend */
T_NEXUS [shape=diamond] T_NEXUS [shape=diamond]
T_DATA [shape=triangle] T_DATA [shape=triangle, label="T_DATA\nT_CRC\n(bytes to oc)"]
T_SUBREQ [shape=box] T_SUBREQ [shape=box, label="T_SUBREQ\nT_FINAL\n(oc / thread)"]
T_NEXUS -> T_DATA T_NEXUS -> T_DATA
T_NEXUS -> T_SUBREQ T_NEXUS -> T_SUBREQ
T_NEXUS2 [shape=diamond, label=T_NEXUS]
T_NEXUS -> T_NEXUS2
T_NEXUS2 -> more1
T_NEXUS2 -> more2
T_NEXUS2 -> more3
more1 [shape=none, label="..."]
more2 [shape=none, label="..."]
more3 [shape=none, label="..."]
} }
} }
\ No newline at end of file
...@@ -114,20 +114,36 @@ enum n_type { ...@@ -114,20 +114,36 @@ enum n_type {
* *
* ST_DATA: may never have any children * ST_DATA: may never have any children
* *
* T_DATA / T_CRC / T_SUBREQ / T_FINAL
*
* ST_PRIVATE: may receive pushes creating children * ST_PRIVATE: may receive pushes creating children
* unpending must not yet touch it * unpending must not yet touch it
* creating children unlocked * children can be created unlocked
* XXX can change into other types * can change into other types
*
* T_NEXUS only
* *
* ST_OPEN: may receive pushes creating children * ST_OPEN: may receive pushes creating children
* unpending may deliver in parallel * unpending may deliver in parallel ("front delivery")
* XXX OR NOT - WIP * any changes below loced only
*
* T_NEXUS only
*
* *
* ST_CLOSED: the request is done, no pushes can occur * ST_CLOSED: the request is done, no pushes can occur,
* unpending can proceed upwards
*
* T_NEXUS only
* *
* ST_UNPENDING: in the process of being pushed to the client * ST_UNPENDING: in the process of being pushed to the client
* *
* T_DATA / T_CRC / T_SUBREQ / T_FINAL
*
* ST_DELIVERED: We have pushed data up * ST_DELIVERED: We have pushed data up
*
* any type
*
* for T_NEXUS, means "anything below is delivered"
*/ */
enum n_state { enum n_state {
ST_INVALID = 0, ST_INVALID = 0,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment