| From: | Jeff Davis <pgsql(at)j-davis(dot)com> |
|---|---|
| To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Erik Wienhold <ewie(at)ewie(dot)name> |
| Cc: | Murat Efendioğlu <mrtdmrts001(at)gmail(dot)com>, pgsql-bugs(at)lists(dot)postgresql(dot)org |
| Subject: | Re: Error when setting default_text_search_config |
| Date: | 2024-10-06 21:51:17 |
| Message-ID: | dac9094eac03d8eaff9e310aba336ec01fa3cf47.camel@j-davis.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-bugs |
On Sun, 2024-10-06 at 14:39 -0400, Tom Lane wrote:
> I suppose we could just move the InitializeSearchPath call up
> a bit (the comments in postinit.c are misleading about what it
> actually does), but I wonder whether the cache-is-valid assumptions
> in namespace.c ought to be rethought. It seems unduly fragile
> as-is.
I attached a patch which fixes the observed problem and is hopefully
more robust to similar issues.
The test for use_cache in check_search_path() is also somewhat
indirect. The goal there is to avoid calling GetUserId() before
CurrentUserId is valid, but that could probably be solved other ways or
commented better. I will look into it.
Regards,
Jeff Davis
| Attachment | Content-Type | Size |
|---|---|---|
| v1-0001-Fix-search_path-cache-approach-2.patch | text/x-patch | 2.1 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Devrim Gündüz | 2024-10-06 22:52:30 | Re: BUG #18631: Brocken postgresql12-devel RPM |
| Previous Message | Murat Efendioğlu | 2024-10-06 20:22:34 | Re: Error when setting default_text_search_config |