Re: [HACKERS] proposal: session server side variables - Mailing list pgsql-hackers

From Fabien COELHO
Subject Re: [HACKERS] proposal: session server side variables
Date
Msg-id alpine.DEB.2.20.1701041151121.22281@lancre
Whole thread Raw
In response to Re: [HACKERS] proposal: session server side variables  (Craig Ringer <craig@2ndquadrant.com>)
Responses Re: [HACKERS] proposal: session server side variables  (Fabien COELHO <coelho@cri.ensmp.fr>)
Re: [HACKERS] proposal: session server side variables  (Craig Ringer <craig@2ndquadrant.com>)
List pgsql-hackers
>> I respect your opinion and don't agree with it.
>
> Yeah. I'm pretty overwhelmingly unconvinced too.

I'm lost.

The security-related use-case you have presented stores the status of the 
verification in a variable. If the variable is untransactional, then it 
has been shown that the variable status may say ok while the verification 
has really really failed. This means that subsequent operations would be 
executed believing wrongly that the security was ok. Not good.

Morover, there is no special cost in implementing transactional on session 
variables, has it is already done by pg. It can probably be reused.

An alternative is to implement sub (nested) transactions, like Oracle and 
MS SQL Server... but that would be quite some work.

So basically I do not see any point in not doing transactional variables.

-- 
Fabien.



pgsql-hackers by date:

Previous
From: Thomas Munro
Date:
Subject: Re: [HACKERS] Measuring replay lag
Next
From: Amit Kapila
Date:
Subject: Re: [HACKERS] UNDO and in-place update