Re: Remove unused fields in ReorderBufferTupleBuf - Mailing list pgsql-hackers

From Aleksander Alekseev
Subject Re: Remove unused fields in ReorderBufferTupleBuf
Date
Msg-id CAJ7c6TM0sCuxk_aAhkDuSJmr402uJdrYKats-5_GooD7xLg57g@mail.gmail.com
Whole thread Raw
In response to Remove unused fields in ReorderBufferTupleBuf  (Masahiko Sawada <sawada.mshk@gmail.com>)
Responses Re: Remove unused fields in ReorderBufferTupleBuf
List pgsql-hackers
Hi,

Thanks for the patch.

> However, node and alloc_tuple_size are not used at all. It seems an
> oversight in commit a4ccc1cef5a, which introduced the generation
> context and used it in logical decoding. I think we can remove them
> (only on HEAD). I've attached the patch.

I'm afraid it's a bit incomplete:

```
../src/backend/replication/logical/reorderbuffer.c: In function
‘ReorderBufferGetTupleBuf’:
../src/backend/replication/logical/reorderbuffer.c:565:14: error:
‘ReorderBufferTupleBuf’ has no member named ‘alloc_tuple_size’
  565 |         tuple->alloc_tuple_size = alloc_len;
      |              ^~
[829/1882] Compiling C object contrib/xml2/pgxml.so.p/xpath.c.o
```

On top of that IMO it doesn't make much sense to keep a one-field
wrapper structure. Perhaps we should get rid of it entirely and just
use HeapTupleData instead.

Thoughts?

--
Best regards,
Aleksander Alekseev



pgsql-hackers by date:

Previous
From: Aleksander Alekseev
Date:
Subject: Re: [PATCH] Check more invariants during syscache initialization
Next
From: Dean Rasheed
Date:
Subject: Re: cataloguing NOT NULL constraints