Commit Graph

480 Commits

Author SHA1 Message Date
Karsten Loesing
5af3f60993 Simplify method call. 2019-11-20 12:07:49 +01:00
Karsten Loesing
a18c70b33e Simplify switch/case statement. 2019-11-20 12:07:01 +01:00
Karsten Loesing
75e1d31465 Use StandardCharsets.US_ASCII instead of "US-ASCII". 2019-11-20 12:04:29 +01:00
Karsten Loesing
2614e6137c Fix logging. 2019-11-20 12:03:05 +01:00
Karsten Loesing
25ea064dc8 Remove deprecation warning.
Class#newInstance is deprecated in Java 9 and higher, which doesn't
affect us yet in Java 8. But the suggested replacement already works
in Java 8, so that we can safely switch to that.
2019-11-20 11:14:48 +01:00
Karsten Loesing
87d998c542 Bump version to 2.9.1-dev. 2019-11-09 12:30:02 +01:00
Karsten Loesing
6c8470a0b7 Prepare for 2.9.1 release. 2019-11-09 12:25:11 +01:00
Karsten Loesing
fba9137499 Ignore unknown fields in index.json.
This is required for processing index.json files produced by CollecTor
1.13.0 or higher. We don't need those newly added fields or any other
fields added in the future. But we must not fail when fields are
added.
2019-11-09 12:24:28 +01:00
Karsten Loesing
8763af4446 Bump version to 2.9.0-dev. 2019-11-01 09:17:42 +01:00
Karsten Loesing
4bdfc62905 Prepare for 2.9.0 release. 2019-11-01 09:10:25 +01:00
Karsten Loesing
bde697f447 Make NetworkStatusEntryImpl#parseSLine thread-safe.
The bug was that we accessed static class members, namely the two maps
NetworkStatusEntryImpl#flagIndexes and #flagStrings, during instance
creation without synchronization. This worked just fine with a single
thread creating instances, but it breaks with multiple threads doing
that at the same time.

The fix is to keep a separate map per NetworkStatusImpl instance and
share that between all its NetworkStatusEntryImpl instances. This
doesn't save as much memory as sharing maps between all
NetworksStatusEntryImpl instances ever created, but it's a reasonable
compromise between memory and runtime efficiency. In contrast to that,
synchronizing map access would have put a major runtime performance
penalty on parsing.

Fixes #32194.
2019-10-31 14:57:50 +01:00
Karsten Loesing
02e486d16d Bump version to 2.8.0-dev. 2019-10-18 09:43:10 +02:00
Karsten Loesing
ee87da0f04 Prepare for 2.8.0 release. 2019-10-18 09:33:36 +02:00
Karsten Loesing
09d7311df6 Add new BridgedbMetrics descriptor type.
Also extend DescriptorReader#readDescriptors to support .gz-compressed
files which will be necessary to process files rsync'ed from BridgeDB.
And maybe it's useful for other purposes, too.

Implements part of #19332.
2019-10-18 09:27:07 +02:00
Karsten Loesing
8e2f67107f Upgrade to latest metrics-base. 2019-10-02 14:34:41 +02:00
Karsten Loesing
c1581dd8ca Upgrade to latest metrics-base. 2019-09-27 08:58:47 +02:00
Karsten Loesing
c324d11035 Upgrade to latest metrics-base. 2019-09-17 10:00:00 +02:00
Karsten Loesing
7e396f01ef Bump version to 2.7.0-dev. 2019-09-11 16:08:16 +02:00
Karsten Loesing
0520779255 Prepare for 2.7.0 release. 2019-09-06 08:53:14 +02:00
Karsten Loesing
dc946fe1c8 Add new SnowflakeStats descriptor type.
Implements #29461.
2019-09-05 16:47:31 +02:00
Iain R. Learmonth
4d8a8ea711 Adds GitLab CI for tests and checks
Configuration is held in the .gitlab-ci.yml file.

Fixes: #31645
2019-09-05 13:03:55 +01:00
fava
114f548674 Fix leaking resource in TorperfResultImpl.java
Fix leaking resource in TorperfResultImpl.java using
try-with-resource statement.
This fix is related to analysis on metrics-lib using sonarqube
Implements part of #30544

Signed-off-by: fava <fava@libertymail.net>
2019-08-29 06:52:16 +00:00
fava
9fc82fafb3 Fix leaking resource in ExitListEntryImpl.java
Fix leaking resource in ExitListEntryImpl.java using
try-with-resource statement.
This fix is related to analysis on metrics-lib using sonarqube
Implements part of #30544
2019-08-22 05:41:03 +00:00
fava
ce19c16543 Fix leaking resource in DescriptorReaderImpl.java
Fix leaking resource in DescriptorReaderImpl.java using
try-with-resource statement.
This fix is related to analysis on metrics-lib using sonarqube
Implements part of #30544
2019-08-22 05:28:44 +00:00
fava
3987fe8fd6 Ignore Intellij's project files.
Ignore Intellij's project files in order
to avoid personal configurations erroneusly committed
to the repository.
2019-08-22 04:46:34 +00:00
Karsten Loesing
53b16d192d Remove Cobertura from the build process. 2019-08-12 09:34:04 +02:00
Karsten Loesing
e1728709b5 Use Ivy for resolving external dependencies.
Includes an upgrade to the latest metrics-base commit 256e619.

Implements part of #31326.
2019-08-06 15:46:59 +02:00
Karsten Loesing
7032e73a64 Revert all Debian buster library upgrades.
Turns out that updating all dependencies, including those in
metrics-web and exonerator using servlets and JSPs, is much harder
than expected. We decided to revert all these changes for now, so that
we can merge patches again. We're going to investigate alternatives
like Ant + Ivy, Maven, or Gradle in the near future.
2019-07-28 21:46:09 +02:00
Karsten Loesing
4ffa637c56 Add change log entry for Cobertura deps. 2019-07-24 19:56:39 +02:00
Karsten Loesing
aa686c4b49 Upgrade to latest metrics-base.
Also include change log entries.
2019-07-24 19:25:19 +02:00
Karsten Loesing
453a6f5acb Update to Debian buster libraries.
Also upgrade to latest metrics-base.

Note that Checkstyle is excluded from this update, because there's a
yet unresolved issue with the new version: ("Unable to create Root
Module") that we'll have to address in a separate patch. But given
that Checkstyle is not required for the build it's okay to keep the
old version for now. It'll be in the release tarball.
2019-07-18 07:53:39 +02:00
Karsten Loesing
e723c065b7 Bump version to 2.6.2-dev. 2019-05-30 15:21:41 +02:00
Karsten Loesing
3fe5dd322a Prepare for 2.6.2 release. 2019-05-29 17:22:12 +02:00
Karsten Loesing
f8afa3930d Recognize bandwidth files with @type annotation.
Fixes part of #30525.
2019-05-16 15:55:12 +02:00
Karsten Loesing
3693e107a3 Bump version to 2.6.1-dev. 2019-05-13 11:45:17 +02:00
Karsten Loesing
d1d8ec5dca Prepare for 2.6.1 release. 2019-05-03 08:44:52 +02:00
Karsten Loesing
016d49f514 Fix a bug in recognizing bandwidth files.
We're using a regular expression on the first 100 characters of a
descriptor to recognize bandwidth files. More specifically, if a
descriptor starts with ten digits followed by a newline, we parse it
as a bandwidth file. (This is ugly, but the legacy bandwidth file
format doesn't give us much of a choice.)

This regular expression is broken. The regular expression we want is
one that matches the first 100 characters of a descriptor, which ours
didn't do.

More detailed explanation of the code change:

 - We don't need to start the pattern with `^`, because the regular
   expression needs to match the whole string anyway.
 - The `(?s)` part enables the dotall mode: "In dotall mode, the
   expression . matches any character, including a line terminator. By
   default this expression does not match line terminators. Dotall
   mode can also be enabled via the embedded flag expression (?s).
   (The s is a mnemonic for "single-line" mode, which is what this is
   called in Perl.)"
 - We need to end the pattern with `.*` to match any characters
   following the first newline, which also includes newlines due to
   the previously enabled dotall mode.

Fixes #30369.
2019-05-02 20:54:53 +02:00
Karsten Loesing
492ef35d16 Bump version to 2.6.0-dev. 2019-04-29 16:56:57 +02:00
Karsten Loesing
890941af03 Prepare for 2.6.0 release. 2019-04-29 16:09:57 +02:00
Karsten Loesing
25072720b9 Add BandwidthFile for parsed bandwidth files.
Implements #30216.
2019-04-29 14:49:11 +02:00
Karsten Loesing
23927c2777 Stop signing jars.
Implements #28584.
2018-11-28 10:01:20 +01:00
Karsten Loesing
603a439f80 Bump version to 2.5.0-dev. 2018-09-26 17:14:36 +02:00
Karsten Loesing
3ce769b692 Prepare for 2.5.0 release. 2018-09-25 09:24:42 +02:00
Karsten Loesing
7c26323811 Use Map.putIfAbsent and Map.getOrDefault where possible. 2018-08-21 15:05:26 +02:00
Karsten Loesing
4a1c02c61a Inline redundant local variables. 2018-08-21 14:10:29 +02:00
Karsten Loesing
0cb2f05ba4 Replace if with switch. 2018-08-21 12:22:41 +02:00
Karsten Loesing
c9dae38506 Simplify a test case. 2018-08-21 12:20:23 +02:00
Karsten Loesing
a1b07be296 Remove redundant string operation. 2018-08-21 12:07:50 +02:00
Karsten Loesing
25998e1539 Remove unnecessary return statements. 2018-08-21 11:47:45 +02:00
Karsten Loesing
53857805b6 Use parameterized log statements. 2018-08-21 10:45:00 +02:00