Is it possible to detect races in Go with SonarQube?

I have a fairly simple Go code that has data races and -race can catch them. However, I can not find where SonarQube does any race detection and analysis.

Is it possible to detect races in Go with SonarQube?

The code:

package main

var balance = 10000

func main() {
    for i:=0; i<10000; i++ {
	    go func() {
	    	balance--
	    }()
    }
}

Hey there.

I don’t think we have such a rule, however we dod support a few external issue report formats for Go.

Language Property Remarks
Go sonar.go.govet.reportPaths Comma-delimited list of paths to GoVet reports
Go sonar.go.golint.reportPaths Comma-delimited list of paths to GoLint reports
Go sonar.go.gometalinter.reportPaths Comma-delimited list of paths to GoMetaLinter reports
Go sonar.go.golangci-lint.reportPaths Comma-delimited list of paths to golangci-lint reports in checkstyle format (use --out-format checkstyle golangci-lint option)

Maybe one of these works for you.