public static void resetGlobalInstanceTestOnly() {
    GLOBAL_INSTANCE.keyManagerMap = new ConcurrentHashMap<>();
    GLOBAL_INSTANCE.newKeyAllowedMap = new ConcurrentHashMap<>();
  }
Resets the global instance. Should only be used in tests. Not thread safe.
java_src/src/main/java/com/google/crypto/tink/internal/KeyManagerRegistry.java