Class ListServerSocketServlet
- java.lang.Object
-
- javax.servlet.GenericServlet
-
- javax.servlet.http.HttpServlet
-
- org.pentaho.di.www.BaseHttpServlet
-
- org.pentaho.di.www.ListServerSocketServlet
-
- All Implemented Interfaces:
Serializable
,javax.servlet.Servlet
,javax.servlet.ServletConfig
,CartePluginInterface
,CarteServletInterface
public class ListServerSocketServlet extends BaseHttpServlet implements CartePluginInterface
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
CONTEXT_PATH
static String
PARAM_HOSTNAME
static String
PARAM_ONLY_OPEN
-
Fields inherited from class org.pentaho.di.www.BaseHttpServlet
detections, jobMap, log, socketRepository, transformationMap
-
-
Constructor Summary
Constructors Constructor Description ListServerSocketServlet()
ListServerSocketServlet(TransformationMap transformationMap)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
String
getContextPath()
String
getService()
String
toString()
-
Methods inherited from class org.pentaho.di.www.BaseHttpServlet
convertContextPath, doDelete, doPost, doPut, getDetections, getJobMap, getSocketRepository, getTransformationMap, isJettyMode, logBasic, logBasic, logDebug, logDetailed, logDetailed, logError, logError, logError, logMinimal, logRowlevel, setJettyMode, setup
-
Methods inherited from class javax.servlet.http.HttpServlet
doHead, doOptions, doTrace, getLastModified, service, service
-
Methods inherited from class javax.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, init, log, log
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.pentaho.di.www.CartePluginInterface
isJettyMode, setJettyMode, setup
-
-
-
-
Field Detail
-
CONTEXT_PATH
public static final String CONTEXT_PATH
- See Also:
- Constant Field Values
-
PARAM_HOSTNAME
public static final String PARAM_HOSTNAME
- See Also:
- Constant Field Values
-
PARAM_ONLY_OPEN
public static final String PARAM_ONLY_OPEN
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ListServerSocketServlet
public ListServerSocketServlet()
-
ListServerSocketServlet
public ListServerSocketServlet(TransformationMap transformationMap)
-
-
Method Detail
-
doGet
public void doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, IOException
/kettle/listSocket
GET
Gets list of ports for specified host. Method is used for listing all or just open ports for specified host. Response contains port number, which transformation it is (was) used for, current status of the port and last date time used.
Example Request:
GET /kettle/listSocket/?host=127.0.0.1
Parameters
name description type host Host to get ports for. query onlyOpen Boolean flag that indicates whether all or only open ports should be returned. Set it to Y
to get the list of only currently open ports.boolean, optional Response Body
text: HTML media types: text/html Response is HTML document listing the ports requested.
Example Response:
List of server sockets on server '127.0.0.1' Ports for host '127.0.0.1'
Found 5 ports for host '127.0.0.1'8088 : Transformation=dummy-trans, crt/Dummy (do nothing) 2.0 --> sll/Dummy (do nothing).0 id=b20bcd03-9682-4327-8c42-b129faabbfe1, allocated=false time=Mon Nov 17 09:31:15 BRT 2014
8089 : Transformation=dummy-trans, crt/Dummy (do nothing) 2.0 --> sll/Dummy (do nothing).1 id=b20bcd03-9682-4327-8c42-b129faabbfe1, allocated=false time=Mon Nov 17 09:31:15 BRT 2014
8090 : Transformation=dummy-trans, crt/Dummy (do nothing) 2.0 --> sll/Dummy (do nothing).2 id=b20bcd03-9682-4327-8c42-b129faabbfe1, allocated=false time=Mon Nov 17 09:31:15 BRT 2014
8091 : Transformation=dummy-trans, crt/Dummy (do nothing) 2.0 --> sll/Dummy (do nothing).3 id=b20bcd03-9682-4327-8c42-b129faabbfe1, allocated=false time=Mon Nov 17 09:31:15 BRT 2014
8092 : Transformation=dummy-trans, crt/Dummy (do nothing) 2.0 --> sll/Dummy (do nothing).4 id=b20bcd03-9682-4327-8c42-b129faabbfe1, allocated=false time=Mon Nov 17 09:31:15 BRT 2014
Status Codes
code description 200 Request was processed. 500 Internal server error occurs during request processing. - Specified by:
doGet
in interfaceCartePluginInterface
- Overrides:
doGet
in classjavax.servlet.http.HttpServlet
- Throws:
javax.servlet.ServletException
IOException
-
getService
public String getService()
- Specified by:
getService
in interfaceCarteServletInterface
-
getContextPath
public String getContextPath()
- Specified by:
getContextPath
in interfaceCartePluginInterface
-
-