chapter 6 Flashcards

1
Q

how do we keep replicas consistent?

A
  • ensure that all conflicting operations are done in the the same order everywhere
  • when one copy is updated we need to ensure that the other copies are updated as well.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

give an example of a Conflicting operations.

A
  • concurrent Read–write conflict
  • concurrent Write–write conflict
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Reasons for Replication?

A

1) Replication for reliability
- possible to continue working after one replica crashes by simply switching to one of the other replicas.
- to provide better protection against corrupted data

2) Replication for performance
- when number of processes need to access data managed by a single server. by replicating the server and subsequently dividing the work.
- by placing a copy of data in the proximity of the process using them, the time to access the data decreases.

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

Guaranteeing global ordering on conflicting operations may be a costly operation, downgrading scalability. Solution?

A

weaken consistency requirements so that hopefully global synchronization can be avoided

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

describe a Data-centric consistency models.

A

is a contract between a distributed data store [ distributed collection of storages ] and processes in which, the data store will specify the result of a read and write operation during concurrency.

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

describe a Continuous Consistency.

A
  • allows us to measure the degree of consistency.
  • replicas may have:
  • inconsistent numerical values
  • inconsistent staleness [ time of ops ]
  • inconsistent number or order of update ops
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

describe a conit.

A

specifies the data unit, whose consistency we are measuring
- stack market [ conit = stock value ]

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

describe weak consistency

A

Shared data can be counted on to be consistent only after a synchronization is done.

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

Properties Weak Consistency:

A
  1. Accesses to synchronization variables associated with a data-store are sequentially consistent.
  2. No operation on a synchronization variable is allowed to be performed until all previous writes have been completed everywhere.
  3. No read or write operation on data items are allowed to be performed until all previous operations to synchronization variables have been performed.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

describe Causal consistency

A

Writes that are potentially causally related must be seen by all processes in the same order. Concurrent writes may be seen in a different order by different processes.

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

describe Sequential consistency.

A

The result of any transaction is the same as if all operations contained within the transaction were executed in a sequential order specified by the program.

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

list types of data centric Consistency models.

A
  • sequential
  • strict
  • casual
  • weak
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

what is the goal of a Client-centric consistency models?

A

Aims to achieve the consistency that the client wants instead of the consistency that the server should maintain.

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

what are the techniques to find the best place fore replica placement?

A
  1. Select best location out of N − K for which the average distance to clients is minimal. Then choose the next best server. EXPENSIVE
  2. Select the K-th largest autonomous system and place a server at the best-connected host. COMPUTATIONALLY EXPENSIVE
  3. Position nodes in a d-dimensional geometric space, where distance reflects latency. Identify the K regions with highest density and place a server in every one. COMPUTATIONALLY CHEAP
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

what are the types of replicas?

A
  • permanent
  • server initiated
  • client initiated
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

describe Permanent replicas.

A

describes a process or a machine who always has a replica

17
Q

describe Server-initiated replicas

A

To enhance performance, a data store dynamically places a replica in a certain geographical location to meet the unexpected burst of request coming from a server in that location.

18
Q

describe a Client-initiated replica

A

A type of replica that is dynamically hosted [ created ] at the request of client
- same machine, LAN, WAN

19
Q

draw The logical organization of replicas.

A

inner to outer circle
permanent -> server Initiated -> client initiated -> client

20
Q

explain how a Server-initiated replicas works

A
  • Specific files on a server can be migrated or replicated to servers placed in the proximity of clients that issue many requests for those files.

** count access [ requests ] to file F.
- if access count is below the deletion threshold = drop file
- if access count exceeds the replication threshold = replicate file
- if access count is b/n the deletion and replication threshold = migrate file

21
Q

what are the 3 models of Content distribution?

A
  1. propagate notification of an update
  2. transfer data from 1 copy to another
  3. Propagate the update operation to other copies
22
Q

describe propagate notification of an update model

A
  • Performed by an invalidation protocol
  • other copies are informed that an update has taken place and that the data they contain are no longer valid.
  • used for caching
  • adv - less bandwidth
23
Q

describe Transfer data from one copy to another model.

A
  • passive replication
  • useful when the read-to-write ratio is relatively high
  • Log the changes and transfer only those logs to save bandwidth.
24
Q

describe Propagate the update operation to other copies model.

A
  • active replication
  • Tell each replica which update operation it should perform and send only the parameter values that those operations need
25
Q

which Content distribution approach is the best?

A

but depends highly on available bandwidth and read-to-write ratio at replicas.

26
Q

explain push protocols in updating

A

** Pushing updates: server-initiated approach
- updates are propagated to other replicas without those replicas requesting updates.
- Used between permanent and server-initiated replicas and can used to push updates to client caches.
- Used when replicas need to maintain a relatively high degree of consistency.

27
Q

explain pull protocols in updating

A

** Pull-based - client-based protocols
- a client requests another server to send the updates it has at that moment.
- Used by client caches.

28
Q

compare and contrast b/n Push-based Pull-based in terms of:
1. State at server
2: Messages to be exchanged
3: Response time at the client

A
  1. push [ list of client ] , pull [ None ]
  2. push [ update , maybe fetch updates ] , pull [ poll and fetch ]
  3. push [ immediate or fetch update time ], pull [ fut ]
29
Q

describe a lease.

A

a lease is a contract b/n a client and a server, where the server will make a promise that it will continue to push updates until the lease expires.
- allows dynamic switching between pulling and pushing

30
Q

what happens When a lease expires?

A
  • the client is forced to poll the server for updates and pull in the modified data if necessary.
  • Or a client requests a new lease
31
Q

describe an age-based lease.

A

An object [ a file ] that hasn’t changed for a long time, will not change in the near future, so provide a long-lasting lease
- cheaper for me

32
Q

describe a Renewal-frequency based lease?

A

The more often a client requests a specific object, the longer the expiration time for that client (for that object) will be

  • you’re bugging me, go away. I will send you updates when I get them. stop nagging
  • cheaper for me to …
33
Q

describe a State-based lease

A

The more loaded a server is, the shorter the expiration times become