apache/cassandra · error · ConfigurationException

Multiple sstable format implementations with the same name %

Error message

Multiple sstable format implementations with the same name %s: %s and %s

What it means

During DatabaseDescriptor's static sstable-format registration, each SSTableFormat.Factory is registered by its lowercase name in a map; if two factories declare the same name, the second registration finds a previous entry and throws this ConfigurationException. It exists to keep the sstable format registry unambiguous, since format names are used in config and sstable metadata to select implementations.

Source

Thrown at src/java/org/apache/cassandra/config/DatabaseDescriptor.java:1938

        {
            throw new ConfigurationException("commitlog_disk_access_mode = " + accessModeDirectIoPair.left + " is not supported. Please use 'auto' when unsure.", false);
        }
    }

    private static void validateSSTableFormatFactories(Iterable<SSTableFormat.Factory> factories)
    {
        Map<String, SSTableFormat.Factory> factoryByName = new HashMap<>();
        for (SSTableFormat.Factory factory : factories)
        {
            if (factory.name() == null)
                throw new ConfigurationException(String.format("SSTable format name in %s cannot be null", factory.getClass().getCanonicalName()));

            if (!factory.name().matches("^[a-z]+$"))
                throw new ConfigurationException(String.format("SSTable format name for %s must be non-empty, lower-case letters only string", factory.getClass().getCanonicalName()));

            SSTableFormat.Factory prev = factoryByName.put(factory.name(), factory);
            if (prev != null)
                throw new ConfigurationException(String.format("Multiple sstable format implementations with the same name %s: %s and %s", factory.name(), factory.getClass().getCanonicalName(), prev.getClass().getCanonicalName()));
        }
    }

    private static ImmutableMap<String, Supplier<SSTableFormat<?, ?>>> validateAndMatchSSTableFormatOptions(Iterable<SSTableFormat.Factory> factories, Map<String, Map<String, String>> options)
    {
        ImmutableMap.Builder<String, Supplier<SSTableFormat<?, ?>>> providersBuilder = ImmutableMap.builder();
        if (options == null)
            options = ImmutableMap.of();
        for (SSTableFormat.Factory factory : factories)
        {
            Map<String, String> formatOptions = options.getOrDefault(factory.name(), ImmutableMap.of());
            providersBuilder.put(factory.name(), () -> factory.getInstance(ImmutableMap.copyOf(formatOptions)));
        }
        ImmutableMap<String, Supplier<SSTableFormat<?, ?>>> providers = providersBuilder.build();
        if (options != null)
        {
            Sets.SetView<String> unknownFormatNames = Sets.difference(options.keySet(), providers.keySet());
            if (!unknownFormatNames.isEmpty())

View on GitHub (pinned to 88fd0f6a0e)

Solutions

  1. Rename your custom format's name() (NAME constant) to a unique lowercase string not used by any other registered format
  2. Check the classpath for duplicate format-provider jars and remove the stale one
  3. If the collision is with a built-in format, do not register a factory with name 'big' or 'bti'; extend or configure the existing one instead

Example fix

// before
public static final String NAME = "big"; // collides with built-in BigFormat
// after
public static final String NAME = "mycustom";
Defensive patterns

Strategy: validation

Validate before calling

Set<String> names = new HashSet<>();
for (SSTableFormat.Factory f : myFactories) {
    if (!names.add(f.name()))
        throw new IllegalStateException("Duplicate sstable format name: " + f.name());
}

Try / catch

try { DatabaseDescriptor.daemonInitialization(); }
catch (ConfigurationException e) {
    if (e.getMessage().startsWith("Multiple sstable format implementations"))
        log.error("Format name collision: {}", e.getMessage());
}

Prevention

When it happens

Trigger: Registering (via the applySSTableFormats registration loop) two format factories whose name() returns the same string, e.g. a custom format named 'big' or a classpath containing two third-party format providers with clashing names.

Common situations: Shipping a custom SSTableFormat whose name collides with a built-in (big, bti) or with another plugin on the classpath; copy-pasting a format implementation and forgetting to change its NAME; duplicate jars of the same format library on the classpath.

Understand the failure class

Background: Conflicting config options: "cannot be used together" — configuration validation errors across open-source libraries — this error's family across 162 libraries.

Related errors


AI-assisted analysis of apache/cassandra@88fd0f6a0e (2026-09-10). Data as JSON: /api/errors/9f834a49089c5256. Report an issue: GitHub.