The bootstrap properties

The bootstrap properties are the properties defined in the generated web.xml file. These properties cannot be modified at runtime. You can view the properties by calling the calling the meta function _GetSettings. When the WAR file is created XINS set some default properties which are:

org.xins.api.nameThe name of the API.
org.xins.api.build.versionThe version of XINS with which the WAR file was created.
org.xins.api.versionThe version of the API (may be empty).
org.xins.api.build.timeThe time at which the WAR file was created.
org.xins.api.calling.conventionThe name of the default calling convention.

You can also define your own properties. Just add <bootstrap-properties> and <bootstrap-property> elements to the impl.xml file.

Example:

<impl>
  <bootstrap-properties>
    <bootstrap-property name="xiff.login.page">Login</bootstrap-property>
    <bootstrap-property name="xiff.default.command">DefaultCommand</bootstrap-property>
  </bootstrap-properties>
</impl>

Note

Bootstrap properties starting with org.xins. are reserved except for the org.xins.server.config bootstrap property. This property could be set to indicate the location of the runtime properties file in the case that you cannot pass it in the command line of the Servlet container.

The values of the properties will be available in the bootstrapImpl(Map<String, String> bootstrapProperties) method of your functions and shared instances.

Note

Since XINS 2.2 it is also possible to define in impl.xml extra XML elements you want to add to the generated web.xml file. Tou can think at elements such as context-param, filter, listener, ...

To do it, use the following syntax (after runtime-properties):

<impl>
  <web-app element="context-param">
    <![CDATA[
      <param-name>contextConfigLocation</param-name>
      <param-value>/WEB-INF/applicationContext.xml,/WEB-INF/daoContext.xml</param-value>
    ]]>
  </web-app>
  <web-app element="listener" id="spring">
  <![CDATA[
    <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
  ]]>
  </web-app>
</impl>