Replace default buffer value to 100 GB, changed buttons to use String notation, removed default buffer parameter in UI URLs
This commit is contained in:
parent
a32784109d
commit
6d054487bf
|
@ -90,9 +90,9 @@ private[spark] class ApplicationPage(parent: MasterWebUI) {
|
|||
<td>{executor.memory}</td>
|
||||
<td>{executor.state}</td>
|
||||
<td>
|
||||
<a href={"%s/logPage?appId=%s&executorId=%s&logType=stdout&byteLength=10000"
|
||||
<a href={"%s/logPage?appId=%s&executorId=%s&logType=stdout"
|
||||
.format(executor.worker.webUiAddress, executor.application.id, executor.id)}>stdout</a>
|
||||
<a href={"%s/logPage?appId=%s&executorId=%s&logType=stderr&byteLength=10000"
|
||||
<a href={"%s/logPage?appId=%s&executorId=%s&logType=stderr"
|
||||
.format(executor.worker.webUiAddress, executor.application.id, executor.id)}>stderr</a>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -89,9 +89,9 @@ private[spark] class IndexPage(parent: WorkerWebUI) {
|
|||
</ul>
|
||||
</td>
|
||||
<td>
|
||||
<a href={"logPage?appId=%s&executorId=%s&logType=stdout&byteLength=10000"
|
||||
<a href={"logPage?appId=%s&executorId=%s&logType=stdout"
|
||||
.format(executor.appId, executor.execId)}>stdout</a>
|
||||
<a href={"logPage?appId=%s&executorId=%s&logType=stderr&byteLength=10000"
|
||||
<a href={"logPage?appId=%s&executorId=%s&logType=stderr"
|
||||
.format(executor.appId, executor.execId)}>stderr</a>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -54,7 +54,7 @@ class WorkerWebUI(val worker: Worker, val workDir: File, requestedPort: Option[I
|
|||
}
|
||||
|
||||
def log(request: HttpServletRequest): String = {
|
||||
val defaultBytes = 10000
|
||||
val defaultBytes = 100 * 1024
|
||||
val appId = request.getParameter("appId")
|
||||
val executorId = request.getParameter("executorId")
|
||||
val logType = request.getParameter("logType")
|
||||
|
@ -72,7 +72,7 @@ class WorkerWebUI(val worker: Worker, val workDir: File, requestedPort: Option[I
|
|||
}
|
||||
|
||||
def logPage(request: HttpServletRequest): Seq[scala.xml.Node] = {
|
||||
val defaultBytes = 10000
|
||||
val defaultBytes = 100 * 1024
|
||||
val appId = request.getParameter("appId")
|
||||
val executorId = request.getParameter("executorId")
|
||||
val logType = request.getParameter("logType")
|
||||
|
@ -95,7 +95,8 @@ class WorkerWebUI(val worker: Worker, val workDir: File, requestedPort: Option[I
|
|||
<a href={"?appId=%s&executorId=%s&logType=%s&offset=%s&byteLength=%s"
|
||||
.format(appId, executorId, logType, math.max(startByte-byteLength, 0),
|
||||
byteLength)}>
|
||||
<button>Previous {math.min(byteLength, startByte)} Bytes</button>
|
||||
<button>Previous {Utils.memoryBytesToString(math.min(byteLength, startByte))} Bytes
|
||||
</button>
|
||||
</a>
|
||||
}
|
||||
else {
|
||||
|
@ -106,7 +107,8 @@ class WorkerWebUI(val worker: Worker, val workDir: File, requestedPort: Option[I
|
|||
if (endByte < logLength) {
|
||||
<a href={"?appId=%s&executorId=%s&logType=%s&offset=%s&byteLength=%s".
|
||||
format(appId, executorId, logType, endByte, byteLength)}>
|
||||
<button>Next {math.min(byteLength, logLength-endByte)} Bytes</button>
|
||||
<button>Next {Utils.memoryBytesToString(math.min(byteLength, logLength-endByte))} Bytes
|
||||
</button>
|
||||
</a>
|
||||
}
|
||||
else {
|
||||
|
@ -135,7 +137,7 @@ class WorkerWebUI(val worker: Worker, val workDir: File, requestedPort: Option[I
|
|||
/** Determine the byte range for a log or log page. */
|
||||
def getByteRange(path: String, offset: Option[Long], byteLength: Int)
|
||||
: (Long, Long) = {
|
||||
val defaultBytes = 10000
|
||||
val defaultBytes = 100 * 1024
|
||||
val maxBytes = 1024 * 1024
|
||||
|
||||
val file = new File(path)
|
||||
|
|
Loading…
Reference in a new issue