flowable/flowable-engine · error · FlowableException

problem retrieving flowable-app-context.xml resources on the

Error message

problem retrieving flowable-app-context.xml resources on the classpath: <java.class.path>

What it means

Same discovery mechanism as the cfg.xml lookup, but for Spring-style flowable-app-context.xml resources: AppEngines.init() calls ClassLoader.getResources("flowable-app-context.xml") and wraps any IOException in this FlowableException with the java.class.path appended. A classpath scanning failure while initializing app engines from Spring resources.

Source

Thrown at modules/flowable-app-engine/src/main/java/org/flowable/app/engine/AppEngines.java:79

            } catch (IOException e) {
                throw new FlowableException("problem retrieving flowable.app.cfg.xml resources on the classpath: " + System.getProperty("java.class.path"), e);
            }

            // Remove duplicated configuration URL's using set. Some
            // classloaders may return identical URL's twice, causing duplicate startups
            Set<URL> configUrls = new HashSet<>();
            while (resources.hasMoreElements()) {
                configUrls.add(resources.nextElement());
            }
            for (URL resource : configUrls) {
                LOGGER.info("Initializing app engine using configuration '{}'", resource);
                initAppEngineFromResource(resource);
            }

            try {
                resources = classLoader.getResources("flowable-app-context.xml");
            } catch (IOException e) {
                throw new FlowableException("problem retrieving flowable-app-context.xml resources on the classpath: " + System.getProperty("java.class.path"), e);
            }

            while (resources.hasMoreElements()) {
                URL resource = resources.nextElement();
                LOGGER.info("Initializing app engine using Spring configuration '{}'", resource);
                initAppEngineFromSpringResource(resource);
            }

            setInitialized(true);
        } else {
            LOGGER.info("App engines already initialized");
        }
    }

    protected static void initAppEngineFromSpringResource(URL resource) {
        try {
            Class<?> springConfigurationHelperClass = ReflectUtil.loadClass("org.flowable.app.spring.SpringAppConfigurationHelper");
            Method method = springConfigurationHelperClass.getDeclaredMethod("buildAppEngine", new Class<?>[] { URL.class });

View on GitHub (pinned to d6d39ce1c6)

Solutions

  1. Fix invalid entries reported in java.class.path in the message.
  2. Inspect the wrapped IOException cause for the real failure.
  3. Initialize the engine programmatically from a Spring configuration instead of relying on flowable-app-context.xml discovery.
  4. Ensure the Spring context files are packaged and reachable by the application classloader.
Defensive patterns

Strategy: try-catch

Validate before calling

Enumeration<URL> urls = Thread.currentThread().getContextClassLoader().getResources("flowable-app-context.xml");
if (!urls.hasMoreElements()) { log.info("No spring app context resources found"); }

Try / catch

try { AppEngines.getAppEngine(); } catch (FlowableException e) {
    log.error("Spring app-context discovery failed: " + e.getMessage(), e);
}

Prevention

When it happens

Trigger: AppEngines.getAppEngine()/init() when enumerating flowable-app-context.xml resources via the classloader throws IOException.

Common situations: Application-server classloader quirks, broken classpath entries, or filesystem errors during resource enumeration when using Spring context auto-discovery of the app engine.

Related errors


AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11). Data as JSON: /api/errors/5d4595d11b8e52e3. Report an issue: GitHub.