If I was to describe what blockchain is in one sentence it would be this:
"A distributed database that can be trusted"
Lets break this down a bit:
"A distributed database"
A database that runs on many computers, each of which has a full copy of the database and work together to keep things in sync. This is similar to a high availability database deployment like you might see with SQL Server, Oracle or MongoDB - with a few significant differences:
- Number of computers. A SQL Server HA deployment typically consists of two computers - an active node and a passive node. A blockchain database has no real limit on number of computers and some deployments run on thousands of computers (e.g bitcoin, ethereum).
- Connectivity between computers. A SQL Server HA deployment requires a reliable connection between the active and passive nodes. If the network is not reliable, the system will run into many problems trying to figure out who is in charge. This often results in the deployment of the computers being in the same data center. If the active and passive are split into separate datacenter, there must be a high speed and reliable network between them. Blockchain on the other hand assumes the network is not reliable. Any given blockchain node can come and go at any point and the entire system will continue to function. The network can even slow down and the system will continue to function.
One of the benefits of blockchain running on multiple computers and being resilient to network problems is that it is much more reliable. Computer and network failures happen regularly on blockchain, yet the system continues to run - thus giving us confidence that it will not go down. Contrast that with a HA SQL Server deployment. A failure on such a system is very rare and you often discover it isn't working as expected until a failure actually occurs.
"database that can be trusted"
Blockchain brings a different model of trust than we are used to and this is probably the hardest thing to fully understand as it requires a paradigm shift. Today we put our trust in many things that are not in our control. We trust the bank with our money, we trust the government to represent the peoples interests, the media with truthful reporting and even our IT administrator with our data. Is SQL Server trustworthy? In some ways it is - it is proven technology and as a developer, I am very confident that doing an INSERT or UPDATE will work properly. I even trust that its authorization and authentication mechanisms work to protect sensitive data. While this sounds like a trustworthy technology, it has several shortcomings:
- Identity management handled by applications. Databases typically have user accounts, but they are rarely integrated with end user accounts. Database accounts are typically granted for applications that handle identity management for end users. The application may delegate authentication to a centralized system such as active directory, but once the user is authenticated, all database actions are done on behalf of the applications database account. What this means is that end users have to trust the application to do the right thing as well as everyone who has higher levels of access. This is rarely a problem in the real world as those with higher levels of access are trustworthy - but this is not a guarantee. It is entirely possible for someone with higher level access to do bad things. For example, an IT administrator could delete records from a database that recorded actions by staff that resulted in the death of a patient to avoid potential fines from a malpractice law suit. I hate to say it, but chances are this has happened and likely more than once. With blockchain, changes are validated via a digital signature signed by the end user. Identity management is handled by the end user, not the database! The database simply validates that actions done by a user are in fact done by that user and nobody else. It is impossible for anyone but that user to impersonate them (assuming the private key is kept secret). Decentralizing identity management gives us as users a level of trust that we don't have today with existing database technologies.
- Data is immutable. This is a new aspect to databases for most of us - it means that once a record is written, it can never be changed. This means UPDATE and DELETE actions don't work the same way. An update to data is done by writing a new block to the blockchain saying it updated the data - the original data is never changed (it is left in the blockchain). Data immutability gives us a level of trust with the underlying data that we currently don't have.
Data immutability with decentralized identity management provides a new paradigm of trust. It means that end users can be fully in control of their identity and the changes made on its behalf. It also means that we have a full history of data changes that cannot be changed or corrupted by anyone. While these properties increase end users control over their data, it also puts a higher level of responsibility on them - specifically around managing their private keys. Fortunately there are hardware wallet solutions available today such as trezor, ledger and uPort (via iOS/Android devices) to help with protecting private keys.
Blockchain Drawbacks
This may sound great, but the blockchain database has a few drawbacks compared to SQL and NoSQL technologies:
1) Blockchain has a much lower transaction throughput. While A SQL or NoSQL database can support transaction times in milliseconds, blockchain often operates in seconds, minutes or even hours! The slowness of blockchain transactions means we can't use it as a direct replacement for the databases we use today.
2) Limited or no query support. Blockchains are more of a write only transaction log than a database. For most solutions, a SQL or NoSQL database is populated with data read from the blockchain so query operations can be performed against it. In the case of ethereum, filters can be used to do primitive queries. Some query use cases can be addressed by processing the queries in a smart contract or perhaps in the application tier.
3) Cost. Blockchain requires considerably more CPU, storage and network resources that a corresponding SQL Server HA installation.
No comments:
Post a Comment