23 lines
443 B
Go
23 lines
443 B
Go
package main
|
|
|
|
import (
|
|
"_StorBackEnd/pkg/network"
|
|
)
|
|
|
|
const (
|
|
MULTICAST_ADDRESS = "226.66.66.1:42500"
|
|
MULTICAST_SECOND = 10 // TODO : Changer en 30 secondes
|
|
UNICAST_ADDRESS = "0.0.0.0:58000"
|
|
)
|
|
|
|
func main() {
|
|
println("StorBackEnd started !")
|
|
|
|
multicast := network.CreateClientMulticast(MULTICAST_ADDRESS, MULTICAST_SECOND)
|
|
go multicast.Run()
|
|
|
|
server := network.ServerUnicast{Network: "tcp", Address: UNICAST_ADDRESS}
|
|
server.Run()
|
|
|
|
}
|