Hey everyone, welcome back to the course.
So in the last lecture we defined some of the business components which will affect your blockchain
architecture.
And before going into defining your blockchain instance, you should take care of all these components
and define your structure accordingly.
In this lecture, we are going to talk about technical components which will affect your blockchain
architecture, and you also need to make sure that you are able to provide different integration capabilities
and technical services using your blockchain solution.
The first component of technical services are the crypto services.
Crypto services forms the basis of the blockchain.
It is very important to see that what kind of security and performance oriented algorithms will be employed
with your blockchain solution.
Enterprise architecture for blockchain will also be affected by the integration and the throughputs
for the performance achieved through the crypto services.
There are different crypto services which are running with blockchain platforms.
The first one is asymmetric cryptography algorithm.
This is also known as key generation algorithm.
So whenever you have a private key and a blockchain address, you are going to use a symmetric cryptography
algorithm.
As we have learned in the previous lectures, two blockchain utilizes different asymmetric algorithms
to generate keys and addresses.
Some of the examples are SEC and RSA.
SEC is the algorithm which is running behind Ethereum and Bitcoin and other major blockchain platforms.
SEC is very secure as it is also present behind your Windows and Mac operating systems.
The second crypto service is your hashing algorithm.
Hashing algorithm is present with the blockchain services to make sure that you safeguard and verify
the data.
It converts the variable length of data into a fixed length of alphanumeric string, and it's a one
way function where you cannot convert back the whole data.
There are different hashing algorithms which are utilized with blockchain services.
Some of the examples for hashing algorithm are Sha256 and RIP and 160 Sha256 is used for hashing of
block data transaction and private key, whereas RIP 160 is used for hashing of the blockchain address
in different platforms.
You can also use different hashing algorithm as per your requirement for the project, but make sure
your hashing algorithm is secure because we have already seen the example of how hashing algorithms
are attacked and taken advantage of.
The third crypto service is your consensus algorithm.
Blockchain utilizes consensus algorithm to verify and share the data across different participants.
There are different consensus algorithm used behind different kinds of blockchain platforms, and some
of the blockchain platforms also allow you to use multiple consensus algorithm where you can shift between
different consensus processes.
Some of the examples of consensus algorithm are proof of work, proof of stake, delegated proof of
stake, proof of importance or proof of elapsed time.
Then you also have mnemonics algorithm working through different blockchain platforms.
Blockchain utilizes mnemonics for safeguarding the wallets.
In simple terms, you can define mnemonics as 12, 18 or 24 English words, which are chosen from a
predefined list, and these words will represent your private key.
So if you forgot or lost your private key, you can recover your private key using these words.
Moreover, it's hard to break these words because the combination of these words form a very large number,
and it's not possible for an attacker to try out all these different possible combinations.
The second important technical component which will affect your blockchain architecture is ledger.
Ledger is a very important component for blockchain.
In simple terms, if we want to define ledger, we can say it as a database which is consensually shared
and synchronized across multiple parties, institutes or geographies.
Different blockchain platforms employ different ledger schemas and design.
If you look at the platforms like Bitcoin and Ethereum, then you will see that these platforms utilizes
flat file system as a ledger where transactions are recorded inside the flat file.
On the other hand, the enterprise blockchain platforms like Hyperledger and Corda could employ NoSQL
databases like Leveldb and Couchdb.
While defining your blockchain architecture, you need to make sure that what kind of different ledger
design or schema you are going to follow.
If you are adopting a blockchain platform, then you might want to go for the predefined schemas with
the blockchain platform.
Or if you are defining your blockchain solution from the scratch, then you can go for your own defined
schema which is able to integrate with your other services, but always make sure that ledger has to
be defined in such a way that different participants are able to interact with the data which is immutably
shared between all the participants.
The third type of technical component for blockchain is blockchain services.
Blockchain services can be defined as the peer or the nodes which you are running across.
Blockchain.
A blockchain network refers to the collection of nodes as a peer to peer blockchain protocol and schema.
Nodes forms the backbone of the complete blockchain architecture.
Inside the solution.
You need to define that how many nodes you are going to keep for your blockchain platform.
If you provide less number of nodes, then your data could be hampered and the availability and performance
of the system could take effect.
And if you provide more number of nodes, then it might increase the cost of your project.
So you need to have a balance between the number of nodes or peers which you are spinning up for your
blockchain solution.
For example, normally whenever we go for a Hyperledger Fabric project, I take a thumb rule that for
every 50 users I'm going to have three committing nodes, one order node and one endorsing peer node.
So in this way you can also define the different nodes which you are going to use.
Moreover, make sure that before defining the total number of nodes which you are going to utilize,
you come to the decision about the business components on the stakeholders and the transaction throughput
which is expected from your system.
Then another blockchain service is your mining services.
Mining is a process where you take the data and add it over the blockchain after verification.
Public blockchains have very complex solution for providing mining, which is secure because everyone
is able to access all the data, but it affects your performance.
If you are going for a private blockchain solution, then you might not require such a complex solution.
You can go with less number of complexities as already you are authenticating the participants who are
going to verify the data In a blockchain architecture.
We should be certain about the components and services which we are going to employ to have an effective
blockchain storage mechanism.
Another important technical component for blockchain architecture are blockchain artifacts.
Blockchain artifacts can be taken up as the data stores or digital key or certificate stores which are
present with the blockchain.
So you have channels or streams.
Channels are like private subnet of communication between two or more specific network members for the
purpose of conducting private and confidential transactions.
For example, if you are working in a hospital and you have different departments available in the hospital
so you can have a channel for dental department, a separate channel for cardiology department and a
third channel for orthopedic department.
And these channels on their backend will be a complete ledger.
So each channel will be their own ledger and then participants can join these channel as per their authorization
channels are created to segregate the data and they may have different policies and rules compared to
other channels.
So let's say there is a policy that on dental channel you have to approve the data through an artificial
intelligence system.
But same policy might not be present on a cardiology channel.
Apart from that, the other blockchain artifact are the digital certificates and key stores.
Certificate and key stores are the secure storage of the certificates and keys which are utilized behind
the blockchain platforms.
Your blockchain architecture design is going to affect in how you store your certificates and keys.
Some blockchain platforms provide node wide storage of certificate and keys, while other blockchain
platform directly provide the certificate and keys to the user and they don't store at their own end.
Certificate and keys are very important because they need to be securely protected from any attacker.
We have seen multiple examples where blockchain platforms or blockchain exchanges has been hacked because
of insufficient storage of certificates and keys.
Other blockchain artifacts which will affect your technical decisions are about smart contracts.
Smart contracts, as we have already defined, are self-executing contracts which are agreed upon between
two or more parties.
They are analogous to your legal contracts.
Enterprise blockchain architecture will be heavily impacted by the introduction of smart contracts.
We need to maintain the permissions, authorization and development of smart contracts, and according
to that, we need to make sure that your interfaces and interaction capabilities are available.
Let's say you have a blockchain platform available, and on top of that you are defining smart contracts
within a different language.
So you need to also provision the SDKs and different interaction capabilities for smart contract.
Moreover, you also need to manage the users and their accounts for those smart contracts.
So by introducing smart contracts, we are going to change our blockchain architecture heavily and we
need to maintain that in our solution to another blockchain artifact are the transactions transaction
inside, blockchain can be referred to the transfer of goods data or digital currencies.
Each platform defines the different schemas for transaction you might need to take, in effect, the
interaction and data capability of transactions.
It could be possible that transactions are directly available in Json, RPC, or it could be in the
raw format.
So you need to make sure that whatever the transactions are happening on the blockchain, they are able
to communicate with the different blockchain stakeholders which are present with your system.
After blockchain artifacts.
We also have blockchain events.
Blockchain events are emitted by different blockchain platforms which can be captured by applications.
Events are similar to push notifications architecture where applications can behave according to data
pushed on top of the blockchain.
Let's say, for example, you have a blockchain running within a university inside university.
You are going to upload the results of an examination on top of blockchain.
You might have different applications which could be related to students, teachers, lecturers or management
who are subscribed to this event.
As soon as you upload the different results on top of your blockchain platform, these applications
will be notified that this is a new event generated from the blockchain.
And by capturing this event they can calculate or do multiple operations.
So let's say once you upload the results on top of your blockchain platform, an application can capture
this event and then calculate the total marks and certificate for an individual inside the university.
So such type of solutions can also be provisioned with blockchain By using blockchain events inside
your blockchain architecture, you need to make sure that how you are going to capture these events
and what different provision systems will be applied on top of these events.
Let's say these events are only available in XML schema or these events are only available in Json schema,
so make sure your applications are able to provision the capabilities with the blockchain events.
Finally, we have system integration.
System integration is an important technical component and it makes sure that the whole system is working
smoothly and the architecture is not disrupted.
After introducing blockchain in the process, Blockchain provides various tools for system integration,
and as a blockchain architect, it's your job to judge how and in which capacity you will use these
tools to integrate your existing legacy system with blockchain.
Some of the important tools which are available for system integration are SDKs.
SDKs are the software development kits.
Many blockchain platform provides the SDKs, which you can use to integrate with the system.
Make sure that your SDKs are appointable with existing system.
Some of the examples of SDKs are Hyperledger provides the SDKs for Go, NodeJS and Java Services, whereas
Corda provides the SDKs for Kotlin and Java Services.
Then you have Jason Json, RPC are the remote procedure calls which happen using the Json format.
This is one of the most common integration mechanism for blockchain as Json is supported by multitude
of platforms and you can easily integrate with your existing systems.
Then you also have smart contracts containerization.
Few of the platforms also offer separate containerization of smart contracts where you can compile and
then integrate the smart contracts with your blockchain platforms.
You need to maintain the integration in a way that your existing system is able to adapt to your blockchain
solution with much more efficiency.
We need to make sure that blockchain is able to provide growth instead of hampering your whole system.
So that was about the technical components for your blockchain architecture.
Both of these business and technical components define how your blockchain architecture is going to
perform, and it will also define the different components and integration capabilities which you will
keep with your blockchain architecture.
We will see in later part of the course that how you will be creating your enterprise blockchain architecture
and how these components will define that, what different services are going to be provisioned with.
Our solution In the next lecture we are going to go through the analysis of architecture for different
blockchain platforms.
We are going to focus on four major platforms Bitcoin, Ethereum, Hyperledger and Coda.
We are going to study about how these architectures different from each other and we are also going
to see what different services and capabilities are provided by these different architectures.
This analysis of blockchain architecture is about gaining the overview of internal blockchain platform
architecture and how we can utilize this internal blockchain architecture with our enterprise blockchain
solution.
If you have any queries, feel free to contact us at info at v2 blocks.com.
Thank you.