apache/skywalking · critical · IllegalStateException
LogAnalyzerModule Factory unavailable for LAL compile of {so
Error message
LogAnalyzerModule Factory unavailable for LAL compile of {sourceName} What it means
LalRuleEngine.compile throws IllegalStateException when resolveApplier() cannot obtain the LogAnalyzerModule Factory needed to build a LalFileApplier. The runtime-rule engine depends on the log-analyzer module being booted (its Factory is looked up through the module manager); a null result means LogAnalyzerModule is absent or not yet started in this OAP instance. This is a module-dependency wiring error on the node handling the rule compile, surfaced per-file rather than at boot.
Source
Thrown at oap-server/server-admin/runtime-rule/src/main/java/org/apache/skywalking/oap/server/receiver/runtimerule/engine/lal/LalRuleEngine.java:305
* bundle's keys it overwrote are gone — non-overlapping old keys keep serving until
* commit removes them. The orchestrator runs the cross-file ownership guard before
* calling this; the engine assumes the planned key set is conflict-free.
*
* <p>Throws {@link RuntimeException} wrapping {@link LalFileApplier.ApplyException} on
* compile / register failure; the orchestrator catches and routes to {@link #rollback}.
*/
@Override
public CompiledDSL compile(final RuntimeRuleManagementDAO.RuntimeRuleFile file,
final Classification classification,
final DSLClassLoaderManager.Kind kind,
final LalApplyContext ctx) {
final String key = DSLScriptKey.key(file.getCatalog(), file.getName());
final String sourceName = file.getCatalog() + "/" + file.getName();
final String newHash = ContentHash
.sha256Hex(file.getContent());
final LalFileApplier lalApplier = resolveApplier();
if (lalApplier == null) {
throw new IllegalStateException(
"LogAnalyzerModule Factory unavailable for LAL compile of " + sourceName);
}
final LalFileApplier.Applied oldApplied = appliedFor(ctx.getRules(), key);
try {
final LalFileApplier.Applied newApplied = lalApplier.apply(
file.getContent(), sourceName, newHash, kind);
return new CompiledLalDSL(file.getCatalog(), file.getName(), newHash, classification,
file.getContent(), oldApplied, newApplied);
} catch (final LalFileApplier.ApplyException ae) {
// Engine-internal partial rollback for the rare case where Phase 2 of
// LalFileApplier.apply (the addOrReplace loop) threw after at least one rule was
// already swapped. Drop those partial entries so the Factory doesn't carry the
// half-applied set forward. The orchestrator never sees a CompiledLalDSL for this
// path (we throw EngineCompileException instead of returning), so the orchestrator's
// rollback() never runs — meaning the old DSL for any overlap key is NOT restored
// by this catch. The state map still points at the old content, so the next
// reconciler scan (NO_CHANGE → re-apply on disagreement check) will recover by
// recompiling the persisted content. Phase 1 failures arrive here with an emptyView on GitHub (pinned to 102af09b4a)
Solutions
- Enable/start the LogAnalyzerModule in application.yml on every node that will compile LAL runtime rules (check receiver/analyzer module list)
- Ensure runtime-rule module declares and waits for its required modules so compiles can't run before the Factory is up
- Remove stale LAL runtime-rule files from the store if this deployment intentionally has no log analysis
- Restart the node after the config fix; the Factory lookup is not retried lazily
Defensive patterns
Strategy: validation
Validate before calling
final boolean lalReady = moduleManager.find(LogAnalyzerModule.NAME) != null
&& /* Factory service is registered */ logAnalyzerFactoryAvailable();
if (!lalReady) deferOrReject("LAL compile needs LogAnalyzerModule — enable it first"); Try / catch
catch (IllegalStateException e) when 'LogAnalyzerModule Factory unavailable': permanent wiring error on this node — route LAL compiles to a node with log analysis enabled, or enable the module and restart. Do not retry in place.
Prevention
- Enable LogAnalyzerModule on every node that serves the runtime-rule API in a full deployment
- Gate the runtime-rule module's availability on the analyzer modules in packaging configs
- In minimal packagings, purge LAL catalog files from the store or disable LAL handling
When it happens
Trigger: A runtime-rule operation targeting a LAL file on an OAP whose configuration excludes the log-analyzer module, or where the module is still initializing when the first compile arrives. Also in custom packagings (e.g. server-tools style boot) that include runtime-rule but not LogAnalyzerModule.
Common situations: application.yml trimmed for a metrics-only deployment, dropping log analysis while runtime-rule LAL files remain installed; Module start-order changes making the engine reachable before the Factory registers; Test harnesses booting a subset of modules
Related errors
- Load meter analyzer configs failed
- registry_misconfigured
- Duplicate RuleEngine registration for catalog '{catalog}': {
- MeterSystem unavailable for MAL compile of {sourceName}
- Failed to load GenAI configuration file.
AI-assisted analysis of apache/skywalking@102af09b4a (2026-08-14).
Data as JSON: /api/errors/7eaacc664c8c3bfc.
Report an issue: GitHub.