Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-14584

Analysis of the project can fail if path of the file exceeds 400 character limit

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Compute Engine, Database
    • Labels:
      None
    • Edition:
      Community
    • Production Notes:
      None

      Description

      Analysis of the project can fail if path of the file exceeds 400 character limit.

      Steps to reproduce:
      1. Create a project with deeply nested directory (relative path should exceed 400 char)
      2. Analyse project
      3. Project analysis fails with exception:

      Caused by: java.lang.IllegalArgumentException: Component key length (470) is longer than the maximum authorized (400). 'com.sonarsource:test-project-1:src/main/java/com/sonarsource/ver_long_(…)' was provided.
      	at com.google.common.base.Preconditions.checkArgument(Preconditions.java:459)
      	at org.sonar.db.component.ComponentValidator.checkComponentKey(ComponentValidator.java:77)
      	at org.sonar.db.component.ComponentDto.setDbKey(ComponentDto.java:185)
      	at org.sonar.ce.task.projectanalysis.step.PersistComponentsStep$PersistComponentStepsVisitor.createBase(PersistComponentsStep.java:365)
      
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              jacek.poreda Jacek Poreda
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated: