[TZF-260079] Add admin-only LanceDB explorer - #82
Conversation
…/tz-fabric into feature/TZF-260079
|
Also I see there are changes in |
|
do not call lance db directly when user logged in instead give a place to add path of lancedb and then it will read and scan |
|
|
||
| const localSource = { | ||
| storage: "local" as const, | ||
| location: "C:\\data\\fabric.lancedb", |
LanceDB Admin Explorer — Setup & UsageThis PR adds the LanceDB Admin Explorer for inspecting LanceDB databases from:
The explorer is designed to be usable by any developer/team member after configuring the required backend environment variables. No machine-specific paths or credentials are hardcoded.
1. Backend Environment SetupFrom the repository: For local development, make sure the backend environment file exists. For example: Configure the following values as required. Common configuration
The value configured in: is the secret that must be entered on the LanceDB Explorer login page. It is separate from AWS/R2 credentials. 2. Local LanceDB ConfigurationLocal mode does not require AWS/R2 credentials. The backend uses the project's configured LanceDB database directory: The expected structure is similar to: To check which local LanceDB tables are currently available: Example: ImportantDo not provide the complete The explorer connects to the LanceDB database directory and then discovers the tables contained inside it. Therefore: The user does not need to manually enter the local path in the admin UI. Select: and click: The backend will use the configured local database location and return the available tables. 3. Amazon S3 SetupTo enable Amazon S3 support, configure these values in the backend environment: Example region: Credentials stay entirely on the backend. S3 — Database at bucket rootIf the LanceDB database is stored directly at the configured bucket root: then in the Admin Explorer: Leave the database-location field empty and click: The backend will use: automatically. S3 — Database inside a prefix/folderIf the layout is: enter: Example: Do not enter AWS credentials in this field. 4. Cloudflare R2 SetupCloudflare R2 uses an S3-compatible API, which is why LanceDB locations still use the Configure R2 on the backend: If used elsewhere by the application, the CDN URL can also be configured:
Important distinctionThis: is the R2 API endpoint. It belongs in: It should not be entered into the Admin Explorer's database-location field. 5. R2 — Database at bucket rootIf R2 contains: select: Leave the database-location field empty and click: The backend automatically uses: No Cloudflare credentials need to be provided through the browser. 6. R2 — Database inside a prefix/folderFor an R2 structure such as: enter the LanceDB database location as: Then click: Do not enter: The HTTPS endpoint is backend configuration, not a database location. 7. Why R2 Uses an |
| Storage | Admin-page location | Backend configuration |
|---|---|---|
| Local | No path required | Uses configured local DATABASE_PATH |
| S3 bucket root | Leave empty | AWS_BUCKET_NAME + AWS credentials |
| S3 prefix | s3://bucket/path | AWS credentials |
| R2 bucket root | Leave empty | R2_BUCKET_NAME + R2_ENDPOINT + R2 credentials |
| R2 prefix | s3://bucket/path | R2 endpoint + R2 credentials |
Example
Local: Storage = Local database Location = N/AS3:
Storage = Amazon S3
Location = s3://my-bucket/lancedb
R2:
Storage = Cloudflare R2
Location = s3://my-r2-bucket/lancedb
For both S3 and R2, the location points to the LanceDB database directory/prefix containing the .lance tables, rather than to an individual .lance table.
|
Also create a separate markdown file for lancedb explorer not just under PR; how to make it work with screenshots |









Summary
Closes #79
Adds a secure, read-only LanceDB Explorer that allows administrators to inspect LanceDB tables, schemas, metadata, paginated rows and vector details from a private application route.
Screenshots
Administrator access gate
LanceDB table overview
Row and vector details
Backend changes
GET /api/v1/admin/lancedb/tablesGET /api/v1/admin/lancedb/{table_name}GET /api/v1/admin/lancedb/{table_name}/rowsGET /api/v1/admin/lancedb/{table_name}/rows/{row_id}X-Internal-SecretFrontend changes
/admin/lancedbSecurity
X-Internal-SecretINTERNAL_API_KEYValidation
Backend
Frontend
Merge target
This PR is raised against
develop.