AnsweredAssumed Answered

Config Changes Through JMX - What's Persisted and What Isn't

Question asked by tommorris on Dec 21, 2011
Latest reply on Jan 8, 2014 by vincent_os
I hope to clarify a small matter about configuration using JMX and what is persisted and what is not.

Once you make changes through JMX, those changes are persisted in the database, and these changes take priority over the values that you may have in the 'alfresco-global.properties' file.

However, an important point to note, is that not all configuration changes are persisted in this way. So how do you know what is and what is not persisted?

The MBeans are exposed in a hierarchical tree and all configuration that lies beneath the branch 'Alfresco -> Configuration' is persisted in the database, but only after their attributes have been modified through a JMX console. All the beans in that branch are described as 'Persistent Managed Bean' and are therefore values that are kept in the database .

But notice that there's a lot of other configuration outside this branch, none of which appears to be persisted because they're instead described as 'Property Dynamic MBeans' (or other). To confirm what is and what is not persisted, you can go to the 'Metadata' tab within VisualVM and check the bean description.

Another useful point to note is that you can go back to favouring configuration in 'alfresco-global.properties' over that of a persisted value in the database. Each bean of type 'Persistent Managed Bean' normally has three operations: Start, Stop, and Revert. If you execute the 'Revert' method from VisualVM (or the JMX Console fo your choice) it will remove the value from the database and use the value from the properties file instead.

I've just noticed that the wiki page is a little confusing on the topic (see  http://wiki.alfresco.com/wiki/JMX#Change_Management) but if you follow the advice above, you'll know for sure.

I hope this information is useful, but I can add some screen-shots if it helps.

Tom
http://www.ixxus.com

Outcomes