Professional Documents
Culture Documents
[1] Corfu is a consistency platform designed around the abstraction of a shared log. It
offers powerful features like:
Objects are in-memory
Highly available data-structures
Providing linearizable read/write operations
Strictly Serializable Transactions
ACID guarantees at Scale
2 Basic Concepts
In this section, we define and discuss some of the general concepts required for a clear
understanding of the proposed approach.
3 Todays Architecture
1
In todays distributed software arena. services require to store and manipulate very large
state and process data at extremely high throughput, and many services are built to
scale-out across large clusters. Unfortunately, distributed software developers are faced
with a plethora of tools for managing a variety of ingredients: data-placement; location;
ownership and fail-over; consistent snapshot; checkpoint and recovery; multi-object func-
tionality; and distributed caching. At their core, all of these tools need a log, in order
to order and persist a history of updates to state. They need tools for querying and
modifying the state efficiently and conveniently.
4 Corfu Components
5 Transactions
The transaction in corfu consists of multiple state machine changes on one or more objects.
A transaction is categorized by 3 components.
2
Execution: It describes what the transaction should do. This is the code that
expresses the transaction.
Read-Set: It describes the objects and its version which are read during transaction
execution.
Write-Set: It describes the modifications that the transaction has made during
execution.
The ACID properties that guide any database can be defined as:
Atomicity: Atomicity is statisfied if the write set is indivisible. i.e other clients
view the entire write at once or it is not seen
Corfu has got additional properties , generally not provided by standard transactional
implementations:
Read own writes: During the execution of a transaction, a read will reflect any
writes in that transactions own write set.
Opacity: Transactions are not allowed to see an inconsistent state, even if they
abort and do not commit any changes.
6 Working
The corfu runtime helps in connecting to the infrastructure. The CorfuDB is based on
shared log and state machine replication. Every client has its own Corfu Runtime present.
Whenever a Corfu Runtime client come up for the first time, it syncs the state with the
Infrastructure. The state is generated by replaying of log entries. The operations of
insersion into the database is very simple as it is based on HashMap operations.
3
7 Statistics
The statistics are based on the SMR Map of CorfuDB. All the values are average of 10000
entries in corfuDB.
Operation Time(ms)
Put Operation 7.0
Get Operation 1.445
KeySet Operation 0.8
Values Operation 0.8
EntrySet Operation 0.57
Contains Key Operation 1.5
8 Conclusion
In this work, the working of distributed database systems was studied with the help of
CorfuDB. First we created objects of different types and ingested them into Corfu. Then
based on diffferent operations available metrics were recorded. Corfu makes it very easy
for noivice users to handle database as it works on the principle of basic map. All the
different operations in a HashMap behave the same way and they internally work with
corfu runtime. Hence map gives an abstraction over the internal complexities of the
system.
4
References
[1] Dahlia Malkhi,MAHESH BALAKRISHNAN,JOHN D. DAVIS, MICHAEL WEI, TED
WOBBER : CORFU: A Distributed Shared Log, November 23, 2013, TOCS3104-10.