https://issues.apache.org/bugzilla/show_bug.cgi?id=57403

            Bug ID: 57403
           Summary: Persist configuration changes made via status worker
           Product: Tomcat Connectors
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Common
          Assignee: dev@tomcat.apache.org
          Reporter: rainer.j...@kippdata.de

The status worker should have an optional feature to save any configuration
changes made via its GUI to workers.properties.

Writing a configuraiton file is typically not an easy task, because you would
loose comments and other structure of the original file, e.g. property
inheritance via the "reference" attribute.

One implementation idea would be second "journal" file to which one would write
a protocol of all new propertiy values coming our of status worker changes.
Only changes with a "persist" checkbox set in the GUI would be written there.

During startup mod_jk would read the original workers.properties and then
overlay the journal file to reacreate the last "persisted" configuration state.

A sysadmin could at any time either roll back by deleting the journal file or
parts of it, or reintegrate the journal file contents into the original
workers.properties.

The default name of the journal file could be the value of JkWorkersFile plus
some suffix, like ".journal" or ".changes". For situations, where the file has
to go to some other place, a JkWorkersJounrnalFile directive could be used to
explicitely set the file (and dir).

The default in the status worker GUI would be not to persist, activating it via
a checkbox in the forms, in which one can set new property values. A
configuration item for the status worker could switch defaults (it would still
show the same checkbox, but then it would be checked by default).

If saving the properties fails, the status workr would show an error message
and also log an error.

If mod_jk finds a journal file, it would log its existence and processing on
info log level during startup.

The journal file could also contain a comment line for each property line,
which contains a timestamp of the change and maybe user name and other meta
data (client IP? User comment added via GUI?).

I currently do not plan to work on this but patches are welcome.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to