Blockchains are immutable and distributed– in the world of tech this is a killer combination! Immutable means that once information enters the database it can’t be tampered with. When your database is immutable you don’t have to worry about someone rewriting your data . Distributed dbs mean that your data doesn’t “live” in one place. These datastores make interacting with your data transparent- all of the changes are visible to everyone.
Blockchains are great, but they do have their downsides. For one, public blockchains such as bitcoin and ethereum are notoriously slow- bitcoin’s blockchain can process no more than 10 transactions per second. Visa, on the other hand, can process 2,000 transactions per second.
If you are not ready to commit to a blockchain- fear not. There are ways you can get an immutable and distributed datastore without using ethereum or bitcoin.
Traditional SQL Databases
In some cases you can use a regular old SQL db as a immutable datastore. Standard databases implement CRUD transactions- Create, Read, Update, and Delete. To create an immutable database, the user would only Create, and Read. Updating and deleting would not be permitted and each transaction would come with a timestamp. This can be done with databases like PostGres. To learn more about immutability in PostGres, check out the docs.
BigchainDB and CockroachDB
As demonstrated above, it does take a bit of hacking to make a traditional SQL database immutable and distributed. If you are looking for a datastore that has these qualities out of the box I would give CockroachDB or BigchainDB a try. I haven’t used BigChainDB but many major companies like Microsoft and Porsche are actively experimenting with BigchainDB.
I did, however, got a chance to play with CockroachDB. CockroachDB allowed me to create a cluster that were completely in synch with each other. When I updated one node the other X nodes followed suit. Querying from CockroachDB was far less arduous than on the Ethereum or Bitcoin blockchain. All in all, it took me about a day to get a basic app up and running. If you are curious what a hello world app in CockroachDB and Python looks like you can peep the source code here.
I would be remiss if I didn’t give a shoutout to HDFS, Hadoop Distributed File System. HDFS is file storage system that is immutable and distributed. I don’t know a ton about HDFS, but it has been around since 2005 and is probably more production ready than newer technologies like BigchainDB and CockroachDB which as of this writing have been around for less than 5 years.
The Takeaway
Blockchains are a game changing technology. Period. That being said, many of the features that makes blockchains special like being distributed or immutable can be found in more traditional databases. It is prudent that one does their research before committing to a blockchain.