From: | Masahiro Ikeda <ikedamsh(at)oss(dot)nttdata(dot)com> |
---|---|
To: | Michael Paquier <michael(at)paquier(dot)xyz> |
Cc: | Andres Freund <andres(at)anarazel(dot)de>, Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>, Tristan Partin <tristan(at)neon(dot)tech>, pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: Support to define custom wait events for extensions |
Date: | 2023-08-10 04:08:39 |
Message-ID: | 53dc58793eb3df17d2da8c2fc2275fac@oss.nttdata.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
Thanks for your comments about the v2 patches. I updated to v3 patches.
The main changes are:
* remove the AddinShmemInitLock assertion
* add the new lock (WaitEventExtensionLock) to wait_event_names.txt
* change "static const int wee_hash_XXX_size" to "#define XXX"
* simplify worker_spi. I removed codes related to share memory and
try to allocate the new wait event before waiting per background
worker.
* change to elog from ereport because the errors are for developers.
* revise comments as advised.
* fix the request size for shared memory correctly
* simplify dblink.c
* fix process ordering of WaitEventExtensionNew() as advised to
avoid leading illegal state.
In addition, I change the followings:
* update about custom wait events in sgml. we don't need to use
shmem_startup_hook.
* change the hash names for readability.
(ex. WaitEventExtensionNameHash -> WaitEventExtensionHashById)
* fix a bug to fail to get already defined events by names
because HASH_BLOBS was specified. HASH_STRINGS is right since
the key is C strings.
I create a new entry in commitfest for CI testing.
(https://commitfest.postgresql.org/44/4494/)
Thanks for closing the former entry.
(https://commitfest.postgresql.org/43/4368/)
Regards,
--
Masahiro Ikeda
NTT DATA CORPORATION
Attachment | Content-Type | Size |
---|---|---|
v3-0002-poc-custom-wait-event-for-dblink.patch | text/x-diff | 1.1 KB |
v3-0001-Change-to-manage-custom-wait-events-in-shared-hash.patch | text/x-diff | 24.0 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2023-08-10 04:33:48 | Re: Incorrect handling of OOM in WAL replay leading to data loss |
Previous Message | Yugo NAGATA | 2023-08-10 03:59:35 | Make psql's qeury canceling test simple by using signal() routine of IPC::Run |