From: | "Hayato Kuroda (Fujitsu)" <kuroda(dot)hayato(at)fujitsu(dot)com> |
---|---|
To: | 'Amit Kapila' <amit(dot)kapila16(at)gmail(dot)com>, Michael Paquier <michael(at)paquier(dot)xyz> |
Cc: | Robert Haas <robertmhaas(at)gmail(dot)com>, Jeff Davis <pgsql(at)j-davis(dot)com>, Alexander Lakhin <exclusion(at)gmail(dot)com>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>, "Hayato Kuroda (Fujitsu)" <kuroda(dot)hayato(at)fujitsu(dot)com> |
Subject: | RE: Is this a problem in GenericXLogFinish()? |
Date: | 2023-11-06 06:46:16 |
Message-ID: | TYAPR01MB58668D6E367C6C57B515E965F5AAA@TYAPR01MB5866.jpnprd01.prod.outlook.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Dear hackers,
> Dear Amit, Michael,
>
> Thanks for making the patch!
>
> > Why register wbuf at all if there are no tuples to add and it is not
> > the same as bucketbuf? Also, I think this won't be correct if prevbuf
> > and wrtbuf are the same and also we have no tuples to add to wbuf. I
> > have attached a naive and crude way to achieve it. This needs more
> > work both in terms of trying to find a better way to change the code
> > or ensure this won't break any existing case. I have just run the
> > existing tests. Such a fix certainly required more testing.
>
> I'm verifying the idea (currently it seems OK), but at least there is a coding error -
> wbuf_flags should be uint8 here. PSA the fixed patch.
Here is a new patch which is bit refactored. It did:
* If-conditions in _hash_freeovflpage() were swapped.
* Based on above, an Assert(xlrec.ntups == 0) was added.
* A condition in hash_xlog_squeeze_page() was followed the change as well
* comments were adjusted
Next we should add some test codes. I will continue considering but please post anything
If you have idea.
Best Regards,
Hayato Kuroda
FUJITSU LIMITED
Attachment | Content-Type | Size |
---|---|---|
fix_hash_squeeze_wal_3.patch | application/octet-stream | 2.3 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | David Rowley | 2023-11-06 06:51:02 | Re: Compiling warnings on old GCC |
Previous Message | Michael Paquier | 2023-11-06 06:35:28 | Re: Add recovery to pg_control and remove backup_label |