On Mon, Mar 22, 2021 at 9:55 AM Masahiko Sawada <sawada.m...@gmail.com> wrote:
>
> On Sat, Mar 20, 2021 at 3:52 AM Andres Freund <and...@anarazel.de> wrote:
> >
> >
> > - PgStat_ReplSlotStats etc use slotname[NAMEDATALEN]. Why not just NameData?
>
> That's because we followed other definitions in pgstat.h that use
> char[NAMEDATALEN]. I'm okay with using NameData.
>

I see that at many places in code we use char[NAMEDATALEN] for names.
However, for slotname, we use NameData, see:
typedef struct ReplicationSlotPersistentData
{
/* The slot's identifier */
NameData name;

So, it will be better to use the same for pgstat purposes as well. In
other words, I also agree with this decision and I see that Vignesh
has already used NameData for slot_name in his recent patch.

-- 
With Regards,
Amit Kapila.


Reply via email to