Introduce BlazeInterners, a Blaze-specific wrapper around Guava's Interners that makes an appropriate call to Interners.InternerBuilder#concurrencyLevel.
For current readers of this CL, I used this class everywhere in the Blaze codebase.
For future readers of this CL, this class should be used to create an Interner in the Blaze codebase.
--
MOS_MIGRATED_REVID=140063271
diff --git a/src/main/java/com/google/devtools/build/skyframe/SkyKey.java b/src/main/java/com/google/devtools/build/skyframe/SkyKey.java
index f2355e1..0af8b82 100644
--- a/src/main/java/com/google/devtools/build/skyframe/SkyKey.java
+++ b/src/main/java/com/google/devtools/build/skyframe/SkyKey.java
@@ -15,7 +15,7 @@
import com.google.common.base.Function;
import com.google.common.collect.Interner;
-import com.google.common.collect.Interners;
+import com.google.devtools.build.lib.concurrent.BlazeInterners;
import com.google.devtools.build.lib.util.Preconditions;
import java.io.Serializable;
@@ -24,7 +24,7 @@
* A {@link SkyKey} is effectively a pair (type, name) that identifies a Skyframe value.
*/
public final class SkyKey implements Serializable {
- private static final Interner<SkyKey> SKY_KEY_INTERNER = Interners.newWeakInterner();
+ private static final Interner<SkyKey> SKY_KEY_INTERNER = BlazeInterners.newWeakInterner();
private final SkyFunctionName functionName;