Add properties by openfire.xml

Hi,

I want to set properties in openfire.xml.
I tried this

<plugin> 
    <restapi> 
      <enabled> 
        <prop>true</prop> 
      </enabled> 
    </restapi> 
  </plugin>

but after restart of Openfire, those properties are not set in ofproperty table.

in openfire.xml, it’s written this:

<!--
    This file stores bootstrap properties needed by Openfire.
    Property names must be in the format: "prop.name.is.blah=value"
    That will be stored as:
        <prop>
            <name>
                <is>
                    <blah>value</blah>
                </is>
            </name>
        </prop>

    Most properties are stored in the Openfire database. A
    property viewer and editor is included in the admin console.
-->

can someone help me to set properties in autosetup, please.
thanks for your support.

MBE

For me it seems that the comments in the xml files (also in the security.xml) are not exactly up-to-date with the code, there are some bugs in the code or the comments are just not clear enough. Autosetup supports only the properties listed in the code here.

I ended up writing the most of the properties directly to the property table in the database as I had no luck in getting them there from openfire.xml (except for some passwords with the help of security.xml).

@Mbe You can directly fetch it with the Jiveproperty class,

Can you post a code snippet how are you trying to fetch it i can help you,i did it many times.

Hi
Thank for your support and reply.
I want to use openfire.xml to put data in ofproperty.

Yes please help me with your solution.

Happy New year

That will defeat the purpose of the xml file but you can write it down the script at the start of the server that you can dump those values into database.

However why you need to do that ?

Hi,

I want to setup some plugins properties at autosetup like

<plugin> 
    <restapi> 
      <enabled> 
        <prop>true</prop> 
      </enabled> 
    </restapi> 
  </plugin>

Best regards