remm 2004/06/07 08:30:06 Modified: catalina/src/share/org/apache/catalina/core StandardContext.java mbeans-descriptors.xml Log: - Add flag to disable save-context-file, which can be useful in embedded mode. Revision Changes Path 1.130 +24 -2 jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/StandardContext.java Index: StandardContext.java =================================================================== RCS file: /home/cvs/jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/StandardContext.java,v retrieving revision 1.129 retrieving revision 1.130 diff -u -r1.129 -r1.130 --- StandardContext.java 26 May 2004 15:36:28 -0000 1.129 +++ StandardContext.java 7 Jun 2004 15:30:06 -0000 1.130 @@ -615,6 +615,12 @@ private boolean tldNamespaceAware = false; + /** + * Should we save the configuration. + */ + private boolean saveConfig = true; + + // ----------------------------------------------------- Context Properties public void setName( String name ) { @@ -1676,6 +1682,22 @@ } + /** + * Save config ? + */ + public boolean isSaveConfig() { + return saveConfig; + } + + + /** + * Set save config flag. + */ + public void setSaveConfig(boolean saveConfig) { + this.saveConfig = saveConfig; + } + + // -------------------------------------------------------- Context Methods @@ -4047,7 +4069,7 @@ // Set config file name File configBase = getConfigBase(); - if (configBase != null) { + if ((configBase != null) && saveConfig) { if (getConfigFile() == null) { File file = new File(configBase, getDefaultConfigFile()); setConfigFile(file.getPath()); 1.29 +5 -0 jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/mbeans-descriptors.xml Index: mbeans-descriptors.xml =================================================================== RCS file: /home/cvs/jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/mbeans-descriptors.xml,v retrieving revision 1.28 retrieving revision 1.29 diff -u -r1.28 -r1.29 --- mbeans-descriptors.xml 25 Feb 2004 21:08:07 -0000 1.28 +++ mbeans-descriptors.xml 7 Jun 2004 15:30:06 -0000 1.29 @@ -256,6 +256,11 @@ type="[Ljava.lang.String;" writeable="false"/> + <attribute name="saveConfig" + description="Should the configuration be written as needed on startup" + is="true" + type="boolean"/> + <attribute name="server" description="The J2EE Server this module is deployed on" type="java.lang.String"/>
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]