SonarQube error: Component key length is longer than the maximum authorized

2.9k views Asked by At

I have this error on SonarQube 6.1

Please note: I cannot shorten the projecy key, since I have no power over the organization's naming convention, our work is to mantain the platform. I am aware the name can be made short, but I am looking for a workaround (ie. ALTER table for the field lenght? If so, which and how?)

"java.lang.IllegalArgumentException: Component key length is longer (401) than the maximum authorized (400)"

The kee is indeed longer than the 400 characters allowed, but I have no control over the naming convention since we manage the build system.

That said, I am looking for a workaround to overcome this error. Any guesses ?

1

There are 1 answers

7
Teryk - SonarSource On BEST ANSWER

I suggest to shorten the project key:

  • SonarQube documentation to rename a key in SonarQube
  • launch analyses with the sonar.projectKey property, with the new shorten key