Package de.elo.ix.client.webapp.servlet
Class IXClientServletHandler
java.lang.Object
de.elo.utils.webapp.status.StatusPageHandler
de.elo.ix.client.webapp.servlet.IXClientServletHandler
- All Implemented Interfaces:
Application
public class IXClientServletHandler
extends de.elo.utils.webapp.status.StatusPageHandler
implements Application
This class helps to develop a J2EE Servlet that has to manage one or more Indexserver
connections. It is internally used by the IXClientServlet class.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class de.elo.utils.webapp.status.StatusPageHandler
de.elo.utils.webapp.status.StatusPageHandler.Request, de.elo.utils.webapp.status.StatusPageHandler.Response, de.elo.utils.webapp.status.StatusPageHandler.StatusDataCallback
-
Field Summary
Fields inherited from class de.elo.utils.webapp.status.StatusPageHandler
URL_COMMAND_SET_LOG_LEVEL, URL_COMMAND_STATUS, URL_COMMAND_STATUS_TEXT, URL_PARAM_COMMAND, URL_PARAM_COMMAND_LOG_LEVEL, URL_PARAM_COMMAND_STATUS, URL_PARAM_LOG_LEVEL, URL_PARAM_LOGGER, URL_PARAM_MODE, URL_PARAM_MODE_TEXT
-
Constructor Summary
ConstructorsConstructorDescriptionIXClientServletHandler
(String programName, String programVersion, String mainPackage) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionGets the interface to access the appliations configuration.Connection manager.Program nameProgram versionde.elo.utils.webapp.status.StatusData
This object can be used to store information that should be printed on the applications status page.void
init
(jakarta.servlet.ServletConfig config) Initialization with ServletConfig values, reading the configuration properties.void
shutdown()
This function should be called in Servlet.destroy().Methods inherited from class de.elo.utils.webapp.status.StatusPageHandler
getLogLevel, printStatus, service, setLogLevel
-
Constructor Details
-
IXClientServletHandler
Constructor. Either the programVersion or the mainPackage parameter should be supplied. If mainPackage is supplied, the programVersion is internally evaluated by using the de.elo.utils.Version class.- Parameters:
programName
- program nameprogramVersion
- program version.mainPackage
- main package name (e.g. de.elo.intrafind).
-
-
Method Details
-
init
public void init(jakarta.servlet.ServletConfig config) throws jakarta.servlet.ServletException Initialization with ServletConfig values, reading the configuration properties. The parameter found in the web.xml and config.xml are read into the internal configuration property map. Furthermore, log4j is initialized.- Parameters:
config
- ServletConfig- Throws:
jakarta.servlet.ServletException
-
getConnManager
Description copied from interface:Application
Connection manager. This object helps to create and manage Indexserver connections.- Specified by:
getConnManager
in interfaceApplication
- Returns:
- AppConnManager object
-
getAppConfig
Description copied from interface:Application
Gets the interface to access the appliations configuration.- Specified by:
getAppConfig
in interfaceApplication
- Returns:
- AppConfig object
-
getProgramName
Program name- Specified by:
getProgramName
in interfaceApplication
- Returns:
- value
-
getProgramVersion
Program version- Specified by:
getProgramVersion
in interfaceApplication
- Returns:
- value
-
getStatusData
public de.elo.utils.webapp.status.StatusData getStatusData()This object can be used to store information that should be printed on the applications status page.- Specified by:
getStatusData
in interfaceApplication
- Returns:
- object
- See Also:
-
StatusPage
-
shutdown
public void shutdown()This function should be called in Servlet.destroy(). It closes the internal Indexserver connection and shutdowns the thread pools of Commons HTTP Client. Furthermore it closes the logger.- Specified by:
shutdown
in interfaceApplication
-