dims 01/06/22 11:19:38
Modified: src/org/apache/cocoon Cocoon.java
Log:
Dump System Properties into the log file. Makes it easier to diagnose
problems when we get the full cocoon.log file from someone.
Revision Changes Path
1.12 +20 -1 xml-cocoon2/src/org/apache/cocoon/Cocoon.java
Index: Cocoon.java
===================================================================
RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/Cocoon.java,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- Cocoon.java 2001/06/14 10:47:32 1.11
+++ Cocoon.java 2001/06/22 18:19:37 1.12
@@ -55,7 +55,7 @@
*
* @author <a href="mailto:[EMAIL PROTECTED]">Pierpaolo Fumagalli</a> (Apache
Software Foundation, Exoffice Technologies)
* @author <a href="mailto:[EMAIL PROTECTED]">Stefano Mazzocchi</a>
- * @version CVS $Revision: 1.11 $ $Date: 2001/06/14 10:47:32 $
+ * @version CVS $Revision: 1.12 $ $Date: 2001/06/22 18:19:37 $
*/
public class Cocoon extends AbstractLoggable implements ThreadSafe, Component,
Initializable, Disposable, Modifiable, Processor, Contextualizable {
/** The application context */
@@ -117,6 +117,10 @@
this.componentManager.contextualize(this.context);
getLogger().debug("New Cocoon object.");
+
+ // Log the System Properties.
+ dumpSystemProperties();
+
// Setup the default parser, for parsing configuration.
// If one need to use a different parser, set the given system property
String parser = System.getProperty(Constants.PARSER_PROPERTY,
Constants.DEFAULT_PARSER);
@@ -172,6 +176,21 @@
getLogger().debug("Sitemap location = " + this.sitemapFileName);
getLogger().debug("Checking sitemap reload = " + this.checkSitemapReload);
getLogger().debug("Reloading sitemap asynchron = " +
this.reloadSitemapAsynchron);
+ }
+
+ /** Dump System Properties */
+ private void dumpSystemProperties() {
+ try {
+ Enumeration e = System.getProperties().propertyNames();
+ getLogger().debug("===== System Properties Start =====");
+ for (;e.hasMoreElements();) {
+ String key = (String) e.nextElement();
+ getLogger().debug(key + "=" + System.getProperty(key));
+ }
+ getLogger().debug("===== System Properties End =====");
+ } catch ( SecurityException se ) {
+ // Ignore Exceptions.
+ }
}
/** Configure this <code>Cocoon</code> instance. */
----------------------------------------------------------------------
In case of troubles, e-mail: [EMAIL PROTECTED]
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]