Re: [HACKERS] Cache lookup errors with functions manipulation objectaddresses
| От | Alvaro Herrera |
|---|---|
| Тема | Re: [HACKERS] Cache lookup errors with functions manipulation objectaddresses |
| Дата | |
| Msg-id | 20170720140402.7nrm56yjig7q2r3r@alvherre.pgsql обсуждение исходный текст |
| Ответ на | Re: [HACKERS] Cache lookup errors with functions manipulation object addresses (Michael Paquier <michael.paquier@gmail.com>) |
| Ответы |
Re: [HACKERS] Cache lookup errors with functions manipulation object addresses
|
| Список | pgsql-hackers |
Michael Paquier wrote: > - getObjectDescription and getObjectIdentity are called in quite a > couple of places. We could have those have a kind of missing_ok, but > as the status is just for adding cache lookup errors I have kept the > interface simple as this keeps the code in objectaddress.c more simple > as well. getObjectIdentity is used mainly in sepgsql, which I have not > compiled yet so I may have missed something :) getObjectDescription is > used in more places in the backend code, but I am not much into > complicating the objaddr API with this patch more. I think the addition of checks everywhere for NULL return is worse. Let's add a missing_ok flag instead, so that most callers can just trust that they get a non null value if they don't want to deal with that case. -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
В списке pgsql-hackers по дате отправления: