diff options
author | simonbrandhof <simon.brandhof@gmail.com> | 2011-09-11 20:46:29 +0200 |
---|---|---|
committer | simonbrandhof <simon.brandhof@gmail.com> | 2011-09-11 20:46:29 +0200 |
commit | 8b162f1f5718b1c25bbf83ab75f731043ddf30ea (patch) | |
tree | cd94be9488f8b998ede9a5907f025089a614c379 /sonar-server | |
parent | 0d57ce7853c35d7b6c502bd4b1c3284dafc41371 (diff) | |
download | sonarqube-8b162f1f5718b1c25bbf83ab75f731043ddf30ea.tar.gz sonarqube-8b162f1f5718b1c25bbf83ab75f731043ddf30ea.zip |
SONAR-2603 increase size of server id
Diffstat (limited to 'sonar-server')
-rw-r--r-- | sonar-server/src/main/java/org/sonar/server/platform/ServerIdGenerator.java | 2 | ||||
-rw-r--r-- | sonar-server/src/test/java/org/sonar/server/platform/ServerIdGeneratorTest.java | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/sonar-server/src/main/java/org/sonar/server/platform/ServerIdGenerator.java b/sonar-server/src/main/java/org/sonar/server/platform/ServerIdGenerator.java index 3577effe7e6..7d09dd95c99 100644 --- a/sonar-server/src/main/java/org/sonar/server/platform/ServerIdGenerator.java +++ b/sonar-server/src/main/java/org/sonar/server/platform/ServerIdGenerator.java @@ -42,7 +42,7 @@ public class ServerIdGenerator { */ static final String VERSION = "1"; - static final int CHECKSUM_SIZE = 9; + static final int CHECKSUM_SIZE = 14; private final boolean acceptPrivateAddress; diff --git a/sonar-server/src/test/java/org/sonar/server/platform/ServerIdGeneratorTest.java b/sonar-server/src/test/java/org/sonar/server/platform/ServerIdGeneratorTest.java index 73677bec163..354e19435ea 100644 --- a/sonar-server/src/test/java/org/sonar/server/platform/ServerIdGeneratorTest.java +++ b/sonar-server/src/test/java/org/sonar/server/platform/ServerIdGeneratorTest.java @@ -42,7 +42,7 @@ public class ServerIdGeneratorTest { @Test public void idShouldHaveTenCharacters() { String id = new ServerIdGenerator().toId("SonarSource", localhost); - assertThat(id.length(), Is.is(10)); // first character is version + 9 characters for checksum + assertThat(id.length(), Is.is(15)); // first character is version + 14 characters for checksum assertThat(StringUtils.isBlank(id), Is.is(false)); } |