Skip to content

Commit

Permalink
Qualification tool support UI code generation (#5470)
Browse files Browse the repository at this point in the history
* QualUI. add notice file to resources [skip ci]

Signed-off-by: Ahmed Hussein (amahussein) <a@ahussein.me>

* QualUI. pull UI dependencies during build [skip ci]

Signed-off-by: Ahmed Hussein (amahussein) <a@ahussein.me>

* ui-fix. add disclaimer and config app-details-view

Signed-off-by: Ahmed Hussein (amahussein) <a@ahussein.me>

1- add disclaimer at top of page
2- add conf to enable/disable app view details. Default is false
3- Matt requests
	Change "Total Speed-up" to "Estimated Speed-up" and round to 1 digit after the decimal
	GPU Opportunity description typo: "speed-up" should be "sped up" or even change to "accelerated"
	add disclaimer at top of dashboard page: "Disclaimer: projections are based on TPC-DS benchmark queries run using Spark 3.X.  Additionally, estimates are given assuming supported data formats and expressions are used in the application."

4- qualUI. generate js file
5- qualUI. add uiEnabledArgument
6- qualUI. add qualArgs ui enabled by default
7- qualUI. remove appInoRecords from UI usage
8- qualUI. change ui config and gitignore
9- qualUI. cleanup code

* fix notice/license and address PR comments

Signed-off-by: Ahmed Hussein (amahussein) <a@ahussein.me>

* remove comment block from js code

Signed-off-by: Ahmed Hussein (amahussein) <a@ahussein.me>

* checksum verification of ui dowanloaded files

Signed-off-by: Ahmed Hussein (amahussein) <a@ahussein.me>

* modify license file

Signed-off-by: Ahmed Hussein (amahussein) <a@ahussein.me>

* modify license file-2

Signed-off-by: Ahmed Hussein (amahussein) <a@ahussein.me>

* add license to jar and address cosmetic UI comments

Signed-off-by: Ahmed Hussein (amahussein) <a@ahussein.me>
  • Loading branch information
amahussein authored May 18, 2022
1 parent 78750ef commit 6a1fa70
Show file tree
Hide file tree
Showing 21 changed files with 2,433 additions and 8 deletions.
154 changes: 154 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -199,3 +199,157 @@
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.


MIT License
-----------

Boostrap V4.6.1
bootstrap.bundle.min.js
bootstrap.min.css

The MIT License (MIT)

Copyright (c) 2011-2019 Twitter, Inc.
Copyright (c) 2011-2019 The Bootstrap Authors

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.


DataTables
DataTables-1.12.0/jquery.dataTables.min.js
DataTables-1.12.0/dataTables.bootstrap4.min.css
DataTables-1.12.0/dataTables.bootstrap4.min.js
searchpanes-2.0.1/searchPanes.bootstrap4.min.css
searchpanes-2.0.1/searchPanes.bootstrap4.min.js
searchpanes-2.0.1/dataTables.searchPanes.min.js
select-1.4.0/select.bootstrap4.min.css
select-1.4.0/dataTables.select.min.js
buttons-2.2.3/buttons.bootstrap4.min.css
buttons-2.2.3/buttons.bootstrap4.min.js
buttons-2.2.3/buttons.html5.min.js
buttons-2.2.3/dataTables.buttons.min.js
responsive-2.3.0/dataTables.responsive.min.js
responsive-2.3.0/responsive.bootstrap4.min.css
responsive-2.3.0/responsive.bootstrap4.min.js

The MIT License (MIT)

Copyright (C) 2008-2022, SpryMedia Ltd.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software
and associated documentation files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or
substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

jQuery V3.6.0
jquery.min.js

Copyright JS Foundation and other contributors, https://js.foundation/

This software consists of voluntary contributions made by many
individuals. For exact contribution history, see the revision history
available at https://github.com/jquery/sizzle

The following license applies to all parts of this software except as
documented below:

====

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

====

All files located in the node_modules and external directories are
externally maintained libraries used by this software which have their
own licenses; we recommend you read them, as their terms may differ from
the terms above.

Mustache.js V4.10
mustache.min.js

The MIT License

Copyright (c) 2009 Chris Wanstrath (Ruby)
Copyright (c) 2010-2014 Jan Lehnardt (JavaScript)
Copyright (c) 2010-2015 The mustache.js community

Permission is hereby granted, free of charge, to any person obtaining a copy of this software
and associated documentation files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or
substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Spur Dashboard V1.1.0
spur.min.css

The MIT License (MIT)

Copyright 2018 Alexander Rechsteiner

Permission is hereby granted, free of charge, to any person obtaining a copy of this software
and associated documentation files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or
substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
26 changes: 26 additions & 0 deletions NOTICE
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,29 @@ Copyright 2014 and onwards The Apache Software Foundation

This product includes software developed at
The Apache Software Foundation (http://www.apache.org/).


This product bundles various third-party components under other open source licenses.

Boostrap V4.6.1 - The MIT License (MIT)
License Text ( https://github.com/twbs/bootstrap/blob/v4.6.1/LICENSE )
Copyright (c) 2011-2021 Twitter, Inc.
Copyright (c) 2011-2021 The Bootstrap Authors

DataTablesSrc V1.12 - The MIT License (MIT)
License Text ( https://datatables.net/license/ )
Copyright (C) 2008-present, SpryMedia Ltd.

jQuery V3.6.0 - The MIT License (MIT)
License Text ( https://jquery.org/license/ )
Copyright OpenJS Foundation and other contributors, https://openjsf.org/

Mustache.js V4.10 - The MIT License (MIT)
License Text ( https://github.com/janl/mustache.js/blob/master/LICENSE )
Copyright (c) 2009 Chris Wanstrath (Ruby)
Copyright (c) 2010-2014 Jan Lehnardt (JavaScript)
Copyright (c) 2010-2015 The mustache.js community

Spur Dashboard V1.1.0 - The MIT License (MIT)
License Text ( https://github.com/HackerThemes/spur-template/blob/master/LICENSE )
Copyright 2016 - 2019 Alexander Rechsteiner
27 changes: 27 additions & 0 deletions NOTICE-binary
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,30 @@ PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

---------------------------------------------------------------------

This product bundles various third-party components under other open source licenses.

Boostrap V4.6.1 - The MIT License (MIT)
License Text ( https://github.com/twbs/bootstrap/blob/v4.6.1/LICENSE )
Copyright (c) 2011-2021 Twitter, Inc.
Copyright (c) 2011-2021 The Bootstrap Authors

DataTablesSrc V1.12 - The MIT License (MIT)
License Text ( https://datatables.net/license/ )
Copyright (C) 2008-present, SpryMedia Ltd.

jQuery V3.6.0 - The MIT License (MIT)
License Text ( https://jquery.org/license/ )
Copyright OpenJS Foundation and other contributors, https://openjsf.org/

Mustache.js V4.10 - The MIT License (MIT)
License Text ( https://github.com/janl/mustache.js/blob/master/LICENSE )
Copyright (c) 2009 Chris Wanstrath (Ruby)
Copyright (c) 2010-2014 Jan Lehnardt (JavaScript)
Copyright (c) 2010-2015 The mustache.js community

Spur Dashboard V1.1.0 - The MIT License (MIT)
License Text ( https://github.com/HackerThemes/spur-template/blob/master/LICENSE )
Copyright 2016 - 2019 Alexander Rechsteiner
2 changes: 1 addition & 1 deletion aggregator/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@
<plugin>
<!-- keep for the case dependency-reduced pom is enabled -->
<artifactId>maven-clean-plugin</artifactId>
<version>3.1.0</version>
<version>${maven.clean.plugin.version}</version>
<executions>
<execution>
<id>clean-reduced-dependency-poms</id>
Expand Down
1 change: 1 addition & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -861,6 +861,7 @@
<hadoop.client.version>3.3.1</hadoop.client.version>
<scala.local-lib.path>org/scala-lang/scala-library/${scala.version}/scala-library-${scala.version}.jar</scala.local-lib.path>
<target.classifier>${spark.version.classifier}</target.classifier>
<maven.clean.plugin.version>3.1.0</maven.clean.plugin.version>
</properties>

<dependencyManagement>
Expand Down
4 changes: 4 additions & 0 deletions tools/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,7 @@
*.iml
target
event_log_profiling.log
## ignore qual-ui static files
**/ui/assets/
**/ui-dependencies-cache/
**/ui/js/data-output.js
96 changes: 96 additions & 0 deletions tools/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@
<spark.test.version>${spark311.version}</spark.test.version>
<spark.version.classifier>spark311</spark.version.classifier>
<target.classifier>spark311</target.classifier>
<ui.cache.dir>${project.build.directory}/ui-dependencies-cache</ui.cache.dir>
<ui.resources.relative>src/main/resources/ui</ui.resources.relative>
<ui.resources.dir>${project.basedir}/${ui.resources.relative}</ui.resources.dir>
<ui.resources.external.folder>assets</ui.resources.external.folder>
</properties>

<dependencies>
Expand Down Expand Up @@ -86,6 +90,14 @@
<resource>
<directory>${project.basedir}/src/main/resources</directory>
</resource>
<resource>
<directory>${project.basedir}/..</directory>
<targetPath>META-INF</targetPath>
<includes>
<!-- The NOTICE will be taken care of by the antrun task below -->
<include>LICENSE</include>
</includes>
</resource>
</resources>
<plugins>
<plugin>
Expand Down Expand Up @@ -138,6 +150,90 @@
<groupId>net.alchim31.maven</groupId>
<artifactId>scala-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>download-ui-dependencies</id>
<phase>generate-sources</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<property name="project.basedir" value="${project.basedir}"/>
<property name="project.build.directory"
value="${project.build.directory}"/>
<property name="project.cache.dir" value="${ui.cache.dir}"/>
<property name="project.ui.root" value="${ui.resources.dir}"/>
<property name="project.ui.output"
value="${ui.resources.dir}/${ui.resources.external.folder}"/>
<property name="lib.bootstrap.url"
value="https://github.com/twbs/bootstrap/releases/download/v4.6.1/bootstrap-4.6.1-dist.zip"/>
<property name="lib.bootstrap.dir" value="bootstrap"/>
<property name="lib.jquery.dir" value="jquery"/>
<property name="lib.jquery.url"
value="https://github.com/jquery/jquery/archive/refs/tags/3.6.0.zip"/>
<property name="lib.mustache.dir" value="mustache-js"/>
<property name="lib.mustache.url"
value="https://github.com/janl/mustache.js/archive/refs/tags/v4.1.0.zip"/>
<property name="lib.spur.dir" value="spur"/>
<property name="lib.spur.url"
value="https://github.com/HackerThemes/spur-template/archive/refs/heads/master.zip"/>
<property name="lib.datatables.url.domain"
value="https://cdn.datatables.net"/>
<property name="lib.datatables.dir" value="datatables"/>
<ant antfile="${project.basedir}/prepare-ui-libraries.xml"></ant>
</target>
</configuration>
</execution>
<execution>
<id>copy-notice</id>
<goals>
<goal>run</goal>
</goals>
<phase>process-resources</phase>
<configuration>
<target>
<!-- copy NOTICE-binary to NOTICE -->
<copy
todir="${project.build.directory}/classes/META-INF/"
verbose="true">
<fileset dir="${project.basedir}/..">
<include name="NOTICE-binary"/>
</fileset>
<mapper type="glob" from="*-binary" to="*"/>
</copy>
</target>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<!-- clean up the qual-ui dependencies from the resources -->
<artifactId>maven-clean-plugin</artifactId>
<version>${maven.clean.plugin.version}</version>
<executions>
<execution>
<id>clean-qual-ui-dependencies</id>
<phase>clean</phase>
<goals>
<goal>clean</goal>
</goals>
<configuration>
<filesets>
<fileset>
<directory>${ui.resources.relative}</directory>
<includes>
<include>${ui.resources.external.folder}/</include>
</includes>
</fileset>
</filesets>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
Loading

0 comments on commit 6a1fa70

Please sign in to comment.