Class SynchronizationServlet

java.lang.Object
jakarta.servlet.GenericServlet
jakarta.servlet.http.HttpServlet
net.ontopia.topicmaps.db2tm.SynchronizationServlet
All Implemented Interfaces:
jakarta.servlet.Servlet, jakarta.servlet.ServletConfig, Serializable

public class SynchronizationServlet extends jakarta.servlet.http.HttpServlet
PUBLIC: Servlet that sets up and schedules DB2TM synchronization at regular intervals. Parameters: start-time, delay, interval, mapping, relations and topicmap. Example web.xml configuation:
   <servlet>
   <servlet-name>MySynchronizationServlet</servlet-name>
   <description>
     DB2TM synchronization
   </description>
   <servlet-class>
     net.ontopia.topicmaps.db2tm.SynchronizationServlet
   </servlet-class>
   <init-param>
     <param-name>start-time</param-name>
     <param-value>09:50</param-value>
   </init-param>
   <init-param>
     <param-name>interval</param-name>
     <param-value>86400000</param-value>
   </init-param>
   <init-param>
     <param-name>mapping</param-name>
     <param-value>bk.db2tm.xml</param-value>
   </init-param>
   <init-param>
     <param-name>topicmap</param-name>
     <param-value>result.xtm</param-value>
   </init-param>
   <load-on-startup>1</load-on-startup>
 </servlet>
 
This configuration will make the DB2TM synchronization run at every day at 09:50 in the morning. The mapping file must either be adressed directly on the file system or it will be loaded by name from the CLASSPATH.
Since:
3.3.0
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
     

    Fields inherited from class jakarta.servlet.http.HttpServlet

    LEGACY_DO_HEAD
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
     
    void
    init(jakarta.servlet.ServletConfig config)
     

    Methods inherited from class jakarta.servlet.http.HttpServlet

    doDelete, doGet, doHead, doOptions, doPatch, doPost, doPut, doTrace, getLastModified, isSensitiveHeader, service, service

    Methods inherited from class jakarta.servlet.GenericServlet

    getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

    • SynchronizationServlet

      public SynchronizationServlet()
  • Method Details

    • init

      public void init(jakarta.servlet.ServletConfig config) throws jakarta.servlet.ServletException
      Specified by:
      init in interface jakarta.servlet.Servlet
      Overrides:
      init in class jakarta.servlet.http.HttpServlet
      Throws:
      jakarta.servlet.ServletException
    • destroy

      public void destroy()
      Specified by:
      destroy in interface jakarta.servlet.Servlet
      Overrides:
      destroy in class jakarta.servlet.GenericServlet