Zhengdai Hu created STORM-3140:
----------------------------------
Summary: Duplicated method?
Key: STORM-3140
URL: https://issues.apache.org/jira/browse/STORM-3140
Project: Apache Storm
Issue Type: Bug
Components: storm-webapp
Affects Versions: 2.0.0
Reporter: Zhengdai Hu
{code:java}
/**
* Handles '/searchLogs' request.
*/
@GET
@Path("/searchLogs")
public Response searchLogs(@Context HttpServletRequest request) throws
IOException {
String user = httpCredsHandler.getUserName(request);
String topologyId = request.getParameter("topoId");
String portStr = request.getParameter("port");
String callback = request.getParameter("callback");
String origin = request.getHeader("Origin");
return logviewer.listLogFiles(user, portStr != null ?
Integer.parseInt(portStr) : null, topologyId, callback, origin);
}
/**
* Handles '/listLogs' request.
*/
@GET
@Path("/listLogs")
public Response listLogs(@Context HttpServletRequest request) throws
IOException {
meterListLogsHttpRequests.mark();
String user = httpCredsHandler.getUserName(request);
String topologyId = request.getParameter("topoId");
String portStr = request.getParameter("port");
String callback = request.getParameter("callback");
String origin = request.getHeader("Origin");
return logviewer.listLogFiles(user, portStr != null ?
Integer.parseInt(portStr) : null, topologyId, callback, origin);
}{code}
These two methods have identical although they seem to serve different
functions.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)