6 - Consistency and Replication Flashcards

1
Q

Why Replicate data?

A

System Performance- lowered latency
System Reliability

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Data Consistency

A

Corrrectness of Data according to a model

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Read-write conflict

A

Two read operations on the same data that read different values

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Write-Write Conflict

A

Two concurrent write operations on same data result in different versions

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Data centric consistency model

A

Specifies what is allowed and what the results of read/write ops are in presence of concurrency

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Data store model

A

Distributed storage collection
Read/Write
Read one, write all (datastores)
Consistency

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Tight Consistency

A

Synchronous Replication

Update every replica before next op

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Problems of Tight Consistency

A

Replicas must agree on next operation
Requires a lot of comms
Delay before next operation.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Consistent Ordering

In terms of what processes work on

A

Processes work on different copies of the same data

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Sequentially Consistent

A

Any result is the same as if the operations of all processes were executed in some sequential order
All processes execute operations in the issued order

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Causally Consistent

A

causally related writes are exec in same order by all processes

all operations are executed by all processes in the order of issuing

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

FIFO Consistent

A

individual processes operations are exec by all in the order they were issued

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Hierarchy of Consistencies

A

(Top Down)
Tight
Sequential
Causal
FIFO

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Eventual Consistency

A

Weak consistency model where no or rare parallel write accesses.
Updates are forwarded at some point.
All eventually consistent

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Critical Section

A

Processes must acquire lock to access critical sections

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Continuous Consistency

A

Divide data into consistency units
Non uniform consistency model

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

Client Centric Consistency

A

Consistency guaranteed for the same client

18
Q

Types of continuous consistency constraints

A

Absolute/relative numerical division
Relative staleness of data
Order and number of updates

19
Q

Types of client centric consistency requirements

A

Monotonic reads/writes
Read Your Writes
Writes Follow Reads

20
Q

Monotonic Reads

A

If a process reads item x, any successive read on x by that process is always same or more recent value

21
Q

Monotonic Writes

A

A write by process on item x is completed before any further write on x by the same process

22
Q

Read Your Writes

A

Effect of write on item x will always be seen by success read operation on x by the same process

23
Q

Writes Follow Reads

A

Write on item x following a previous read by same process will take place on same or more recent value of x

24
Q

Lazy Updates

A

Server that has not been recently accessed can be updated before it replies (lazy update)

25
Permanent Replicas
Initial set usually small At one location or mirrored sites
26
Server-initiated Replicas
Created ad-hoc Either at one location or close to client
27
Clustering
Partition space into cells and place servers at high demand
28
Client initiated replicas
Caching of data. Usually on the same LAN. Can have limited size and become stale
29
Invalidation Protocol
Propagate notifications for updates
30
Passive Replication
Transfer data from one copy to another
31
Active Replication
Propagate update operation to other copies
32
Primary-based protocol: Remote Write
Request forwarded to remote primary which distributes it
33
Primary-based protocol: Local Write
Replica receiving request is made new primary
34
Quorum based protocols
Only a certain number of replicas written to (write quorum) Read a few (read quorum) replicas and return latest version
35
What expression for n prevents read-write conflicts?
nw + nr > n The addition of write and read quorums must be more than n or the updates may not be read
36
What expression for n prevents write-write conflicts?
nw > n/2 The write quorum must exceed n or it is possible to have multiple writes with the same version number
37
Quorum based protocols: Advantages over ROWA
ROWA requires all replicas to be available but Quorum allows max{n-nw,n-nr} unresponsive. When single replicas fail or are expensive to update this may be more efficient
38
ROWA
Read One Write All
39
What consistency is probably sufficient for a stock market?
Causal. Changes in stock value should be consistent but independent changes can be seen in different orders
40
What client-centric consistency is most appropriate for a mobile user's mailbox?
All of them. The owner should always see the same mailbox.