databendlabs / bendsql

Databend Native Client
Apache License 2.0
49 stars 26 forks source link

feat: Add `explain analyze graphical` feature for SQL performance visualization #484

Closed Maricaya closed 1 week ago

Maricaya commented 1 month ago

https://github.com/user-attachments/assets/fe276f03-a176-43a2-9b9a-8097201dda12

Chasen-Zhang commented 1 month ago

Please remove the "✨" in the title.

Chasen-Zhang commented 1 month ago

The contributor is from the Summer of Open Source Promotion Plan. Please help with the review when it is ready. @PsiACE @zhang2014 @everpcpc

Chasen-Zhang commented 3 weeks ago

Please resolve the conflict first @Maricaya

Chasen-Zhang commented 2 weeks ago

@sundy-li Request to merge into the main branch, thanks!

sundy-li commented 2 weeks ago

@sundy-li Request to merge into the main branch, thanks!

do we need to wait for another pr in databend?

@Maricaya please add frontend/** to licenserc.toml to fix the license check.

Chasen-Zhang commented 2 weeks ago

@sundy-li Request to merge into the main branch, thanks!

do we need to wait for another pr in databend?

@Maricaya please add frontend/** to licenserc.toml to fix the license check.

Let's wait for the databend pr to merge into the main branch

Maricaya commented 2 weeks ago

@sundy-li Request to merge into the main branch, thanks!

do we need to wait for another pr in databend? @Maricaya please add frontend/** to licenserc.toml to fix the license check.

Let's wait for the databend pr to merge into the main branch

got it!

Chasen-Zhang commented 2 weeks ago

@sundy-li This PR https://github.com/databendlabs/databend/pull/16543 is already in the main branch.

Maricaya commented 1 week ago

@sundy-li this PR is ready, would you mind merging it?

sundy-li commented 1 week ago

@Maricaya Ok, It will be merged after ci pass.

please commit after you check it in local:

cargo fmt --all -- --check
typos
..
sundy-li commented 1 week ago

@Maricaya Thanks for the contribution.

Some comments about this pr.

I checked the codes and looks like it will start a new server to listen to a free port in each graphical query, this may cause too much port resource usage.

  1. Can we start a dedicated HTTP server as a service if it's is_repl is true?
  2. If we receive graphical query in is_repl mode, we can generate a random URL to render the data for this query.
PsiACE commented 1 week ago

cool, glad to see this project has landed, thanks @Maricaya @Chasen-Zhang @sundy-li

Maricaya commented 1 week ago

@Maricaya Thanks for the contribution.

Some comments about this pr.

I checked the codes and looks like it will start a new server to listen to a free port in each graphical query, this may cause too much port resource usage.

  1. Can we start a dedicated HTTP server as a service if it's is_repl is true?
  2. If we receive graphical query in is_repl mode, we can generate a random URL to render the data for this query.

Got it, thanks for the feedback. Let me finish the CI process first. Here's the PR: https://github.com/databendlabs/bendsql/pull/486. I'll let you know once it's ready.