apache/beam · error · UnsupportedOperationException
Given plugin class ' ' is not supported!
Error message
Given plugin class '%s' is not supported!
What it means
MappingUtils.getPluginByClass() maps a CDAP plugin class to the corresponding Hadoop Input/OutputFormat and format providers. If the plugin class is not in its known list (e.g. unsupported sink/source), it throws UnsupportedOperationException.
Solutions
- Use one of the plugin classes supported by MappingUtils.
- Add a mapping branch for your plugin class (implement InputFormatProvider/OutputFormatProvider and corresponding format class).
- Upgrade the Beam CDAP connector to a version supporting the plugin.
Example fix
// before CdapIO.<String, String>read().withPluginClass(MyCustomSource.class) // after: use a supported plugin CdapIO.<String, String>read().withPluginClass(SalesforceSource.class)
Defensive patterns
Strategy: validation
Validate before calling
List<Class<?>> supported = List.of(SalesforceSource.class, ServiceNowSource.class /* ... */);
if (!supported.contains(pluginClass)) throw new IllegalArgumentException("Unsupported plugin class: " + pluginClass.getName()); Try / catch
try { pipeline.run().waitUntilFinish(); } catch (UnsupportedOperationException e) { if (e.getMessage().contains("not supported")) { /* use supported plugin */ } throw e; } Prevention
- Only use plugin classes listed in MappingUtils.
- Check the connector version's supported-plugin list.
- Contribute mappings for new plugins.
When it happens
Trigger: Passing a pluginClass to CdapIO.read()/write() that MappingUtils does not recognize (not among the supported CDAP plugins like Salesforce, ServiceNow, etc.).
Common situations: Using a newer/custom CDAP plugin not yet mapped in the Beam CDAP connector; typo in plugin class; version mismatch between CDAP plugins and the connector.
Related errors
- Can not call prepareRun
- Could not get value Coder
- Error while prepareRun
- Support for unbounded plugins is not implemented!
- A function must be provided to convert the input type into…
AI-assisted analysis of apache/beam@12126d8942 (2026-09-13).
Data as JSON: /api/errors/96442248ad7039e1.
Report an issue: GitHub.
Appendix: source
Thrown at sdks/java/io/cdap/src/main/java/org/apache/beam/sdk/io/cdap/MappingUtils.java:64
return Plugin.createBatch(
pluginClass, SalesforceInputFormat.class, SalesforceInputFormatProvider.class);
} else if (pluginClass.equals(HubspotBatchSource.class)) {
return Plugin.createBatch(
pluginClass, HubspotInputFormat.class, HubspotInputFormatProvider.class);
} else if (pluginClass.equals(ZendeskBatchSource.class)) {
return Plugin.createBatch(
pluginClass, ZendeskInputFormat.class, ZendeskInputFormatProvider.class);
} else if (pluginClass.equals(HubspotBatchSink.class)) {
return Plugin.createBatch(
pluginClass, HubspotOutputFormat.class, SourceInputFormatProvider.class);
} else if (pluginClass.equals(SalesforceBatchSink.class)) {
return Plugin.createBatch(
pluginClass, SalesforceOutputFormat.class, SalesforceInputFormatProvider.class);
} else if (pluginClass.equals(ServiceNowSource.class)) {
return Plugin.createBatch(
pluginClass, ServiceNowInputFormat.class, SourceInputFormatProvider.class);
}
throw new UnsupportedOperationException(
String.format("Given plugin class '%s' is not supported!", pluginClass.getName()));
}
}
View on GitHub (pinned to 12126d8942)