Commit Graph

633 Commits

Author SHA1 Message Date
Riccardo Busetti
e9424b98de feat(replication): Delete destination and pipeline atomically (#37790) 2025-08-11 08:23:15 +02:00
Peter
c538c4dc6e database report: fix xlarge compute size max db connection in dashboard report (#37819)
* fix xlarge compute size max db connection in dashboard report

* pnpm format
2025-08-10 11:01:48 -05:00
Jordi Enric
5c28d11265 database report: fix keys in getConnectionLimits (#37795)
fix keys
2025-08-08 17:11:35 +02:00
Rodrigo Mansueli
edd4430432 Fix: database-cron-jobs-infinite-query.ts (#37792)
ORDER BY was before where
2025-08-08 15:40:35 +02:00
Riccardo Busetti
1ea8c656db feat(replication): Add new UI for new table state handling (#37662)
* feat(replication): Add new UI for new table state handling

* Fix

* Fix

* Fix

* Fix

* Fix

* Fix

* Fix

* Improve

* Fix

* Fix

* Fix TS

* Some UI tweaks

* Tweaaakk

* Fix semantics

* Small optimization

* Some adjustments

* Bit more fixes

* Small UI tweak to simplify UI

* Fixy fix

* gahhh tiny tiny tiny

* Last bit of cleanup

* I swear one final tweak

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-08-07 12:16:03 +02:00
Pamela Chia
a61927e790 feat: update dpa retrieval (#37563)
* feat: update dpa retrieval

* add tracking for other legal docs

* ci: Autofix updates from GitHub workflow

* update api types

* update pdf

* Refactor DPA with text confirm modal

* Nit consistency with using a and buttons

* Update TextConfirmModal

---------

Co-authored-by: pamelachia <26612111+pamelachia@users.noreply.github.com>
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-08-07 16:12:54 +08:00
Joshen Lim
cab0585533 Fe 1799/consolidate to useselectedprojectquery and (#37684)
* Replace all usage of useProjectContext with useSelectedProjectQuery

* Replace all usage of useSelectedProject with useSelectedProjectQuery

* Replace all usage of useProjectByRef with useProjectByRefQuery

* Replace all usage of useSelectedOrganization with useSelectedOrganizationQuery

* Deprecate useSelectedProject, useSelectedOrganization, and useProjectByRef hooks

* Deprecate ProjecContext
2025-08-06 10:53:10 +07:00
Terry Sutton
32b5d8c244 feat: enable Self-Service Single Sign-On (SSO) for orgs (#36732)
* Start

* Add join org logic

* Regenerate the API types and add RQ hooks.

* Various fixes to the UI for SSO config.

* Refactor the components to use RHF.

* Fix the loading/error states in the main file.

* fix: minor changes to SSO UI

* Expanded default attribute mapping preset for `Okta` to include `user_name`, `first_name`, and `last_name` to match our docs.
* Normalized role casing in the "Join Organization on Signup" dropdown to match the roles expected by the backend (`Owner`, `Administrator`, `Developer`).
* Added the role (`Read-only`) to the selectable roles for auto-join.
* Call update mutation when an `ssoConfig` has been retrieved.
* Treats `404` as a valid "create" flow state rather than an error.
* Conditionally renders the SSO config form when config is successfully loaded *or* when the provider is not found, allowing users to onboard from scratch and disable the provider.

* chore: prettier

* feat: add a button linking to SSO setup docs

* Revert "feat: add a button linking to SSO setup docs"

This will be included in a separate docs pr.

This reverts commit 0b616fdd2e.

* General clean up

* Nit copy

* Add empty state for SSO

* Smol change

* One last tweak

---------

Co-authored-by: Chris Stockton <180184+cstockton@users.noreply.github.com>
Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
Co-authored-by: Chris Stockton <chris.stockton@supabase.io>
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-08-05 17:03:30 -07:00
Joshen Lim
47249dc8b4 Add a CTA to run the command of the cron job (#37621) 2025-08-05 14:14:28 +07:00
Joshen Lim
0f4ad7dad3 Factor in filters and sorts for export via CLI option (#37399)
* Factor in filters and sorts for export via CLI option

* Add align

* Update

* Smol fix
2025-08-05 13:52:27 +07:00
Ivan Vasilov
61ccc28c58 fix: Add handling for single quotes in option values when creating FDW. (#37635)
Add handling for single quotes in option values when creating FDW.
2025-08-04 12:44:53 +07:00
Joshen Lim
310d2d575f Chore/cron fixes (#37626)
* Fix query to fetch cron jobs resulting in duplicate if job previous run succeeded, but latest failed

* Fix integration tabs child label

* Add a key to the rows in the data grid.

* Fix the small loading state when clicking the create cron job button.

* Wrap try catch around getDatabaseCronJob when validating cron job name

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2025-08-01 15:00:42 -02:30
Joshen Lim
58d6b4b912 Invalidate project upgrade eligibility query when disabling database extension (#37589)
* Invalidate project upgrade eligibility query when disabling database extension

* Add link to extension upgrade warning, link to extensions page with filter

* Swap a for Link
2025-08-01 10:53:06 +02:00
Joshen Lim
9a8bd0fae4 Chore/convert cron jobs to data grid (#37601)
* Use DataGrid for cron jobs interface instead of cards

* Deprecate CronJobCard and database-cron-jobs-run-query.ts

* Add tooltip for editing unnamed job

* Implement infinite scrolling to cron jobs + server side searching

* Deprecate database-cron-jobs-query, and add a singular database-cron-job-query

* Add hover card for cron job table cell command
2025-08-01 15:20:31 +08:00
Lenny
fbef43fbbc fix: use storage endpoint in S3 settings (#37469)
* fix: use storage endpoint in S3 settings

* Update retrieval of endpoint for analytics bucket related components

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-07-30 10:05:14 -04:00
Ivan Vasilov
b3c6992e56 feat: Make the protected schemas dynamic, namespace schemas are now protected (#37290)
* Add hooks for async protected schemas.

* Migrate the ProtectedSchemaWarning to support the new implementation.

* sq

* Migrate all uses of protected schemas to the new approach.

* Delete extra file.

* Refactor the import foreign schema dialog to forbid protected and exposed schemas.

* Add the type to the protected schema.

* Revert ImportForeignSchemaDialog, it'll be addressed in another PR.

* Update apps/studio/hooks/useProtectedSchemas.ts

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>

* Fix a bad commit.

* Minor fixes.

* Fix the FDW delete mutation to handle names with numbers.

* Simplify the logic to skip a fetch.

* Minor fixes.

* Make the useIcebergFdwSchemasQuery work for all iceberg FDWs.

* Fix the tab schemas to always show in the Table Editor.

* Apply suggestion from @joshenlim

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>

* Fix a minor typo.

* Refactor ProtectedSchemaWarning to use Admonition, and standardise input field for target schema iceberg

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-07-30 11:38:50 +02:00
Jordi Enric
c386daf3a0 add max cpu usage chart (#37532)
add max cpu usage
2025-07-29 16:20:05 +02:00
Joshen Lim
5da5ad06c0 Shift pipeline status page to its own route (#37431)
* Shift pipeline status page to its own route

* Fix back link
2025-07-29 16:33:14 +08:00
Jordi Enric
e4837267f6 Warehouse Clean Up (#37507) 2025-07-28 17:14:57 +02:00
Saxon Fletcher
4bfdbe32ac add with data field to branch (#37451)
* add with data field to branch

* Fix types

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-07-28 18:14:55 +08:00
Joshen Lim
d6fdb20a2a Fix visibility of edge fn charts for enterprise (#37401) 2025-07-28 18:01:54 +08:00
Ivan Vasilov
1bc28c7f85 feat: Add a toast to refresh the page if there's a new version of Studio available (#36323)
* Initial work.

* Add missing import.

* Minor fixes.

* Minor fixes.

* Add a feature flag for the refresh toast.

* Add a commit for testing. Revert before merging.

* Remove header caching for testing.

* Tiny lint

* Fix

* One more

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-07-28 17:51:00 +08:00
Stojan Dimitrovski
800d688d4c fix: api key mutations invalidate proper keys (#37467)
* fix: api key mutations invalidate proper keys

* Fix the RQ keys for API keys.

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2025-07-25 17:47:44 +02:00
Ivan Vasilov
32c3eeb389 feat: Create new schema when creating a FDW with the schema option (#37205)
* Change the import foreign schema to always create a schema.

* Fix the Iceberg wrapper.

* Refactor the create wrapper to always create a new schema.

* Remove unneeded props.

* Smol fixes

* Prevent double error toasts

* Smol fix

* Fix the wrapper creation to include the correct api key.

* Fix a bug with the new api keys.

* Handle both types of keys when fetching the iceberg namespaces.

* Add a field to all wrappers to hold the schema name which can import foreign schema.

* sq

* When importing a foreign schema, save the schema in a special field.

* Fix a type error.

* Fix importing foreign schema overriding wrapper server options with unencrypted values

* Add comment

* Handle duplicate and empty schemas when importing a foreign schema.

* Update the copy in the foreign schema wrappers.

* Remove unnecessary code.

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-07-25 10:54:17 +02:00
Riccardo Busetti
0ecddf1901 feat(replication): Implement UI to render pipeline replication status (#37376) 2025-07-24 13:04:07 +02:00
Kevin Grüneberg
740eeb8504 feat: mandatory address input for paying customers (#37337)
- Mandatory address input when adding a new payment method
- Removed the global HCaptcha store that wasn't used consistently and would sometimes block payment method changes
- Remove the custom billing address data & tax id form on org creation and plan upgrades in favour of Stripe's `AddressElement`
- Unify usage of the Stripe payment elements into a single component
- Customers can mark "Purchasing as a business" and will then be able to put down a tax id
- Adjusted billing address form to have better labels + tax id is filtered down to selected country
- Adjusted Stripe Elements styling to use floating labels (otherwise very hard to use with address element) + additional styling changes
- New flag to filter out payment methods that do not have an address for org upgrades and credit top ups, this will be enforced a few days after rolling this out
- Added Google Maps Places API integration for address auto-completion via Stripe AddressElement
- Upgraded Stripe dependencies
- Slight adjustments to styling of plan upgrade modal
2025-07-23 18:16:10 +08:00
Drake Costa
57cd26ac77 Move non-layout Storage components to components/interfaces (#37381)
* Update studio testing setup files

Improves API mocking type safety and polyfills browser APIs necessary to run tests with framer-motion components

* fix missing listen call for msw, resolve test type error

* fix imports

* Update studio testing setup files

Improves API mocking type safety and polyfills browser APIs necessary to run tests with framer-motion components

* fix missing listen call for msw, resolve test type error

* fix imports

* Move non-layout Storage related components to `components/interfaces`

* Fix paths

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-07-22 23:48:20 +08:00
Joshen Lim
31b8fbe487 Deprecate getAPIKeys from project settings v2, use new api keys endpoint instead (#37300)
* Deprecate getAPIKeys from project settings v2, use new api keys endpoint instead

* use getPreferredKeys where appropriate

* Prevent usage of secret key for storage and realtime inspector

* Add dashboard API api-keys endpoint

* Simplify

* Disable edge functions test if legacy api keys are disabled

* Revert

* Fix graphiql

* Remove all usage of api keys from project settings, except DisplayApiSettings

* Update

* Fix

* Small fix for an undefined upload url.

* Fix the storage state initialization when the resumable url changes.

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2025-07-22 16:22:03 +08:00
Joshen Lim
e70242f822 Chore/clean up assistant mcp feature flags (#36772)
* Clean up usage of newOrgAiOptIn and useBedrockAssistant feature flags

* Remove all OpenAI endpoints

* Fix for self-hosted

* Default isLimited to false

* Update PG meta tests

* Fix unit tests for model

* Revert pg meta tests

* Fix test

---------

Co-authored-by: Alaister Young <alaister@users.noreply.github.com>
2025-07-22 16:05:16 +08:00
Joshen Lim
dbb413beeb Chore/deprecate lib common fetch 03 (#36529)
* Deprecate use of getWithTimeout, refactor BuildingState and RestoringState to use RQ

* Refactor profile-create-mutation to use data/fetchers, and edge-function-status-query to use fetch

* Shift post from lib/common/fetch, refactor bucket-object-download-mutation

* Address feedback

* Minor fix

* Refactor post calls from lib/common/fetch in auth pages to data/fetchers

* Add missing POST users endpoint + small fix when deleting user via context menu

* Remove all use of any imports from lib/common/fetch

* Clean up remaining usage of lib/common/fetch

* Fix fetchHeadWithTimeout

* simplify handleFetchError

* allow handleFetchError to accept unknown

* non-breaking change

* small fixes

* fix query path

---------

Co-authored-by: Alaister Young <a@alaisteryoung.com>
2025-07-21 16:59:17 +08:00
Andrew Valleteau
4bd28eecb8 fix(api): set x-pg-application-name for dashboard (#37048)
chore(api): set x-pg-application-name for dashboard
2025-07-21 10:39:46 +02:00
Joshen Lim
b9a0908331 Refactor post calls from lib/common/fetch in auth pages to data/fetchers (#36506)
* Deprecate use of getWithTimeout, refactor BuildingState and RestoringState to use RQ

* Refactor profile-create-mutation to use data/fetchers, and edge-function-status-query to use fetch

* Shift post from lib/common/fetch, refactor bucket-object-download-mutation

* Address feedback

* Minor fix

* Refactor post calls from lib/common/fetch in auth pages to data/fetchers

* Add missing POST users endpoint + small fix when deleting user via context menu

* simplify handleFetchError

* allow handleFetchError to accept unknown

* non-breaking change

---------

Co-authored-by: Alaister Young <a@alaisteryoung.com>
2025-07-21 12:45:53 +08:00
Jonathan Summers-Muir
3feb843574 fix: restrict log inspection panel tab focus refetch (#37265)
* Update unified-log-inspection-query.ts

* Update unified-log-inspection-query.ts
2025-07-17 19:13:52 +00:00
Jordi Enric
dfacfd5137 Reports clean ups (#37248)
* use similar ui styles for different charts

* fix naming

* use similar styles, fix height

* rm year from tooltip timestamp

* remove unnecessary code in useChartData
2025-07-17 16:08:22 +02:00
Jonathan Summers-Muir
7d5dd5b6be Chore/logs reloading state (#37252)
* Add loading opacity and keep previous data for logs

Wrapped TimelineChart and DataTableInfinite in divs with opacity transition during data fetching for improved UX. Added keepPreviousData: true to unified logs chart, count, and infinite queries to retain previous data while fetching new results.

* Remove keepPreviousData from logs count query

The keepPreviousData option was removed from the useUnifiedLogsCountQuery hook to rely on default query behavior or custom options. This may affect how data is retained between queries.

* Update UnifiedLogs.tsx

* Refactor TimelineChart opacity handling

Moved opacity and transition classes from a wrapping div directly to the TimelineChart component for cleaner structure and improved conditional styling.
2025-07-17 13:49:04 +00:00
Cemal Kılıç
09fc7776b5 feat: update auth sign in report query (#37240)
* feat: update auth sign in report query

* fix chart config

* fix type error for custom properties in chart attributes

---------

Co-authored-by: Jordi Enric <jordi.err@gmail.com>
2025-07-17 15:45:44 +02:00
Francesco Sansalvadore
fb6f625707 chore: add docs for new db reports charts (#36703)
* chore: add docs for new db reports charts

* chore: fix linting issues

* move db reports docs to telemetry section

* add more info to reports docs

* fix lint suggestions

* update reports

* update latest links and chart screenshots

* advanced telemetry

* update db section
2025-07-17 12:40:12 +00:00
Joshen Lim
22f937c954 Chore/async filters for unified logs (#37200)
* Refactor retrieval of log counts

* Async filters

* Clean up

* Clean up

* Fix
2025-07-17 17:33:17 +08:00
Joshen Lim
65c6a683cd Make check-cname endpoint GET, and improve middleware checking (#37235) 2025-07-17 17:04:51 +08:00
Joshen Lim
96875d651e Fix create project default region not getting selected correctly on staging and staging previews (#37237) 2025-07-17 17:02:46 +08:00
Kang Ming
140d6026ab fix: update endpoint for cname check (#37210) 2025-07-17 09:28:34 +02:00
Francesco Sansalvadore
d58649375e db reports fix (#37208)
* restore flag check

* db connections charts

* clean up imports

* pooler label

* remove max on free db connections chart
2025-07-16 17:40:00 +02:00
Joshen Lim
bcf943ee88 Advisor rules update for LW15 (#37202)
* Advisor rules update for LW15

* Simplify UX to confirmation modal

* Rename section to settings

* fix

* patchy

* further simplify

* Smol styling fix

* Create + Delete lint rules to also invalidate lints
2025-07-16 22:20:08 +08:00
Francesco Sansalvadore
097ded6906 standardize db report (#37198)
* init standardization

* same charts

* clean up charts

* cleanup

* restore condition

* remove comment

* show availableIn placeholder
2025-07-16 12:29:01 +02:00
Ivan Vasilov
89c803551b feat: Analytic storage bucket (#37003)
* Migrate the CreateBucketModal to use RHF.

* Minor fixes for the create bucket modal.

* Use the bucket type from the API everywhere.

* Improve the types on some functions. Add "skip" mode to FDWCreateMutation.

* Expand the CreateBucketModal to explain what will happen when creating an iceberg bucket.

* Add a page for iceberg buckets.

* Add error states to the iceberg explorer.

* Fix the names for the FDWs.

* Add a dialog for setting up namespace.

* Restructure the new files.

* Add a download env button.

* Add warning to install the wrappers extension when creating an iceberg bucket.

* Add failover details when the FDW is not setup.

* Fix a lint error.

* Fix a type error.

* Minor fixes.

* Fix the server name.

* Add an icon for iceberg buckets.

* Fix the import foreign schema dialog.

* Make the setup wrapper button functional.

* Fix a bad useMemo dependency.

* Small changes to the iceberg bucket page.

* Minor fix for the edit wrapper sheet.

* Rename the files from kebab-case to PascalCase.

* Rename the files again to include Analytic instead of Iceberg.

* Rename Iceberg type to Analytic.

* Add a switch for creating namespace in the import foreign schema dialog.

* Fix the CreateBucketModal.

* Fix the delete modal feature.

* Fix the S3 keys in the FDW.

* Only create a namespace if the switch is true.

* Regenerate and fix the types.

* Fix the FDW create mutation to handle numbers in the FDW names.

* Make the icon smaller.

* Check whether the namespace exists, if it doesn't create it.

* Hide action from the analytic bucket which don't work.

* Invalidate namespaces when creating them.

* Add small explanation for the creation of namespaces.

* Minor fixes.

* Tons of changes to make the namespace feature work.

* Fix type errors.

* Fix bad import.

* Minor copy fixes.

* Replace the multiple cards with a table of namespaces.

* update copy icon

* tiny copy update

* Fix the empty state for foreign tables.

* Hide the analytics bucket option for self-hosted.

* Minor copy fixes.

* Expand the CTA on no namespaces state.

* More minor fixes.

* More small fixes.

---------

Co-authored-by: Alaister Young <a@alaisteryoung.com>
2025-07-15 14:18:38 +02:00
Joshen Lim
b4717e1787 Some fixes for local studio (#37147) 2025-07-15 17:22:23 +08:00
Jordi Enric
804f270c3a reports pricing (#36992)
* add database pricing config

* pricing paywalls

* fix showing correct charts

* fix test

* remove disabled helpers in favor of upsell dialog

* fix missing fn to calc time

* rm clog

* show badge next to helpers

* ui fix

* fix type errs

* fix hallucinated import fml
2025-07-14 16:45:29 +02:00
Jordi Enric
57edade445 database report: rename label (#37102)
rename
2025-07-14 15:35:24 +02:00
Stojan Dimitrovski
e0a3ab2c74 fix: additional fixes for api keys, jwt signing keys (#37069)
* fix: additional fixes for api keys, jwt signing keys

* Smol fix

* fix issue with screen

* Fix success handler for migrate JWT secret

* Tiny

* text fix

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-07-14 10:04:24 +02:00
Jordi Enric
ee843e162b format edgefn report exec time chart (#36976) 2025-07-10 14:55:17 +02:00