#315 Allow user to change the log level of output to the log


Currently the displayed log is set to show all logging output. It would be nice to make it possible for the user to change the level of output log information displayed.


  • Terry O'Neill

    Terry O'Neill - 2011-09-05

    This item created for work already done by matthewoliver. Assigned to acunliffe to test functionality.

    This has been fixed by allowing the log level to be changed through the java preference mechanic. However there is no change to give the user control of setting this value through the GUI. Thus it must be changed directly through the operating system by looking up how the operating system handles such java preferences. In future it may be desirable to give the user control of this through the GUI. It would also be important to check that any output log information still records all levels and just the GUI display is limited.

  • Terry O'Neill

    Terry O'Neill - 2011-09-05
    • assigned_to: matthewoliver --> acunliffe
    • status: open --> open-fixed
  • Terry O'Neill

    Terry O'Neill - 2011-09-09

    Fixed an error where a default value from the xena/etc/default-preference-properties file would be written over whatever was in the users preference file no matter if there was already a value there. This may have been a deliberate change to allow the user to set the log level without having to find where the preferences are stored but it is bad practice considering the name of the file and the undocumented nature of this behaviour. Thus I have removed this behaviour (may be worth considering a better way for the user to change the logging level in the future).

  • Allan Cunliffe

    Allan Cunliffe - 2011-09-12
    • assigned_to: acunliffe --> terryoneill
  • Allan Cunliffe

    Allan Cunliffe - 2011-09-12

    Tested in Xena Testing Branch (Date: Fri Sep 9 12:05:57 2011 +1000)

    Doesn't look like this is working as expected but I might be doing something wrong.

    This is what I did in Windows XP:

    Changed logging.properties file (under C:\Program Files\Java\jre6\lib):

    1. Under the Set Global properties section, I changed the level (for example, ".level = FINE")
    2. I saved changes
    3. I started Xena via the batch file
    4. I converted a file that fails conversion
    5. I examined the error message in the console, the GUI log, the Xena log, the error dialog.

    When I change the log level, it does not appear to alter any of the error messages listed above.
    When I start Xena each time I change the log level, I still see FINER, FINEST and FINE level messages in the console.

    Logging properties file is attached.

  • Terry O'Neill

    Terry O'Neill - 2011-09-14

    Changing the logging.properties file changes the default properties for created loggers. However Xena specifically sets the logging level so any value you put in this file will not be used. You will need to change the Java user preferences to test this feature request. This can be found in Windows XP in the registry under:

    HKEY_CURRENT_USER -> Software -> JavaSoft -> Prefs

    Note that Xena uses default values from the xena/xena/etc/default-preference-properties file so these can be used to set the user preferences the first time. However, Xena sets the actual user preferences with these values when it is first run (which it really shouldn't) so that if these are changed after running there will be no effect as Xena now thinks these values have been specified. Also note that I have removed the specific overwriting of the loglevel value from the value in the file in all circumstances which seemed to be an undocumented feature for easily changing the loglevel.

  • Allan Cunliffe

    Allan Cunliffe - 2011-09-15
    • status: open-fixed --> closed-fixed
  • Allan Cunliffe

    Allan Cunliffe - 2011-09-15

    OK - retested by altering the Java user preferences.


    HKEY_CURRENT_USER - Software - JavaSoft - Prefs - au - gov - naa - digipres - xena - litegui - loglevel


    I altered the/home/al/.java/.userPrefs/au/gov/naa/digipres/xena/litegui/prefs.xml

    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE map SYSTEM "http://java.sun.com/dtd/preferences.dtd">
    <map MAP_XML_VERSION="1.0">
    <entry key="dir/lastvisited" value="/home/al/Documents/Technical_Doco/files_that_can_be_used_for_testing/DocoSamples"/>
    <entry key="dir/xenadest" value="/home/al/Xena/Destination"/>
    <entry key="dir/xenalog" value="/home/al/Xena/Logs"/>
    <entry key="loglevel" value="FINE"/>


    * Set to FINE (registry data value of /F/I/N/E) - FINE level of output is displayed in the GUI log.

    * Set to OFF (registry data value of /O/F/F) - the log output in the console is Exiftool output only. The GUI log output is null.


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks