{"record":{"id":"d78a8b502d11b907","repo":"hasura/graphql-engine","slug":"data-connector-data-connector-name-is-referenced","errorCode":null,"errorMessage":"Data connector {data_connector_name} is referenced by multiple {plugin_type} plugins: {plugin_name_a} and {plugin_name_b}","messagePattern":"Data connector (.+?) is referenced by multiple (.+?) plugins: (.+?) and (.+?)","errorType":"validation","errorClass":"PluginValidationError","httpStatus":null,"severity":"error","filePath":"v3/crates/metadata-resolve/src/stages/plugins/error.rs","lineNumber":12,"sourceCode":"use crate::Qualified;\nuse open_dds::data_connector::DataConnectorName;\nuse open_dds::plugins::LifecyclePluginName;\n\n#[derive(Debug, thiserror::Error)]\npub enum PluginValidationError {\n    #[error(\"Plugin {plugin_name} references unknown data connector {data_connector_name}\")]\n    UnknownDataConnector {\n        plugin_name: Qualified<LifecyclePluginName>,\n        data_connector_name: Qualified<DataConnectorName>,\n    },\n    #[error(\n        \"Data connector {data_connector_name} is referenced by multiple {plugin_type} plugins: {plugin_name_a} and {plugin_name_b}\"\n    )]\n    DuplicatePluginForDataConnector {\n        plugin_type: String,\n        data_connector_name: Qualified<DataConnectorName>,\n        plugin_name_a: Qualified<LifecyclePluginName>,\n        plugin_name_b: Qualified<LifecyclePluginName>,\n    },\n    #[error(\"Plugin {plugin_name} is defined more than once\")]\n    DuplicatePluginName {\n        plugin_name: Qualified<LifecyclePluginName>,\n    },\n}\n","sourceCodeStart":1,"sourceCodeEnd":26,"githubUrl":"https://github.com/hasura/graphql-engine/blob/724551b9ae87845594ef0408cff0e50eb6c90dc5/v3/crates/metadata-resolve/src/stages/plugins/error.rs#L1-L26","documentation":"Thrown when two lifecycle plugins of the same type (e.g. two read-time or write-time plugins) reference the same data connector. Only one plugin of a given type may be attached to a data connector.","triggerScenarios":"Defining two plugins with the same plugin type whose data_connector_name resolves to the same connector; detected during the plugins validation stage.","commonSituations":"Adding a new plugin for a connector that already has one of the same type; copy-pasting a plugin config and changing only the name; merging plugin definitions from multiple files/subgraphs that target the same connector.","solutions":["Identify the two conflicting plugins named in the error (plugin_name_a and plugin_name_b)","Decide which one should own the connector for that plugin type and delete or re-target the other","If both are needed, point one at a different data connector or combine their logic into a single plugin"],"exampleFix":"# before\nplugins:\n  - name: pluginA\n    type: readTime\n    data_connector: postgres_main\n  - name: pluginB\n    type: readTime\n    data_connector: postgres_main\n# after\nplugins:\n  - name: pluginA\n    type: readTime\n    data_connector: postgres_main","handlingStrategy":"validation","validationCode":"const byConnectorType = new Map();\nfor (const p of plugins) {\n  const key = `${p.type}::${p.data_connector}`;\n  if (byConnectorType.has(key)) throw new Error(`conflict: ${key}`);\n  byConnectorType.set(key, p);\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Maintain one plugin per (type, connector) pair by convention","Lint for connector/type collisions in CI"],"tags":["metadata","plugins","duplicate","data-connector","open-dds"],"backgroundTag":"duplicate-plugin-configuration","analyzedSha":"724551b9ae87845594ef0408cff0e50eb6c90dc5","analyzedAt":"2026-08-28T07:32:55.105Z","schemaVersion":2},"datasetVersion":"2026-08-28T11:17:15.048Z"}