Re: [PATCH] Generalized JSON output functions
От | Shulgin, Oleksandr |
---|---|
Тема | Re: [PATCH] Generalized JSON output functions |
Дата | |
Msg-id | CACACo5Qhy31ZCcwruYPfxVn2itHoju=cKBz9hN-ZKZS6dVCzUQ@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: [PATCH] Generalized JSON output functions (Pavel Stehule <pavel.stehule@gmail.com>) |
Ответы |
Re: [PATCH] Generalized JSON output functions
|
Список | pgsql-hackers |
1. comments - missing comment for some basic API, basic fields like "key_scalar" and similarMy objections:2. I have to fix a typo in hstore_io.c function (update attached), other (patching, regress tests) without problems1. I reread a previous discussion and almost all are for this patch (me too)HiI am sending review of this patch:
I thought it was pretty obvious from the code, because it's sort of the only source for docs on the subject right now. Should we add proper documentation section, this would have been documented for sure.
instead2. why you did indirect call via JsonOutContext?What is benefit
dst.value(&dst, (Datum) 0, JSONTYPE_NULL, InvalidOid, InvalidOid, false);
json_out_value(&dst, ....)
For consistency. Even though we initialize the output context ourselves, there might be some code introduced between json_out_init_context() and dst.value() calls that replaces some of the callbacks, and then there would be a difference.
3. if it should be used everywhere, then in EXPLAIN statement too.
Ahh.. good catch. I'll have a look on this now.
Thanks for the review!
--
Alex
В списке pgsql-hackers по дате отправления: