Class LogAggregationWebUtils
java.lang.Object
org.apache.hadoop.yarn.logaggregation.LogAggregationWebUtils
Utils for rendering aggregated logs block.
-
Method Summary
Modifier and TypeMethodDescriptionstatic longgetLogEndIndex(HtmlBlock.Block html, String endStr) Parse end index from html.static longgetLogEndTime(String endStr) Parse log end time from html.static longgetLogStartIndex(HtmlBlock.Block html, String startStr) Parse start index from html.static longgetLogStartTime(String startStr) Parse log start time from html.static StringverifyAndGetAppOwner(HtmlBlock.Block html, String appOwner) Verify and parse the application owner.static org.apache.hadoop.yarn.api.records.ContainerIdverifyAndGetContainerId(HtmlBlock.Block html, String containerIdStr) Verify and parse containerId.static org.apache.hadoop.yarn.api.records.NodeIdverifyAndGetNodeId(HtmlBlock.Block html, String nodeIdStr) Verify and parse NodeId.
-
Method Details
-
getLogStartIndex
public static long getLogStartIndex(HtmlBlock.Block html, String startStr) throws NumberFormatException Parse start index from html.- Parameters:
html- the htmlstartStr- the start index string- Returns:
- the startIndex
- Throws:
NumberFormatException
-
getLogEndIndex
Parse end index from html.- Parameters:
html- the htmlendStr- the end index string- Returns:
- the endIndex
- Throws:
NumberFormatException
-
verifyAndGetContainerId
public static org.apache.hadoop.yarn.api.records.ContainerId verifyAndGetContainerId(HtmlBlock.Block html, String containerIdStr) Verify and parse containerId.- Parameters:
html- the htmlcontainerIdStr- the containerId string- Returns:
- the
ContainerId
-
verifyAndGetNodeId
public static org.apache.hadoop.yarn.api.records.NodeId verifyAndGetNodeId(HtmlBlock.Block html, String nodeIdStr) Verify and parse NodeId.- Parameters:
html- the htmlnodeIdStr- the nodeId string- Returns:
- the
NodeId
-
verifyAndGetAppOwner
Verify and parse the application owner.- Parameters:
html- the htmlappOwner- the Application owner- Returns:
- the appOwner
-
getLogStartTime
Parse log start time from html.- Parameters:
startStr- the start time string- Returns:
- the startIndex
- Throws:
NumberFormatException
-
getLogEndTime
Parse log end time from html.- Parameters:
endStr- the end time string- Returns:
- the endIndex
- Throws:
NumberFormatException
-