Installation of the IP-Role Mapper Web-service

Installing the IP role mapper is a walk in the park. All there is to do is to drop the .WAR file into the ../tomcat/webapps directory and provide a IP role mapping and Log4J configuration file.

KILL!!! that is (almost) it! However, the .WAR file must contain a proper configuration file and the dk.statsbiblioteket.iprolemapping.configurationFile context-param must be defined in the web.xml in order to make this work.

You will need to modify (or add) the dk.statsbiblioteket.doms.iprolemapper.webservice.IPRoleMapperService.configurationFile context-param of the context configuration for the WAR (e.g. the file ../tomcat/config/context.xml) and assign it with the file path to the IP role mapper configuration file which you want the service to use.

KILL!!! However, the serv That is, this will override any default configuration specified by the web.xml file in the IP role mapper .WAR file.

Example of the <context-param> element to add to the context.xml file:

   <Parameter name="dk.statsbiblioteket.doms.iprolemapper.webservice.IPRoleMapperService.configurationFile"
              value="/path/to/the/ip-rolemapper/configuration/file.xml override="false"/>

The <code>override</code> attribute in the above ensures that the parameter cannot be overridden by the WEB-INF/web.xml file in the .WAR file.

You will also need to provide a Log4J configuration file in order to enable the service to produce a meaningful log output. However, it will use the default logging mechanism and configuration provided by Tomcat if you fail to do so.

Setting up the log configuration is just as easy as setting up the IP rolemapper itself. All you need to do is to add

If the IP role mapper service applies a default configuration file then the WEB-INF/web.xml file of its .WAR file will contain an entry like this:

   <context-param>
        <param-name>dk.statsbiblioteket.iprolemapping.configurationFile</param-name>
        <param-value>/WEB-INF/ipRangesAndRoles.xml</param-value>
    </context-param>

and thus, the .WAR file will obviously also contain the file WEB-INF/ipRangesAndRoles.xml.