common/jsonapi: support libpq as a client
Peter Eisentraut <peter@eisentraut.org>
common/jsonapi: support libpq as a client Based on a patch by Michael Paquier. For libpq, use PQExpBuffer instead of StringInfo. This requires us to track allocation failures so that we can return JSON_OUT_OF_MEMORY as needed rather than exit()ing. Author: Jacob Champion <jacob.champion@enterprisedb.com> Co-authored-by: Michael Paquier <michael@paquier.xyz> Co-authored-by: Daniel Gustafsson <daniel@yesql.se> Reviewed-by: Peter Eisentraut <peter@eisentraut.org> Discussion: https://www.postgresql.org/message-id/flat/d1b467a78e0e36ed85a09adf979d04cf124a9d4b.camel@vmware.com
Files
| Path | Change | +/− |
|---|---|---|
| src/common/jsonapi.c | modified | +348 −125 |
| src/common/Makefile | modified | +19 −4 |
| src/common/meson.build | modified | +31 −4 |
| src/include/common/jsonapi.h | modified | +14 −4 |
| src/test/modules/test_json_parser/Makefile | modified | +5 −2 |
| src/test/modules/test_json_parser/meson.build | modified | +12 −0 |
| src/test/modules/test_json_parser/t/001_test_json_parser_incremental.pl | modified | +15 −10 |
| src/test/modules/test_json_parser/t/002_inline.pl | modified | +95 −82 |
| src/test/modules/test_json_parser/t/003_test_semantic.pl | modified | +19 −12 |
Discussion
- [PoC] Federated Authn/z with OAUTHBEARER 429 messages · 2021-06-08 → 2025-08-08