Currently language detection rely on the extension point org.sonar.api.resources.Language implemented by plugins. The downside of this approach is that there is a lifecycle issue. We may want to do some actions conditionally to the file language, even if the analyzer is not there.
For example, if the analyzer could not be loaded for some technical reason (like MMF-2133) then we would like to warn the user only when a file of the affected language is about to be analyzed.
Later, we could even think about lazyly downloading/loading analyzer only when a first file or the language is opened.
For all those reasons, SonarLint should take back the ownership of language detection.
Also, SonarLint supports a fixed list of languages, so the "pluggability" is not important for us.