You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "ajeydudhe (via GitHub)" <gi...@apache.org> on 2024/09/24 10:15:52 UTC
[I] [Pinot 1.2.0 UI] No support for "database" construct from UI [pinot]
ajeydudhe opened a new issue, #14068:
URL: https://github.com/apache/pinot/issues/14068
### Problem statement
Pinot 1.2.0 supports **_database_** constructs as mentioned [here](https://docs.pinot.apache.org/basics/releases/1.2.0#support-for-logical-database-in-v2-engine-12591-12695).
However, the UI does not allow creating a table using a **_database_** or querying a table within a **_database_**.
### Steps to reproduce
- Launch the Pinot 1.2.0 controller UI.
- On the table screen there is no option to create table within a **_database_**.
- Create a table using REST API passing the **_database_** http header.
- Now, try to query above table using the UI passing the **_database_** as below:
```shell
SET database='testDb';
select * from myTable limit 10;
```
- Above query gives following error:
```
Database name 'testDb' from table prefix does not match database name 'default' from header
```
--
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: commits-unsubscribe@pinot.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
Re: [I] [Pinot 1.2.0 UI] No support for "database" construct from UI [pinot]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #14068:
URL: https://github.com/apache/pinot/issues/14068#issuecomment-4940747179
This issue has been closed because it has been inactive for 180 days. If you believe this issue is still relevant, please feel free to reopen it or create a new issue. Thank you!
--
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: commits-unsubscribe@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
Re: [I] [Pinot 1.2.0 UI] No support for "database" construct from UI [pinot]
Posted by "Jackie-Jiang (via GitHub)" <gi...@apache.org>.
Jackie-Jiang commented on issue #14068:
URL: https://github.com/apache/pinot/issues/14068#issuecomment-2372403980
Thanks for reporting this. cc @jayeshchoudhary
--
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: commits-unsubscribe@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
Re: [I] [Pinot 1.2.0 UI] No support for "database" construct from UI [pinot]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #14068:
URL: https://github.com/apache/pinot/issues/14068#issuecomment-4665440581
This issue has been automatically marked as stale because it has not had any activity in the last 150 days. It will be closed in 30 days if no further activity occurs. If this issue is still relevant, please leave a comment to keep it open. Thank you for your contributions!
--
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: commits-unsubscribe@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
Re: [I] [Pinot 1.2.0 UI] No support for "database" construct from UI [pinot]
Posted by "NihalJain (via GitHub)" <gi...@apache.org>.
NihalJain commented on issue #14068:
URL: https://github.com/apache/pinot/issues/14068#issuecomment-2464606418
### Proposal to Contribute a Fix for Database Support in Pinot 1.2.0 UI
I came across this issue where in Pinot 1.2.0 the UI does not support creating or querying tables apart from the 'default' database. I propose to fix this issue by enhancing the REST API and updating the UI accordingly. (I am a backend developer with little UI experience, but the changes seem manageable.)
#### Problem Statement
- Pinot 1.2.0 supports database constructs, but the UI does not allow creating tables within a database or querying tables within a database.
- The REST API currently returns only resources attached to the default database unless explicitly specified.
#### Proposed Solution
1. **Enhance REST API to support fetching resources for all databases for all relevant APIs**:
- Modify the REST API to support fetching all tables/schemas/etc. irrespective of the database name.
- Modify the existing endpoint to accept a wildcard (`*`) for the database header to return resources from all databases.
Example:
```sh
curl -X GET \
http://localhost:9000/tables \
-H 'Accept: application/json' \
-H 'database: *'
```
2. **Update the Pinot controller UI**:
- Allow creating tables within any database by introducing a new, optional, input field 'Database'.
- Allow creating schemas within any database by introducing a new, optional, input field 'Database'.
- Modify the UI to fetch tables/schemas/etc. for all databases by setting the database to `*` in the UI context.
3. **Support for db.table Queries**:
- Implement support for queries in the format `db.table` in the UI.
- Ensure that the UI sets the appropriate database context before executing queries.
4. **Additional Tasks**:
- Add more tasks as needed, based on deeper insights into the codebase.
#### PoC:
I just tried doing a PoC of this by changing the behavior of the table API to return all tables when no database is specified. See results:
Create 2 tables with same name in different DBs, here's the output.
- 
- 
- 
#### Conclusion
By implementing these changes, we can enhance the functionality of the Pinot UI and REST API to support database constructs more effectively. This will simplify the process for users working with multiple databases within the same cluster. I am eager to contribute to this project and look forward to your feedback on this proposal.
Thank you for considering my proposal.
Best regards,
Nihal Jain
--
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: commits-unsubscribe@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
Re: [I] [Pinot 1.2.0 UI] No support for "database" construct from UI [pinot]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed issue #14068: [Pinot 1.2.0 UI] No support for "database" construct from UI
URL: https://github.com/apache/pinot/issues/14068
--
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: commits-unsubscribe@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
Re: [I] [Pinot 1.2.0 UI] No support for "database" construct from UI [pinot]
Posted by "NihalJain (via GitHub)" <gi...@apache.org>.
NihalJain commented on issue #14068:
URL: https://github.com/apache/pinot/issues/14068#issuecomment-2915013770
> What is the usecase for showing tables/schemas across all databases in one view?
We want to do this because as an ADMIN i may want a single view of the cluster and all its resources.
> Can we have a place on UI to set the database name context globally which gets passed in headers for all the relevant APIs? We already have an API that lists all the database names.
> I am more inclined to a user flow where user is required to set the database context first and then proceed to do any operations, same flow that's followed by other standard SQL CLIs where we are required to set the database/catalog context before doing any operation.
Sure I agree for task 2 onwards we should have a flow where all user CRUD is tied to a particular DB.
--
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: commits-unsubscribe@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
Re: [I] [Pinot 1.2.0 UI] No support for "database" construct from UI [pinot]
Posted by "NihalJain (via GitHub)" <gi...@apache.org>.
NihalJain commented on issue #14068:
URL: https://github.com/apache/pinot/issues/14068#issuecomment-2470803785
Hi @ajeydudhe, @Jackie-Jiang, @shounakmk219, @npawar Any thoughts?
--
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: commits-unsubscribe@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
Re: [I] [Pinot 1.2.0 UI] No support for "database" construct from UI [pinot]
Posted by "shounakmk219 (via GitHub)" <gi...@apache.org>.
shounakmk219 commented on issue #14068:
URL: https://github.com/apache/pinot/issues/14068#issuecomment-2472313806
Hey @NihalJain thanks a lot for taking this up!
Few questions
1. What is the usecase for showing tables/schemas across all databases in one view?
2. Can we have a place on UI to set the database name context globally which gets passed in headers for all the relevant APIs? We already have an API that lists all the database names.
I am more inclined to a user flow where user is required to set the database context first and then proceed to do any operations, same flow that's followed by other standard SQL CLIs where we are required to set the database/catalog context before doing any operation.
This will also ensure that we are not required to prefix the table name with database name while building query on UI.
Let me know your thoughts.
Thanks!
--
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: commits-unsubscribe@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org