apache/druid · error · IAE

Input source type is not registered

Error message

Input source type %s is not registered

What it means

After reading the input source's type property, resolve() looks it up in the TableDefnRegistry. If no input source definition is registered under that type name, the table cannot be validated or converted, so this IAE reports the unregistered type value.

Solutions

  1. Fix the type string to a registered value (e.g. "local", "http", "s3")
  2. Load the Druid extension that registers the input source type
  3. Register a custom InputSourceDefn in the TableDefnRegistry if using a custom input source

Example fix

// before
"source":{"type":"loca","baseDir":"/data"}
// after
"source":{"type":"local","baseDir":"/data"}
Defensive patterns

Strategy: validation

Validate before calling

// Java
String type = (String) sourceMap.get("type");
if (type != null && registry.inputSourceDefnFor(type) == null)
  throw new IllegalArgumentException("input source type not registered: " + type);

Type guard

// Java
static boolean isKnownSourceType(TableDefnRegistry registry, Map<String,Object> sourceMap) {
  Object t = sourceMap.get("type");
  return t instanceof String && registry.inputSourceDefnFor((String) t) != null;
}

Try / catch

try { resolved.resolve(registry); } catch (IAE e) { if (e.getMessage().contains("is not registered")) { /* load the extension or fix the type name */ } else throw e; }

Prevention

When it happens

Trigger: Setting source.type to a type string the registry doesn't know — typos like "loca", extension input sources (e.g. "s3", "kafka") when the providing extension module isn't loaded/registered in the catalog's registry.

Common situations: Typos in type names; using extension input sources without the extension loaded into the Druid process; running against a trimmed registry (tests/embedded mode) missing extensions.

Understand the failure class

Background: Invalid enum value errors: "Unknown type", "Invalid scope", "must be one of" — when a string is not on the library's allowed list — this error's family across 23 libraries.

Related errors


AI-assisted analysis of apache/druid@9b90983fd2 (2026-09-07). Data as JSON: /api/errors/3ad990efce167ab5. Report an issue: GitHub.

Appendix: source

Thrown at server/src/main/java/org/apache/druid/catalog/model/table/ResolvedExternalTable.java:90

  }

  /**
   * Look up the input source type and input format type to find the corresponding
   * definitions in the table registry. Throws an exception if the types are not
   * defined. The input source is required, the format is optional.
   * <p>
   * Note, for resolution to work, the name of each definition must be the same as
   * that used as the type key in the serialized JSON.
   */
  public ResolvedExternalTable resolve(TableDefnRegistry registry)
  {
    String inputSourceType = CatalogUtils.getString(inputSourceMap, InputSource.TYPE_PROPERTY);
    if (inputSourceType == null) {
      throw new IAE("Input source type %s is required", InputSource.TYPE_PROPERTY);
    }
    inputSourceDefn = registry.inputSourceDefnFor(inputSourceType);
    if (inputSourceDefn == null) {
      throw new IAE("Input source type %s is not registered", inputSourceType);
    }
    if (inputFormatMap != null) {
      String inputFormatType = CatalogUtils.getString(inputFormatMap, InputFormat.TYPE_PROPERTY);
      if (inputFormatType != null) {
        inputFormatDefn = registry.inputFormatDefnFor(inputFormatType);
        if (inputFormatDefn == null) {
          throw new IAE("Input format type %s is not registered", inputFormatType);
        }
      }
    }
    return this;
  }

  /**
   * Validate that the table spec is correct by resolving the definitions, then
   * converting the JSON to the desired object type. Note that this path requires
   * special handling: the table spec may be partial, which means it is missing information
   * needed to create a complete input source. The input source definition defines which

View on GitHub (pinned to 9b90983fd2)