{"record":{"id":"a7c227eea7b9ab88","repo":"pentaho/pentaho-kettle","slug":"no-factory-found-for-managerclass","errorCode":null,"errorMessage":"No Factory found for <managerClass>","messagePattern":"No Factory found for <managerClass>","errorType":"exception","errorClass":"KettleException","httpStatus":null,"severity":"error","filePath":"core/src/main/java/org/pentaho/di/core/bowl/BaseBowl.java","lineNumber":39,"sourceCode":"\npublic abstract class BaseBowl implements Bowl {\n\n  private final Map<Class<?>, Object> managerInstances = new ConcurrentHashMap<>();\n  private final Set<Bowl> parentBowls = ConcurrentHashMap.newKeySet();\n\n  @Override\n  public <T> T getManager( Class<T> managerClass ) throws KettleException {\n    // can't use computeIfAbsent here because we want exceptions to propagate. :(\n    T result = managerClass.cast( managerInstances.get( managerClass ) );\n    if ( result != null ) {\n      return result;\n    }\n    synchronized ( this ) {\n      result = managerClass.cast( managerInstances.get( managerClass ) );\n      if ( result == null ) {\n        ManagerFactory<T> factory = BowlManagerFactoryRegistry.getInstance().getManagerFactory( managerClass );\n        if ( factory == null ) {\n          throw new KettleException( \"No Factory found for \" + managerClass );\n        }\n        result = factory.apply( this );\n        if ( result == null ) {\n          throw new KettleException( \"Unable to create manager for \" + managerClass );\n        }\n        managerInstances.put( managerClass, result );\n      }\n      return result;\n    }\n  }\n\n  @Override\n  public Set<Bowl> getParentBowls() {\n    return parentBowls;\n  }\n\n  public void addParentBowl( Bowl parent ) {\n    parentBowls.add( parent );","sourceCodeStart":21,"sourceCodeEnd":57,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/core/src/main/java/org/pentaho/di/core/bowl/BaseBowl.java#L21-L57","documentation":"BaseBowl.getManager() lazily creates manager instances by looking up a ManagerFactory in the BowlManagerFactoryRegistry. If no factory is registered for the requested manager class, it throws this KettleException. This means the manager type was never registered with the registry (typically at plugin or environment initialization).","triggerScenarios":"Calling bowl.getManager(SomeManager.class) where SomeManager's factory was never registered via BowlManagerFactoryRegistry — e.g. the responsible plugin isn't loaded, or registration code didn't run before the lookup.","commonSituations":"Using a bowl in a standalone/embedded Kettle context where plugin lifecycle/registration never ran; ordering bugs where getManager is called before factory registration; missing plugin JAR on the classpath; version changes in manager classes.","solutions":["Ensure the plugin/initializer that calls BowlManagerFactoryRegistry.getInstance().register(...) runs before getManager","Verify the plugin JAR providing the manager factory is on the classpath / installed","Initialize the Kettle environment (e.g. KettleEnvironment.init()) before using bowls","Catch KettleException and fall back to a default manager or report a clear config error"],"exampleFix":"// before\nBowl bowl = ...;\nbowl.getManager(MyManager.class); // factory never registered\n// after\nBowlManagerFactoryRegistry.getInstance().register(MyManager.class, new MyManagerFactory());\nbowl.getManager(MyManager.class);","handlingStrategy":"try-catch","validationCode":"ManagerFactory<MyManager> f = BowlManagerFactoryRegistry.getInstance().getManagerFactory(MyManager.class);\nif (f == null) {\n  throw new IllegalStateException(\"MyManager factory not registered; ensure the owning plugin is loaded\");\n}","typeGuard":null,"tryCatchPattern":"try {\n  MyManager m = bowl.getManager(MyManager.class);\n} catch (KettleException e) {\n  if (e.getMessage().startsWith(\"No Factory found\")) {\n    log.error(\"Manager factory missing — plugin not registered/loaded: \" + e.getMessage(), e);\n  } else throw e;\n}","preventionTips":["Initialize KettleEnvironment (and plugin registry) before calling getManager","Verify the plugin providing the factory is installed/on the classpath","Register factories early in application bootstrap, before any bowl usage","Document which manager classes require which plugins"],"tags":["kettle","bowl","manager","missing-registration"],"backgroundTag":"missing-dependency","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"}