risingwavelabs/risingwave · error · ConnectorError
No allow_alter_on_fly fields registered for connector
Error message
No allow_alter_on_fly fields registered for connector: {connector_name} What it means
Raised when the connector name resolves to a known source type but SOURCE_ALLOW_ALTER_ON_FLY_FIELDS has no entry for it, meaning no fields have been registered as alterable on the fly for that source connector.
Solutions
- Re-run the code generation that populates SOURCE_ALLOW_ALTER_ON_FLY_FIELDS (generate_allow_alter_on_fly_fields_combined / build step).
- If the connector genuinely supports no on-the-fly field alterations, do not call this validation for it (guard on registration first).
- Add an allow_alter_on_fly field list for the connector in the source definition and regenerate.
Example fix
// before
check_source_allow_alter_on_fly_fields(connector, fields)?;
// after
if source_properties::source_name_to_prop_type_name(connector).and_then(|t| SOURCE_ALLOW_ALTER_ON_FLY_FIELDS.get(t)).is_some() {
check_source_allow_alter_on_fly_fields(connector, fields)?;
} Defensive patterns
Strategy: type-guard
Validate before calling
fn source_has_alter_fields(connector: &str) -> bool {
source_properties::source_name_to_prop_type_name(connector)
.and_then(|t| SOURCE_ALLOW_ALTER_ON_FLY_FIELDS.get(t))
.is_some()
} Try / catch
if let Err(e) = check_source_allow_alter_on_fly_fields(connector, &fields) {
log::warn!("skipping on-the-fly alteration check: {e}");
} Prevention
- Re-run code generation after adding or renaming any source connector
- Never hand-edit generated registry maps
- Add a unit test asserting every registered connector has an allow-list entry
When it happens
Trigger: Calling check_source_allow_alter_on_fly_fields with a valid connector name whose allow-alter-on-fly field list was never generated/registered (the generator did not run or the connector has no eligible fields).
Common situations: Hand-editing a new connector without re-running the code generator; connector exists but intentionally (or mistakenly) has no allow_alter_on_fly registry entry; stale build where generated code is outdated.
Understand the failure class
Background: "is required", "must be set", "missing required field": configuration validation errors across open-source libraries — this error's family across 36 libraries.
Related errors
- No allow_alter_on_fly fields registered for connection
- No allow_alter_on_fly fields registered for sink
- {0}
- additional column is not supported for connector
- additional column type
AI-assisted analysis of risingwavelabs/risingwave@6469eb736d (2026-09-11).
Data as JSON: /api/errors/e3fa907d00408f9b.
Report an issue: GitHub.
Appendix: source
Thrown at src/connector/src/with_options_test.rs:801
/// Get all connection names that have `allow_alter_on_fly` fields
pub fn get_connection_names_with_allow_alter_on_fly_fields() -> Vec<&'static str> {{
CONNECTION_ALLOW_ALTER_ON_FLY_FIELDS.keys().map(|s| s.as_str()).collect()
}}
/// Checks if all given fields are allowed to be altered on the fly for the specified source connector.
/// Returns Ok(()) if all fields are allowed, otherwise returns a `ConnectorError`.
pub fn check_source_allow_alter_on_fly_fields(
connector_name: &str,
fields: &[String],
) -> crate::error::ConnectorResult<()> {{
// Convert connector name to the type name key
let Some(type_name) = source_properties::source_name_to_prop_type_name(connector_name) else {{
return Err(ConnectorError::from(anyhow::anyhow!(
"Unknown source connector: {{connector_name}}"
)));
}};
let Some(allowed_fields) = SOURCE_ALLOW_ALTER_ON_FLY_FIELDS.get(type_name) else {{
return Err(ConnectorError::from(anyhow::anyhow!(
"No allow_alter_on_fly fields registered for connector: {{connector_name}}"
)));
}};
for field in fields {{
if !allowed_fields.contains(field) {{
return Err(ConnectorError::from(anyhow::anyhow!(
"Field '{{field}}' is not allowed to be altered on the fly for connector: {{connector_name}}"
)));
}}
}}
Ok(())
}}
pub fn check_connection_allow_alter_on_fly_fields(
connection_name: &str,
fields: &[String],
) -> crate::error::ConnectorResult<()> {{
use crate::source::connection_name_to_prop_type_name;View on GitHub (pinned to 6469eb736d)