code: func (p *Plugin) AfterInit() error {
  	if !p.isKvEnabled() {
  		p.Log.Debugf("KVPlugin is nil or disabled, skipping AfterInit")
  		return nil
  	}
  
  	// set function to be executed on KVPlugin connection
  	p.KvPlugin.OnConnect(p.initKvPlugin)
  
  	return nil
  }
docs: // AfterInit uses provided connection to build new transport watcher.
  //
  // Plugin.registry subscriptions (registered by Watch method) are used for resync.
  // Resync is called only if ResyncOrch was injected (i.e. is not nil).
  // The order of plugins in flavor is not important to resync
  // since Watch() is called in Plugin.Init() and Resync.Register()
  // is called in Plugin.AfterInit().
  //
  // If provided connection is not ready (not connected), AfterInit starts new goroutine in order to
  // 'wait' for the connection. After that, the new transport watcher is built as usual.