Hi Eric, Thank you for the info. Actually parsing the xml with the commons-configuration library is much simpler and nicer. However, although I read the documentation to update the file [1], I am having some problems because it sometimes duplicates instead of updating the value.
I have been looking for examples, but it seems as all the ones I found use the library to read, but not to write. Do you know where I can find a coding example that updates an xml and that I can run? Thanks in advance. [1] http://commons.apache.org/proper/commons-configuration/userguide/howto_filebased.html#Saving 2013/7/25 Eric Charles <[email protected]> > On 25/07/2013 14:18, Emma Sesmero wrote: > >> Hello all, >> >> Currently, I am implementing the configuration web interface and I have a >> couple of questions: >> >> - The documentation says that all configuration files resides in the >> ./conf >> and ./conf/META-INF folder. So what I am doing now is trying to read the >> configuration .xml in the forther ./conf (for example, dnsservice.xml for >> DNS), if it does not exist, I create the xml copying the -template.xml >> (dnsservice-template.xml for DNS), reading this considering it as the >> default configuration and edit it. Do you think this is the correct >> approach? >> >> > Doc is for the last release. trunk uses configuration files embedded in > the jars, and overrided by files in conf folder (initially, conf folder is > empty) > > > - Does any of you know what james server is using to read those >> configuration files? I have started to use jdom, but it might be better to >> use the same as James for this task. >> >> > configuration is parsed with commons-configuration library. > > > Thank you very much in advance. >> >> > ------------------------------**------------------------------**--------- > To unsubscribe, e-mail: > server-dev-unsubscribe@james.**apache.org<[email protected]> > For additional commands, e-mail: > [email protected].**org<[email protected]> > >
