jakarta-jcs-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eduardo Estefano <eduardo.estef...@siemens.com>
Subject Re: Properties instead of config file
Date Fri, 03 Sep 2004 15:29:39 GMT
Since that subject came up. It would also be nice to pass a URL for 
configuration (like in log4j). We had that need in our project and 
created a small hack but would be great if that was part of the official 


Mike Müller wrote:

>To set the config filename now on ehas to use
>th emethod setConfigFilename on org.apache.jcs.JCS
>It would be nice if there would be a second method 
>on the JCS object which would allow it, to pass a
>Properties object instead of a filename. The problem
>which occurred in our web application is the following:
>we need to parse the cache.ccf and set the paths for
>the file-cache on the startup of the servlet container.
>in this case we need to write the cache.ccf after setting
>the paths to the file cache and pass then the filename
>of it with setConfigFilename to JCS. under some circumstances
>JCS now can't read the file (maybe it isn't written entirely?)
>and JCS gets a NullPointerException:
>	at java.util.StringTokenizer.<init>(StringTokenizer.java:146)
>	at java.util.StringTokenizer.<init>(StringTokenizer.java:162)
>	at org.apache.jcs.engine.control.CompositeCacheConfigurator.parseRegion(CompositeCacheConfigurator.java:272)
>	at org.apache.jcs.engine.control.CompositeCacheConfigurator.parseRegion(CompositeCacheConfigurator.java:243)
>	at org.apache.jcs.engine.control.CompositeCacheManager.getCache(CompositeCacheManager.java:356)
>	at org.apache.jcs.engine.control.CompositeCacheManager.getCache(CompositeCacheManager.java:315)
>	at org.apache.jcs.engine.control.CompositeCacheManager.getCache(CompositeCacheManager.java:308)
>	at org.apache.jcs.JCS.getInstance(JCS.java:103)
>So if there's a way to pass the Properties object without writing 
>it down to disk this would be great.
>Maybe we can implement this in JCS, but we're not yet committer to
>the JCS project. What do the committers think about it?
>best regards
>Mike Müller
>To unsubscribe, e-mail: turbine-jcs-dev-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: turbine-jcs-dev-help@jakarta.apache.org

To unsubscribe, e-mail: turbine-jcs-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-jcs-dev-help@jakarta.apache.org

View raw message