Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance web UX dev experience #21560

Merged
merged 1 commit into from
Dec 18, 2023
Merged

Conversation

yhwang
Copy link
Member

@yhwang yhwang commented Dec 17, 2023

Description

Use webpack-dev-server to serve the web UI
and proxy the server APIs to a Presto server.
In this case, you can leverage an external Presto
server or use docker to spin up a Presto server and
focus on UX development.

Related to: #21062

Motivation and Context

When working on pure UX changes, No need to build the whole project to run the presto-server.
Instead, you can use docker to run a presto-server to handle the API calls.
This could be used in the verification of UX changes as well.

Impact

N/A

Test Plan

Manually verify the webpack dev server with an external Presto server

Contributor checklist

  • Please make sure your submission complies with our development, formatting, commit message, and attribution guidelines.
  • 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

Please follow release notes guidelines and fill in the release notes below.

== NO RELEASE NOTE ==

@yhwang yhwang requested a review from a team as a code owner December 17, 2023 22:26
@yhwang yhwang requested a review from presto-oss December 17, 2023 22:26
@yhwang yhwang mentioned this pull request Dec 17, 2023
17 tasks
@yhwang yhwang changed the title Ehance web UX dev experience Enhance web UX dev experience Dec 17, 2023
Use `webpack-dev-server` to serve the web UI
and proxy the server APIs to a Presto server.
In this case, you can leverage an external Presto
server or use docker to spin up a Presto server and
focus on UX development.

Signed-off-by: Yihong Wang <[email protected]>
@yhwang
Copy link
Member Author

yhwang commented Dec 18, 2023

I used docker to spin up a Presto server listening on port 8888 and use the following command to launch the dev server:

yarn --cwd presto-main/src/main/resources/webapp/src run serve --env=apiPort=8888

The dev server was listening on port 8080 and forwarding the API calls to port 8888.
I issued a simple query against the TPCH catalog:
Screenshot 2023-12-17 at 3 59 01 PM

@tdcmeehan tdcmeehan requested a review from alonsovb December 18, 2023 15:26
@tdcmeehan
Copy link
Contributor

@alonsovb can you and your team give this a quick review--thank you!

@tdcmeehan tdcmeehan self-assigned this Dec 18, 2023
Copy link

@alonsovb alonsovb left a comment

Choose a reason for hiding this comment

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

looks good!

Copy link

@jorgeramirezamora jorgeramirezamora left a comment

Choose a reason for hiding this comment

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

LGTM!

@tdcmeehan tdcmeehan merged commit f130180 into prestodb:master Dec 18, 2023
51 checks passed
@yhwang yhwang deleted the web-proxy-4-dev branch February 18, 2025 20:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants