Reduce default Multiplexer impact on ReferenceIndex
*/
package org.apache.jackrabbit.oak.plugins.index.property;
-import static com.google.common.collect.Sets.newHashSet;
import static org.apache.jackrabbit.oak.plugins.index.IndexConstants.INDEX_CONTENT_NODE_NAME;
import java.util.HashSet;
@@ -35,6 +34,7 @@ import org.apache.jackrabbit.oak.spi.state.NodeState;
import org.apache.jackrabbit.oak.spi.state.NodeStateUtils;
import com.google.common.base.Predicate;
+import com.google.common.collect.ImmutableSet;
public class Multiplexers {
@@ -101,8 +101,8 @@ public class Multiplexers {
strategies.add(newStrategy(unique, true, defaultName, defMount));
return strategies;
} else {
- return unique ? newHashSet(newUniqueStrategy(defaultName))
- : newHashSet(newMirrorStrategy(defaultName));
+ return unique ? ImmutableSet.of(newUniqueStrategy(defaultName))
+ : ImmutableSet.of(newMirrorStrategy(defaultName));
}
}
