guixiaowen commented on code in PR #1410: URL: https://github.com/apache/auron/pull/1410#discussion_r2418477141
########## auron-spark-ui/src/main/scala/org/apache/spark/sql/execution/ui/AuronAllExecutionsPage.scala: ########## @@ -0,0 +1,77 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.spark.sql.execution.ui + +import javax.servlet.http.HttpServletRequest + +import scala.collection.mutable +import scala.xml.{Node, NodeSeq} + +import org.apache.spark.internal.Logging +import org.apache.spark.ui.{UIUtils, WebUIPage} + +private[ui] class AuronAllExecutionsPage(parent: AuronSQLTab) extends WebUIPage("") with Logging { + + private val sqlStore = parent.sqlStore + + override def render(request: HttpServletRequest): Seq[Node] = { + val buildInfo = sqlStore.buildInfo() + + val content = { + val _content = mutable.ListBuffer[Node]() + _content + } + content ++= + <script> + function clickDetail(details) {{ + details.parentNode.querySelector('.stage-details').classList.toggle('collapsed') + }} + </script> + + val infos = + UIUtils.listingTable(propertyHeader, propertyRow, buildInfo.info, fixedWidth = true) + val summary: NodeSeq = + <div> + <div> + <span class="collapse-sql-properties collapse-table" + onClick="collapseTable('collapse-sql-properties', 'sql-properties')"> + <h4> + <span class="collapse-table-arrow arrow-open"></span> + <a>Auron Build Information</a> + </h4> + </span> + <div class="sql-properties collapsible-table"> + {infos} + </div> + </div> + <br/> + </div> + + UIUtils.headerSparkPage(request, "Auron SQL / DataFrame", summary ++ content, parent) Review Comment: > `Auron SQL / DataFrame` -> `Auron` is enough? @zuston z Thank you very much for reviewing the code. It has been updated. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
