INNER CODE UNIT · Go

main

apache/yunikorn-core · cmd/queueconfigchecker/queueconfigchecker.go:31

func main() {
	if len(os.Args) != 2 {
		//nolint:gosec // safe to ignore, this is a utility command and the argument is provided by the user
		log.Println("Usage: " + os.Args[0] + " <queue-config-file>")
		os.Exit(1)
	}
	queueFile := os.Args[1]
	//nolint:gosec // safe to ignore, this is a utility command and the file path is provided by the user
	conf, err := os.ReadFile(queueFile)
	if err != nil {
		log.Printf("Could not read file: %v", err)
		os.Exit(2)
	}
	_, err = configs.LoadSchedulerConfigFromByteArray(conf)
	if err != nil {
		log.Printf("Config validation failed: %v", err)
		os.Exit(3)
	}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…