{"record":{"id":"a203d5c17118e38d","repo":"pentaho/pentaho-kettle","slug":"connectionmanagementservicemeta-is-a-placeholder-and-should","errorCode":null,"errorMessage":"ConnectionManagementServiceMeta is a placeholder and should not be used directly.","messagePattern":"ConnectionManagementServiceMeta is a placeholder and should not be used directly\\.","errorType":"exception","errorClass":"NotImplementedException","httpStatus":null,"severity":"error","filePath":"core/src/main/java/org/pentaho/di/core/database/ConnectionManagementServiceMeta.java","lineNumber":34,"sourceCode":"\nimport org.apache.commons.lang3.NotImplementedException;\n\n/**\n * Acts as a placeholder for the Connection Management Service connection, which is not a real database, but needs to be\n * acting as one in the internal flow.\n * <p>\n * Internally contains an instance of a real database and proxies all calls to it after it's data is fetched from the\n * connection management service.\n */\npublic class ConnectionManagementServiceMeta extends BaseDatabaseMeta implements DatabaseInterface {\n\n  private static final String NOT_IMPLEMENTED_MESSAGE =\n    \"ConnectionManagementServiceMeta is a placeholder and should not be used directly.\";\n\n  @Override\n  public String getFieldDefinition( ValueMetaInterface v, String tk, String pk, boolean useAutoinc,\n                                    boolean addFieldName, boolean addCr ) {\n    throw new NotImplementedException( NOT_IMPLEMENTED_MESSAGE );\n  }\n\n  @Override\n  public int[] getAccessTypeList() {\n    return new int[ 0 ];\n  }\n\n  @Override\n  public String getDriverClass() {\n    throw new NotImplementedException( NOT_IMPLEMENTED_MESSAGE );\n  }\n\n  @Override\n  public String getURL( String hostname, String port, String databaseName ) throws KettleDatabaseException {\n    throw new NotImplementedException( NOT_IMPLEMENTED_MESSAGE );\n  }\n\n  @Override","sourceCodeStart":16,"sourceCodeEnd":52,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/core/src/main/java/org/pentaho/di/core/database/ConnectionManagementServiceMeta.java#L16-L52","documentation":"ConnectionManagementServiceMeta is a deliberately non-functional placeholder DatabaseMeta implementation; getFieldDefinition always throws NotImplementedException to make accidental use fail fast. It defines no real SQL dialect behavior.","triggerScenarios":"Any code path invokes getFieldDefinition(ValueMetaInterface, tk, pk, useAutoinc, addFieldName, addCr) on a ConnectionManagementServiceMeta instance — e.g. it was registered as or substituted for the actual database dialect when generating field DDL.","commonSituations":"Plugin/dialect misconfiguration that selects the placeholder meta class as the active database; copy-pasting this placeholder as a template for a new dialect without implementing methods; reflective lookup returning the placeholder.","solutions":["Select/configure the real database dialect for the connection instead of ConnectionManagementServiceMeta","If you intended a new dialect, implement getFieldDefinition (and all other DatabaseMeta methods) in a subclass with a distinct name","Check how the DatabaseMeta for this connection is resolved and why the placeholder instance got returned"],"exampleFix":"// before\nDatabaseMeta meta = new DatabaseMeta(); meta.setDatabaseInterface( new ConnectionManagementServiceMeta() );\n// after\nDatabaseMeta meta = new DatabaseMeta(); meta.setDatabaseInterface( new PostgresDatabaseMeta() );","handlingStrategy":"type-guard","validationCode":"// Reject the placeholder before generating field DDL\nif ( dialect instanceof ConnectionManagementServiceMeta ) {\n  throw new IllegalStateException( \"Placeholder dialect selected; configure a real database type\" );\n}","typeGuard":"boolean isPlaceholderDialect( DatabaseInterface di ) { return di instanceof ConnectionManagementServiceMeta; }","tryCatchPattern":"try { String ddl = dialect.getFieldDefinition( v, tk, pk, false, true, true ); } catch ( NotImplementedException e ) { log.error( \"Placeholder dialect in use; fix database type selection\", e ); throw new IllegalStateException( e ); }","preventionTips":["Never instantiate ConnectionManagementServiceMeta directly; it is a marker only","Verify the connection's database type resolves to a concrete dialect before DDL operations","If subclassing the placeholder as a template, override every throwing method","Add an assertion/config check that the active dialect is not the placeholder"],"tags":["placeholder","not-implemented","database-dialect"],"backgroundTag":"method-not-implemented","analyzedSha":"f3058517a153da500bf4551f46d79b91bf8ec552","analyzedAt":"2026-09-13T14:04:16.340Z","contentChangedAt":"2026-09-13T14:04:16.340Z","schemaVersion":2},"datasetVersion":"2026-09-20T23:17:15.980Z"}