Skip to content

Commit 9b97576

Browse files
committed
Update README.md
1 parent 118f097 commit 9b97576

File tree

1 file changed

+42
-1
lines changed

1 file changed

+42
-1
lines changed

README.md

+42-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ go run ./cmd/main.go -node=Node1 -port=<PORT> -ip=<IP> -coding=<RS/LT>
1212
```
1313

1414
Manual running - Retriever Node:
15-
1615
```bash
1716
go run ./cmd/main.go -node=<Node$id> -port=<PORT> -ip=<IP> -coding=<RS/LT>
1817
```
@@ -25,4 +24,46 @@ Automatic running (Prefered):
2524
Stop all the nodes:
2625
```terminal
2726
ps aux | grep go | grep -v grep | awk '{print $2}' | xargs kill -9
27+
```
28+
29+
30+
Config:
31+
32+
```go
33+
const (
34+
ExpectedChunks = 6
35+
)
36+
37+
// Reed-Solomon parameters
38+
const (
39+
DataShards = 5
40+
ParityShards = 3
41+
)
42+
43+
// Luby-Transform parameters
44+
const (
45+
LTSourceBlocks = 5
46+
LTEncodedBlockCount = 7
47+
RandomSeed = 42
48+
)
49+
50+
var (
51+
NodeID string
52+
CodingMethod string
53+
Nodes = 10
54+
ReceivedChunks = sync.Map{}
55+
SentChunks = sync.Map{}
56+
NodeMutex = sync.Mutex{}
57+
ConnectedPeers []peer.AddrInfo
58+
Node1ID peer.ID
59+
ReceivedFrom = sync.Map{}
60+
Counter = 0
61+
// Must be changed to the coding method
62+
// if LT then it should be LTEncodedBlockCount
63+
// if RS then it should be DataShards + ParityShards
64+
ChunksRecByNode = make([][]byte, DataShards+ParityShards)
65+
ReadyCounter = 0
66+
StartTime time.Time
67+
OriginalLength = 29283680
68+
)
2869
```

0 commit comments

Comments
 (0)