Skip to content

Package all resources into query_view_spa.html#24486

Merged
unidevel merged 3 commits intoprestodb:masterfrom
unidevel:fix_query_viewer
Feb 12, 2025
Merged

Package all resources into query_view_spa.html#24486
unidevel merged 3 commits intoprestodb:masterfrom
unidevel:fix_query_viewer

Conversation

@unidevel
Copy link
Contributor

@unidevel unidevel commented Feb 4, 2025

Description

After the pages optimized with chunk spliting, the query_viewer_spa.html will use split chunks instead of packing all resources as SPA page.

Motivation and Context

The pages under dev folder should not use split chunks, so that they can be easily adopted by other system.

The fix will introduce 2 set of configurations (mainConfig and spaConfig) to make both SPA and non SPA pages working as expected.

Impact

UI pages/build, especially the pages under '/dev/' folder

Test Plan

Build & test UI in dev/prod env

Contributor checklist

  • Please make sure your submission complies with our contributing guide, in particular code style and commit standards.
  • PR description addresses the issue accurately and concisely. If the change is non-trivial, a GitHub Issue is referenced.
  • Documented new properties (with its default value), SQL syntax, functions, or other functionality.
  • If release notes are required, they follow the release notes guidelines.
  • Adequate tests were added if applicable.
  • CI passed.

Release Notes

== NO RELEASE NOTE ==

@prestodb-ci prestodb-ci added the from:IBM PR from IBM label Feb 4, 2025
@unidevel
Copy link
Contributor Author

unidevel commented Feb 4, 2025

After build page, there are warnings about dev/query_viewer.js which is as expected, since we need the SPA pages under dev folder(can not be splitted).

WARNING in asset size limit: The following asset(s) exceed the recommended size limit (244 KiB).
This can impact web performance.
Assets:
  dev/query_viewer.js (674 KiB)
  vendor/vis-timeline/vis-timeline-graph2d.js (569 KiB)
  vendor/vis-timeline/vis-timeline-graph2d.min.js (565 KiB)
  vendor/vis-timeline/vis-timeline-graph2d.min.js.map (2.12 MiB)
  vendor/vis/dist/vis.js (433 KiB)
  vendor/vis/dist/vis.map (574 KiB)
  vendor/vis/dist/vis.min.js (434 KiB)
  dev/query_viewer_spa.html (825 KiB)

WARNING in entrypoint size limit: The following entrypoint(s) combined asset size exceeds the recommended limit (244 KiB). This can impact web performance.
Entrypoints:
  query_viewer (674 KiB)
      dev/query_viewer.js

Related fix => #24374

@unidevel unidevel marked this pull request as ready for review February 4, 2025 16:11
@unidevel unidevel requested review from a team and yhwang as code owners February 4, 2025 16:11
@unidevel unidevel requested a review from presto-oss February 4, 2025 16:11
yhwang
yhwang previously approved these changes Feb 4, 2025
Copy link
Member

@yhwang yhwang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
Thanks for the fix.

For the query_viewer.js, it is also used by the /dev/index.html in a normal cluster setup. However, we can have it with the warning at this moment.

yhwang
yhwang previously approved these changes Feb 4, 2025
@ethanyzhang
Copy link
Contributor

@unidevel @yhwang we ready to merge this?
Li can you merge?

@yhwang
Copy link
Member

yhwang commented Feb 11, 2025

@ethanyzhang we plan to land the ui-forwardfit PR first to avoid rebase on that one.

@unidevel
Copy link
Contributor Author

@yhwang I resolved the conflicts, fix some style issues in SPA page, can you help to review, thanks.

@unidevel unidevel merged commit 1c43927 into prestodb:master Feb 12, 2025
54 checks passed
jp-sivaprasad pushed a commit to jp-sivaprasad/presto that referenced this pull request Mar 10, 2025
* Package all resources into query_view_spa.html

* refactor filename for query_view_spa.html

* Resolve conflicts and fix spa page styles
@prestodb-ci prestodb-ci mentioned this pull request Mar 28, 2025
30 tasks
pradeepvaka pushed a commit to pradeepvaka/presto that referenced this pull request Apr 11, 2025
* Package all resources into query_view_spa.html

* refactor filename for query_view_spa.html

* Resolve conflicts and fix spa page styles
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

from:IBM PR from IBM

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants