Wolfgang Walther and GitHub
be674eb41d
Fix POST, PATCH, DELETE with ?select= and empty body or return=minimal ( #1471 )
...
* add tests for POST, PATCH, DELETE when using ?select= with empty bodies or ret=min
* fix select with empty bodies and ret=min
* improved tests for default cases, fixed computed overloaded columns on empty-body?select= PATCH
2020-04-13 12:32:35 -05:00
Wolfgang Walther and GitHub
c524531784
Fix overloaded computed columns on RPC ( #1473 )
...
* fix some typos and spelling
* fix pg_source CTE name should be prefixed with pgrst_
* added tests for overloaded computed columns on patch calls
2020-04-06 14:04:55 -05:00
steve-chavez
2b61a63686
Bump to version v7.0.0
2020-04-03 11:22:11 -05:00
691bb5640d
Allow multiple schemas to be exposed in one instance ( #1450 )
...
The schema to use can be selected through the headers `Accept-Profile` for GET/HEAD and `Content-Profile` for POST/PATCH/PUT/DELETE.
This is based on the https://www.w3.org/TR/dx-prof-conneg/ttps://www.w3.org/TR/dx-prof-conneg/ spec.
Also increase all memory tests by 1M(otherwise CI fails).
Co-authored-by: Mahmoud Kassem <MKassem@gk-software.com >
Co-authored-by: Mahmoud Kassem <mahmoud_k@mail.com >
2020-03-30 14:04:20 -05:00
steve-chavez
b75e7cef90
Change server-proxy-uri 2 openapi-server-proxy-uri
...
The server-proxy-uri config option mislead into thinking it was a
web server global setting when it's only related to OpenAPI.
2020-02-02 15:23:32 -05:00
steve-chavez
9b1224827a
Allow overriding headers Location,Content-Type,etc
2020-01-21 12:28:05 -05:00
steve-chavez
c7f78fa7fc
Add response.headers on GET/POST/PATCH/PUT/DELETE
2020-01-21 12:28:05 -05:00
steve-chavez
7dade7f466
Add request method and path GUCs
2020-01-21 12:28:05 -05:00
steve-chavez
b20e1150a5
Add GUC for accessing the Authorization header
2020-01-21 12:28:05 -05:00
Steve Chavez and GitHub
663faa1f82
Allow specifying the constraint name to disambiguate an embedding ( #1430 )
...
Makes previous duck typing regex unnecessary since the FK can be renamed
to a singular name or to any other format.
* Remove embedding with duck typed column names
* Allow embedding by foreign key name
* Add junction disambiguation tests
2020-01-06 09:42:33 -05:00
YUKISHITA Yohsuke and Steve Chavez
99b13fa25f
Upsert with "Prefer: resolution=merge-duplicates" on specified columns ( #1327 ) ( #1432 )
...
Allow query param 'on_conflict=key1,key2,...' to upsert with explicit columns with unique
constraint.
2019-12-29 11:52:58 -05:00
Dmitry Wagin and Steve Chavez
e12c1319b6
Change default server-unix-socket-mode 755 -> 660 ( #1423 )
2019-12-16 08:37:00 -05:00
Dmitry Wagin and Steve Chavez
7f365bf60b
Enforce singular behavior despite Prefer: return ( #1417 )
2019-12-08 01:49:20 -05:00
Dan Amoroso and Steve Chavez
2e6c78d723
add config option server-unix-socket-mode ( #1415 )
...
* added config option server-unix-socket-mode to enable custom socket permissions
* added server-unix-socket-mode input validation
2019-11-23 10:52:33 -05:00
steve-chavez
9847e60dca
Err embedding when multiple relationships found
...
When having one-to-many relationships like:
person -< message[sender]
person -< message[recipient]
person_detail -< message[sender]
person_detail -< message[recipient]
Where person_detail is a view of person.
This request:
GET "/message?select=*,sender(*)"
Is ambiguous. Both person or person_detail could be embedded.
Until now we have returned the first detected relationship but
now we return a 300 Multiple Choices error with a
descriptive error message asking the user to disambiguate.
This is more helpful for the user and also aids in cases of more
complex relationships.
2019-11-05 12:55:48 -05:00
Steve Chávez and GitHub
80f763448f
Fix unique foreign key in view ( #1395 )
2019-10-16 12:45:38 -05:00
steve-chavez
ed2bfc09a6
Allow PATCH/DELETE w/o Prefer when no SELECT privs
...
PATCH/DELETE can now be done without adding Prefer return=minimal when
the user doesn't have SELECT privileges.
* Also fix PATCH wrong HTTP status code
2019-10-08 12:41:39 -05:00
steve-chavez
75a42b77ea
Fix M2M resource embedding on RPC and mutations
2019-09-28 13:45:18 -05:00
steve-chavez
94f5894d7f
Fix self join resource embedding on PATCH
2019-09-28 13:45:18 -05:00
Steve Chávez and GitHub
186381bab2
Add support for Prefer: count=planned/estimated on GET /table ( #1386 )
2019-09-18 10:13:48 -05:00
steve-chavez
e044488f73
Make costly bulk call query optional
...
Bulk Call should be used by specifying
the `Prefer: params=multiple-objects` header.
2019-09-11 12:01:41 -05:00
steve-chavez
620721dea7
Add support for HEAD request
2019-09-03 13:38:53 -05:00
Steve Chávez and GitHub
713b214c9a
Bump to version v6.0.2
...
* Add missing CHANGELOG entry for #1368
2019-08-22 11:12:01 -05:00
steve-chavez
ae9e27a0c7
Fix #1348 , go back to converting plus "+" to space
...
Not doing this conflicts with some http clients and proxies.
Use the alternative url-safe character '!' instead for
disambiguating resource embedding.
2019-08-21 10:34:28 -05:00
Dan Amoroso and Steve Chávez
d5758523f3
Change raw-media-types to accept a string of comma separated MIME types ( #1370 )
2019-08-06 13:23:52 -05:00
steve-chavez
47c0141c49
Bump to v6.0.1
2019-07-30 22:34:28 +00:00
steve-chavez
e7544687d1
Fix/organize latest entries in CHANGELOG
2019-07-30 22:34:28 +00:00
Dan Amoroso and Steve Chávez
f5cef205f1
Introduced raw-media-types config option ( #1349 )
...
* extracted rawOutputTypes to config variable raw-output-media-types
* removed CTTextHtml from Types.hs
2019-07-22 23:37:53 +00:00
Eduardo Jorge and Steve Chávez
e639c77aa2
Add websearch_to_tsquery support ( #1339 )
2019-07-08 13:25:58 -05:00
Steve Chávez and GitHub
dd86fe372c
Bump to v6.0.0 ( #1329 )
...
* Also update BACKERS.md
2019-06-21 13:11:48 -05:00
Steve Chávez and GitHub
ea7d747107
Accept text/plain and text/html for raw output ( #1330 )
2019-06-21 11:51:54 -05:00
Steve Chávez and GitHub
1df749a7a8
Add option for overriding root spec ( #1317 )
...
* Only for pg >= 9.6
* Disallow specifying schema on root-spec
* Increase memory test upper bound
2019-06-10 13:45:50 -05:00
Dan Amoroso and Steve Chávez
78e5677fbe
Add server-unix-socket config option ( #1303 )
...
Add ncat workaround to test socket connection on CircleCI
2019-06-05 12:57:47 -05:00
Xavier Francisco and Steve Chávez
1cf54e6575
Small refactor around error responses and more tests ( #1282 )
...
* Fix #880 , Clean and consolidate error responses
* Fix #1285 , Abort on fatal errors
* Add / Detail tests
2019-05-22 09:30:33 -05:00
steve-chavez
3c7738a8c7
Deprecate '.' for disambiguating resource embedding
...
'+' should be used instead.
2019-05-19 13:18:03 -05:00
steve-chavez
181b608c04
Change server-host default of 127.0.0.1 to !4
...
This way the server works in LAN settings by default.
2019-05-19 13:18:03 -05:00
steve-chavez
37de12d376
Remove support for schema reloading with SIGHUP
...
SIGUSR1 should be used instead
2019-05-19 13:18:03 -05:00
Xavier Francisco and Steve Chávez
d32f373e1e
Add config option for pool timeout ( #1280 )
2019-04-25 12:23:20 -05:00
steve-chavez
2044f77d49
Fix #1273 , don't ignore RPC arguments by default
...
* Add different error message for pg 9.4
2019-04-19 16:03:42 -05:00
Xavier Francisco and Steve Chávez
74e38a1d80
Fix invalid SQL generated for bulk upsert with empty array ( #1270 )
2019-04-12 23:26:36 -05:00
steve-chavez
bdfb11001e
Fix #1264 , allow bulk RPC call
2019-04-05 19:10:00 -05:00
fpusch and Steve Chávez
cefbe8f07f
Add numeric and character types to OpenAPI spec ( #1259 )
...
* Add numeric and character types
* Remove decimal type mapping
It is treated as numeric by PostgreSQL so the mapping was redundant.
2019-03-29 11:09:42 -05:00
Vitor Baptista and Steve Chávez
9387e70b66
Fixes #1239 , support resource embedding on materialized views
2019-03-14 16:59:55 -05:00
steve-chavez
1f513f24a5
Fix #1242 , embed a view having a select in a where
2019-03-09 16:03:26 -05:00
steve-chavez
c9b2830e52
Fix #690 , add columns query arg for RPC/POST/PATCH
...
* Refactor normalizing json CTE
* Refactor CTE to use CASE instead of UNION
2019-02-26 11:38:21 -05:00
steve-chavez
673aa25082
Fix #1221 , embedding when having a self join
2019-02-04 10:22:02 -05:00
Steve Chávez and GitHub
04ab0ea753
Fix #1223 , incorrect OpenAPI externalDocs url ( #1232 )
2019-01-25 12:04:36 -05:00
steve-chavez
1e732ac94a
Bump to v5.2.0
2018-12-12 18:59:10 -05:00
steve-chavez
6b2778749f
Add ability to quote column names on filters
2018-12-12 12:07:30 -05:00
steve-chavez
36f86827ee
Fix #1008 , Handle columns that contain spaces
2018-12-12 12:07:30 -05:00