-
Notifications
You must be signed in to change notification settings - Fork 3
/
config.go
43 lines (33 loc) · 1.26 KB
/
config.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
package config
type NodeConf struct {
Number uint `json:"number"`
Upload uint `json:"upload"`
Download uint `json:"download"`
}
type NetworkConf struct {
// network level topology parameters
TransitDomains uint `json:"transitDomains"`
TransitDomainSize uint `json:"transitDomainSize"`
StubDomains uint `json:"stubDomains"`
StubDomainSize uint `json:"stubDomainSize"`
}
type Config struct {
// the language of the entry point and the path of the entry point: file
// which will be used as main class running in the simulation; entry point
// format is [go module]/[nodeStructName]
Lang string `json:"lang"`
Entry string `json:"entry"`
// path to the location of the log.json file
LogFile string `json:"logFile"`
// number of peers in the system
Nodes uint `json:"nodes"`
Network *NetworkConf `json:"network"`
// interval of virtual time units at which the capacity scheduler runs
TransferInterval uint `json:"transferInterval"`
// list which shows the distribution of node capacities
CapacityNodes []NodeConf `json:"capacityNodes"`
// Latency support - when latency support is off, nodes run directly
Latency bool `json:"latency"`
// Run the simulator's event queue with support for parallel events.
Parallel bool `json:"parallel"`
}