Live data from Hacker News

Apple open-sources FoundationDB

foundationdb.org

451–453 of 453 posts

Re: Apple open-sources FoundationDB

#451

Earlier quoted context omitted.

as far as I know SSI as implemented in Postgresql, aborts the way you describe, as per https://drkp.net/papers/ssi-vldb12.pdf

postgresql is not strictly serializable/externally consistent for example this will commit under serializable: create table counters(counter int); insert into counters(counter) values(1); BEGIN TRANSACTION ISOLATION LEVEL serializable; select sum(counter) from counters; /* insert sum into counters. wait until committing next transaction before executing the insert */ insert into counters(counter) values(1); COMMIT; /…

Even without external consistency, a I'm having trouble coming up with an ordering of the transactions that yields [1], [1, 10], [1, 1, 10].

Is that because PostgreSQL's "SERIALIZABLE" doesn't follow the "some serial order" definition? Or maybe I'm missing something else?

Re: Apple open-sources FoundationDB

#452

Earlier quoted context omitted.

postgresql is not strictly serializable/externally consistent for example this will commit under serializable: create table counters(counter int); insert into counters(counter) values(1); BEGIN TRANSACTION ISOLATION LEVEL serializable; select sum(counter) from counters; /* insert sum into counters. wait until committing next transaction before executing the insert */ insert into counters(counter) values(1); COMMIT; /…

Even without external consistency, a I'm having trouble coming up with an ordering of the transactions that yields [1], [1, 10], [1, 1, 10]. Is that because PostgreSQL's "SERIALIZABLE" doesn't follow the "some serial order" definition? Or maybe I'm missing something else?

Well, benmmurphy isn't talking about serializability (some correct ordering exists), but strict serializabilty (roughly: at least one correct ordering corresponds to wall clock order). PG does have the former, but not the latter.

Re: Apple open-sources FoundationDB

#453

Earlier quoted context omitted.

Even without external consistency, a I'm having trouble coming up with an ordering of the transactions that yields [1], [1, 10], [1, 1, 10]. Is that because PostgreSQL's "SERIALIZABLE" doesn't follow the "some serial order" definition? Or maybe I'm missing something else?

Well, benmmurphy isn't talking about serializability (some correct ordering exists), but strict serializabilty (roughly: at least one correct ordering corresponds to wall clock order). PG does have the former, but not the latter.

Huh? The example is for PostgreSQL's "serializable" isolation level, and that's what I'm confused about.

Serializability should ensure that the outcome is equivalent to some serial execution. What serial execution of those five transactions yields [1], [1, 10], [1, 1, 10]?

But also, I just read that prior to PostgreSQL 9.1 (released in 2011), the "serializable" isolation level was actually just snapshot isolation (now called "repeatable read"). So maybe that's what benmmurphy is referring to?

Post reply on HN