Commit Graph

6 Commits

Author SHA1 Message Date
kaiyou 9fdab65237 Revert "Move the metadata parsing code to node.go"
This reverts commit ac6289b5bf95e8903ea90ddf807832a2358371b0.
2020-05-13 13:52:54 +02:00
kaiyou 00c9d5ec76 Create the node slice with the proper length
Co-authored-by: Leo Antunes <leo@costela.net>
2020-05-13 13:52:54 +02:00
kaiyou b0bfeb1f8e Move the metadata parsing code to node.go 2020-05-13 13:52:54 +02:00
kaiyou 0e799d6074 Parse metadata outside of cluster.go
Move the calls for metadata decoding from the cluster
membership management loop to the main loop. This task
was not directly related to the cluster, and was adding
complexity, including the need for multierr structures.
2020-05-13 13:52:54 +02:00
kaiyou 97525f4b10 Stop using wireguard in cluster.go
The wireguard is mostly used to compute metadata.
Metadata is now computed by main.go and encoded in
node.go, the cluster only receives a function generating
the binary metadata.
2020-05-13 13:52:54 +02:00
kaiyou 0d93439d0d Move node related stuff to node.go
The cornerstone for exchanging data is the node
structure and associated metadata. Moving it to a
separate file (maybe later a separate module) will help
decoupling.
2020-05-13 13:52:54 +02:00