Skip to content

Commit ffedb40

Browse files
committed
LDEV-5147 fix debug template error on mode switch
Reset cached configuration fields (debugEntries, mailServers, restMappings) when switching between Single and Multi mode contexts. These lazily-initialized fields would become stale after mode switching, causing component loading to fail with "can't find component [lucee.admin.debug.Simple]". The fix ensures a fresh reload from the new configuration context by resetting these fields to empty arrays in MultiContextConfigWeb when setInstance() is called. Version: 6.2.8.17 → 6.2.8.18-SNAPSHOT
1 parent bf7239c commit ffedb40

3 files changed

Lines changed: 8 additions & 2 deletions

File tree

core/src/main/java/lucee/runtime/config/ConfigWebImpl.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1878,6 +1878,12 @@ public ConfigWebImpl setInstance(ConfigWebInner instance) {
18781878
this.instance.reset();
18791879
}
18801880
this.instance = instance;
1881+
if (instance instanceof MultiContextConfigWeb) {
1882+
MultiContextConfigWeb mcw = (MultiContextConfigWeb) instance;
1883+
mcw.setDebugEntries(new DebugEntry[0]);
1884+
mcw.setMailServers(new Server[0]);
1885+
mcw.setRestMappings(new lucee.runtime.rest.Mapping[0]);
1886+
}
18811887
return this;
18821888
}
18831889

loader/build.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<project default="core" basedir="." name="Lucee"
33
xmlns:resolver="antlib:org.apache.maven.resolver.ant">
44

5-
<property name="version" value="6.2.8.17-SNAPSHOT"/>
5+
<property name="version" value="6.2.8.18-SNAPSHOT"/>
66

77
<taskdef uri="antlib:org.apache.maven.resolver.ant" resource="org/apache/maven/resolver/ant/antlib.xml">
88
<classpath>

loader/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
<groupId>org.lucee</groupId>
55
<artifactId>lucee</artifactId>
6-
<version>6.2.8.17-SNAPSHOT</version>
6+
<version>6.2.8.18-SNAPSHOT</version>
77
<packaging>jar</packaging>
88

99
<name>Lucee Loader Build</name>

0 commit comments

Comments
 (0)