> Yeah, this was already proposed in [0], but there was no consensus. Sorry, I missed that! I should have read all earlier messages in more detail.
> Here the memory context is TopTransactionContext. I don't think this would > cause any problem. Could you explain why you prefer TopMemoryContext? I mainly looked at it similarly to the serialization question: how existing parts of the struct are used? There are two places where authn_id, the other string field, is set. Both use the same pattern, and if I read the code correctly one of them is already in TopMemoryContext, similarly to this call place. (and the other context is the parallel worker context, which would also be long lived enough for storing the authn_field, so again, technically the explicit TopMemoryContext isn't necessary) It seems to me that both existing places only use this explicit way of allocating it in TopMemoryContext for clarity.
