Package org.torproject.descriptor
Interface BridgedbMetrics
-
- All Superinterfaces:
Descriptor,java.io.Serializable
public interface BridgedbMetrics extends Descriptor
Contains aggregated information about requests to the BridgeDB service.- Since:
- 2.8.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Optional<java.util.Map<java.lang.String,java.lang.Long>>bridgedbMetricCounts()Return approximate request numbers to the BridgeDB service in the measurement interval broken down by distribution mechanism, obfuscation protocol, and country code.java.time.LocalDateTimebridgedbMetricsEnd()Return the end of the included measurement interval.java.time.DurationbridgedbMetricsIntervalLength()Return the length of the included measurement interval.java.lang.StringbridgedbMetricsVersion()Return the BridgeDB metrics format version.-
Methods inherited from interface org.torproject.descriptor.Descriptor
getAnnotations, getDescriptorFile, getRawDescriptorBytes, getRawDescriptorLength, getUnrecognizedLines
-
-
-
-
Method Detail
-
bridgedbMetricsEnd
java.time.LocalDateTime bridgedbMetricsEnd()
Return the end of the included measurement interval.- Returns:
- End of the included measurement interval.
- Since:
- 2.8.0
-
bridgedbMetricsIntervalLength
java.time.Duration bridgedbMetricsIntervalLength()
Return the length of the included measurement interval.- Returns:
- Length of the included measurement interval.
- Since:
- 2.8.0
-
bridgedbMetricsVersion
java.lang.String bridgedbMetricsVersion()
Return the BridgeDB metrics format version.- Returns:
- BridgeDB metrics format version.
- Since:
- 2.8.0
-
bridgedbMetricCounts
java.util.Optional<java.util.Map<java.lang.String,java.lang.Long>> bridgedbMetricCounts()
Return approximate request numbers to the BridgeDB service in the measurement interval broken down by distribution mechanism, obfuscation protocol, and country code.Keys are formatted as
DIST.PROTO.CC/EMAIL.[success|fail].nonewhere:DISTis BridgeDB's distribution mechanism, for example,http,email, ormoat;PROTOis the obfuscation protocol, for example,obfs2,obfs3,obfs4,scramblesuit, orfte;CC/EMAILis either a two-letter country code or an email provider;- the second-to-last field is either
successorfaildepending on if the BridgeDB request succeeded or not; and - the last field is reserved for an anomaly score to be added in the future.
Values are approximate request numbers, rounded up to the next multiple of 10.
- Returns:
- Map of approximate request numbers.
- Since:
- 2.8.0
-
-