code: func NewEngine(cfg *config.EngineConfig) *Engine {
  	if cfg == nil {
  		defaultCfg := config.DefaultEngineConfig()
  		cfg = &defaultCfg
  	}
  	// TODO(jsing): Validate node, peer and cluster IP configuration.
  	engine := &Engine{
  		config:   cfg,
  		fwmAlloc: newMarkAllocator(fwmAllocBase, fwmAllocSize),
  		ncc:      ncclient.NewNCC(cfg.NCCSocket),
  
  		overrides:    make(map[string]seesaw.Override),
  		overrideChan: make(chan seesaw.Override),
  
  		vlans:    make(map[uint16]*seesaw.VLAN),
  		vservers: make(map[string]*vserver),
  
  		shutdown:    make(chan bool),
  		shutdownARP: make(chan bool),
  		shutdownIPC: make(chan bool),
  		shutdownRPC: make(chan bool),
  
  		vserverSnapshots: make(map[string]*seesaw.Vserver),
  		vserverChan:      make(chan *seesaw.Vserver, 1000),
  	}
  	engine.bgpManager = newBGPManager(engine, cfg.BGPUpdateInterval)
  	engine.haManager = newHAManager(engine, cfg.HAStateTimeout)
  	engine.hcManager = newHealthcheckManager(engine)
  	engine.syncClient = newSyncClient(engine)
  	engine.syncServer = newSyncServer(engine)
  	return engine
  }
docs: // NewEngine returns an initialised Engine struct.