Releases: PostgREST/postgrest
Releases Β· PostgREST/postgrest
devel
Added
- #3558, Add the
admin-server-host
config to set the host for the admin server - @develop7 - #3607, Log to stderr when the JWT secret is less than 32 characters long - @laurenceisla
- #2858, Performance improvements when calling RPCs via GET using indexes in more cases - @wolfgangwalther
- #3560, Log resolved host in "Listening on ..." messages - @develop7
- #3727, Log maximum pool size - @steve-chavez
Fixed
- #3693, Prevent spread embedding to allow aggregates when they are disabled - @laurenceisla
- #3693, A nested spread embedding now correctly groups by the fields of its top parent relationship - @laurenceisla
- #3693, Fix spread embedding errors when using the
count()
aggregate without a field - @laurenceisla- Fixed
"column reference <col> is ambiguous"
error when selecting?select=...table(col,count())
- Fixed
"column <json_aggregate>.<alias> does not exist"
error when selecting?select=...table(aias:count())
- Fixed
- #3727, Clarify "listening" logs - @steve-chavez
Changed
- #2052, Dropped support for PostgreSQL 9.6 - @wolfgangwalther
- #2052, Dropped support for PostgreSQL 10 - @wolfgangwalther
- #2052, Dropped support for PostgreSQL 11 - @wolfgangwalther
- #3508, PostgREST now fails to start when
server-port
andadmin-server-port
config options are the same - @develop7 - #3607, PostgREST now fails to start when the JWT secret is less than 32 characters long - @laurenceisla
- #3644, Fail schema cache lookup with invalid db-schemas config - @wolfgangwalther
- Previously, this would silently return 200 - OK on the root endpoint, but don't provide any usable endpoints.
- #3757, Remove support for
Prefer: params=single-object
- @joelonsql- This preference was deprecated in favor of Functions with an array of JSON objects
v12.2.3
Fixed
- #3091, Broken link in OpenAPI description
externalDocs
- @salim-b - #3659, Embed One-to-One relationship with different column order properly - @wolfgangwalther
- #3504, Remove
format
fromrowFilter
parameters in OpenAPI - @dantheman2865 - #3660, Fix regression that loaded the schema cache before the in-database configuration - @steve-chavez, @laurenceisla
v12.2.2
Fixed
- #3093, Nested empty embeds no longer show empty values and are correctly omitted - @laurenceisla
- #3644, Make --dump-schema work with in-database pgrst.db_schemas setting - @wolfgangwalther
- #3644, Show number of timezones in schema cache load report - @wolfgangwalther
- #3644, List correct enum options in OpenApi output when multiple types with same name are present - @wolfgangwalther
- #3523, Fix schema cache loading retry without backoff - @steve-chavez
v12.2.1
Fixed
- Don't reload schema cache unnecessarily when doing automatic recovery on Listener by @steve-chavez on #3147.
Documentation
- Architecture diagram now supports dark mode and has links by @laurenceisla on #3592
- The schema isolation diagram now supports dark mode and uses well-known schemas by @laurenceisla on #3616.
v12.2.0
Features
Observability
- Prometheus metrics by @steve-chavez in #1526
- More detailed logging by @steve-chavez in #3171, #3046, #3340, #3184
- log-level=debug by @steve-chavez and @laurenceisla in #3435, #3214, #3229
Listener
- Force the Listener to connect to the primary instance when using read replicas by @steve-chavez in #3414, #2781
API
- Preference
max-affected
to limit affected resources by @taimoorzaeem in #2887
Transactions
- db-hoisted-tx-settings to apply to function settings by @taimoorzaeem in #3242
Admin
- Dump the runtime configuration by @SkyWriter in #3171
- Dump the runtime schema cache by @taimoorzaeem in #3210
Performance
- Performance improvement on bulk json inserts, around 10% increase on requests per second by removing
json_typeof
from write queries by @steve-chavez in #2676.
Documentation
- Dark mode toggling (with a button on the bottom right corner) by @laurenceisla in #3289
- Architecture page by @steve-chavez in #3384
- CLI page by @taimoorzaeem in #3248
- Listener page by @laurenceisla and @steve-chavez in #3582
Errors
- Show extra information in the
PGRST121
error (could not parse RAISE 'PGRST') by @laurenceisla in #3404- Shows the failed MESSAGE or DETAIL in the
details
field - Shows the correct JSON format in the
hints
field
- Shows the failed MESSAGE or DETAIL in the
Fixes
- Dump media handlers and timezones with --dump-schema by @wolfgangwalther in #3237
- Don't hide error on LISTEN channel failure by @steve-chavez in #3323 and #3324
- Incorrect admin server
/ready
response on slow schema cache loads by @steve-chavez in #3330 - Fix in-database configuration values not loading for
pgrst.server_trace_header
andpgrst.server_cors_allowed_origins
by @laurenceisla in #3345 - Clarify the
PGRST121
(could not parse RAISE 'PGRST') error message by @laurenceisla in #3404 - Fix wrong
503 Service Unavailable
on pg error53400
by @taimoorzaeem in #3267 - Fix not adding
application_name
on all connection strings by @steve-chavez in #2985 - Admin
/live
and/ready
now differentiates a failure as 500 status by @steve-chavez in #3424- 503 status is still given when postgREST is in a recovering state
- Media Types are parsed case insensitively by @develop7 in #3478
- Fix listener silently failing on read replica by @steve-chavez in #3533 and #3536
- If the LISTEN connection fails, it's retried with exponential backoff
- Force listener to connect to read-write instances using
target_session_attrs
by @steve-chavez in #3414 - Fix incorrect
413 Request Entity Too Large
on pg errors54*
by @taimoorzaeem in #3255 - Remove verbosity from error logs starting with "An error occurred..." and replacing it with "Failed to..." by @laurenceisla in #3549
Deprecations
- Support for PostgreSQL versions 9.6, 10 and 11 is deprecated. From this on version onwards, PostgREST will only support non-end-of-life PostgreSQL versions. See https://www.postgresql.org/support/versioning/.
Prefer: params=single-object
is deprecated. Use a function with a single unnamed JSON parameter instead. - @steve-chavez
v12.0.3
Fixed
- #3149, Misleading "Starting PostgREST.." logs on schema cache reloading - @steve-chavez
- #3205, Fix wrong subquery error returning a status of 400 Bad Request - @steve-chavez
- #3224, Return status code 406 for non-accepted media type instead of code 415 - @wolfgangwalther
- #3160, Fix using select= query parameter for custom media type handlers - @wolfgangwalther
- #3361, Clarify PGRST204(column not found) error message - @steve-chavez
- #3373, Remove rejected mediatype
application/vnd.pgrst.object+json
from response - @taimoorzaeem - #3418, Fix OpenAPI not tagging a FK column correctly on O2O relationships - @laurenceisla
- #3256, Fix wrong http status for pg error
42P17 infinite recursion
- @taimoorzaeem
v12.0.2
Fixed
- #3124, Fix table's media type handlers not working for all schemas - @steve-chavez
- #3126, Fix empty row on media type handler function - @steve-chavez
v12.0.1
Fixed
- #3054, Fix not allowing special characters in JSON keys - @laurenceisla
- #2344, Replace JSON parser error with a clearer generic message - @develop7
- #3100, Add missing in-database configuration option for
jwt-cache-max-lifetime
- @laurenceisla - #3089, The any media type handler now sets
Content-Type: application/octet-stream
by default instead ofContent-Type: application/json
- @steve-chavez
v12.0.0
Features
API
-
Media Type Handlers by @steve-chavez in #2825, #3076
- New how-to for Providing HTML Content Using Htmx by @laurenceisla
-
Strict/Lenient handling for Prefer header by @taimoorzaeem in #2969
Authentication
- JWT Caching by @taimoorzaeem in #2928
Connection Pool
Errors
Observability
-
Server-Timing response header by @taimoorzaeem, @develop7, @laurenceisla in #2937, #2983, #3064, #3068
-
Log all internal database errors to stderr by @laurenceisla in #3067
Transactions
Fixes
API
-
Remove unnecessary count on RPC returning single row by @steve-chavez in #3015
-
HTTP status responses for upserts by @taimoorzaeem in #2926
PUT
returns201
instead of200
when rows are insertedPOST
withPrefer: resolution=merge-duplicates
returns200
instead of201
when no rows are inserted
Observability
-
Transaction-Scoped Settings are now shown clearly in the Postgres logs by @laurenceisla in #3032
- Shows
set_config('pgrst.setting_name', $1)
instead ofsetconfig($1, $2)
- Does not apply to role settings and
app.settings.*
- Shows
-
Display an actual TCP port app is bound to by @develop7 in #3034
-
Fix Acquision Timeout errors logging to stderr when
log-level=crit
by @laurenceisla in #3067
Breaking changes
API
- Removed raw-media-types config by @steve-chavez in #2825
- Can be done more granularly with Media Type Handlers now.
- Removed
application/octet-stream
,text/plain
,text/xml
builtin support for scalar results - @steve-chavez- Can be done with more flexibility with a Handler Function now.
- Removed default
application/openapi+json
media type for db-root-spec by @steve-chavez in #2825- Can be done by adding a media type for
application/openapi+json
and a Handler Function now.
- Can be done by adding a media type for
Transactions
- Removed db-use-legacy-gucs by @laurenceisla in #3032
- All PostgreSQL versions now use GUCs in JSON format for Headers, Cookies and JWT claims.
New Contributors
- @develop7 made their first contribution in #2946
- @omahs made their first contribution in #3044
- @timabdulla made their first contribution in #2925
Full Changelog: v11.2.2...v12.0.0
v11.2.2
Fixed
- #2824, Fix regression by reverting fix that returned 206 when first position = length in a
Range
header - @laurenceisla, @Strengthless