elastic/elasticsearch · error · NoSuchAlgorithmException
supports only [{}] as method
Error message
supports only [{}] as method What it means
Thrown by FingerprintProcessor.MurmurHasher.getInstance when the requested hash method does not equal Murmur3Hasher.METHOD. MurmurHasher is a delegating wrapper that ONLY supports the Murmur3 method string, so any other algorithm name is rejected at factory time. This is a NoSuchAlgorithmException, surfaced as a configuration error in the fingerprint processor.
Source
Thrown at modules/ingest-common/src/main/java/org/elasticsearch/ingest/common/FingerprintProcessor.java:330
@Override
public String getAlgorithm() {
return md.getAlgorithm();
}
}
static class MurmurHasher implements Hasher {
public static final String METHOD = Murmur3Hasher.METHOD;
private final Murmur3Hasher mh;
private MurmurHasher() {
this.mh = new Murmur3Hasher(0);
}
static Hasher getInstance(String method) throws NoSuchAlgorithmException {
if (method.equalsIgnoreCase(METHOD) == false) {
throw new NoSuchAlgorithmException("supports only [" + METHOD + "] as method");
}
return new MurmurHasher();
}
@Override
public void reset() {
mh.reset();
}
@Override
public void update(byte[] input) {
mh.update(input);
}
@Override
public byte[] digest() {
return mh.digest();
}View on GitHub (pinned to db6a809a66)
Solutions
- Set the fingerprint processor method to exactly the Murmur3 method constant (the value of Murmur3Hasher.METHOD, typically "Murmur3") when you want MurmurHasher.
- If you need SHA-family hashing, ensure the factory selects DigestHasher with a supported algorithm (e.g. "SHA-256") instead of MurmurHasher.
- Check the ingest processor definition in your pipeline for typos in the method field.
Example fix
// before
{"fingerprint": {"fields": ["ip"], "method": "murmur"}}
// after
{"fingerprint": {"fields": ["ip"], "method": "Murmur3"}} Defensive patterns
Strategy: validation
Validate before calling
// before constructing MurmurHasher, validate the method string
String method = config.get("method");
if ("Murmur3".equalsIgnoreCase(method) == false
&& Arrays.asList("SHA-1","SHA-256","SHA-512","MD5").contains(method) == false) {
throw new IllegalArgumentException("Unsupported fingerprint method: " + method);
}
// only then call FingerprintProcessor.Factory.create Type guard
static boolean isSupportedFingerprintMethod(String m) {
if (m == null) return false;
return "Murmur3".equalsIgnoreCase(m)
|| java.util.Arrays.asList("SHA-1","SHA-256","SHA-512","MD5").contains(m);
} Try / catch
try {
Hasher h = MurmurHasher.getInstance(method);
} catch (NoSuchAlgorithmException e) {
// surface to pipeline validation: unsupported method
throw new IllegalArgumentException("Fingerprint method [" + method + "] not supported", e);
} Prevention
- Validate the fingerprint method against the supported set in pipeline create-time validation.
- Document only the canonical method strings (Murmur3, SHA-1, SHA-256, SHA-512, MD5) in user docs.
- Add an integration test that asserts each supported method string produces a working processor.
When it happens
Trigger: Configuring a fingerprint processor with method set to anything other than the Murmur3 constant (e.g. "sha256", "md5", or a typo) and the factory routes to MurmurHasher instead of the SHA-based DigestHasher. The check is method.equalsIgnoreCase(METHOD) == false.
Common situations: User sets "method": "murmur3" vs "MURMUR3" casing issues are tolerated (equalsIgnoreCase), but "murmur" or "sha1" routed wrong, or a custom/older documented method name that the version no longer maps to MurmurHasher.
Related errors
- unsupported ECS compatibility mode [{}]
- field [{}] is null, cannot loop over its elements.
- field [{}] is null, cannot process it.
- unsupported ECS compatibility mode [{}]
- field [{}] is null, cannot join.
AI-assisted analysis of elastic/elasticsearch@db6a809a66 (2026-08-12).
Data as JSON: /api/errors/8ec605c067f3939c.
Report an issue: GitHub.