Tom Lane said:
> Andrew Dunstan <andrew@dunslane.net> writes:
>> Right. And if we have sessionids we would want them logged there, I
>> think. And that would rule out anything based on xid or backend pid.
>
> Uh, what's wrong with backend pid? Since we fork before we start doing
> anything with a connection, it should surely be available soon enough
> for the connection log message.
>
> Larry's idea about combining PID and backend start time didn't sound
> too unreasonable to me.
>
It did to me too. I was just looking at this code 2 days ago. Somehow when
I looked again I thought we logged connections in the postmaster. Larry's
idea should work just fine. For log compactness I think I'd hexencode it -
the SessionID doesn't need any semantics, it's just like a cookie.
cheers
andrew