SlideShare a Scribd company logo
1 of 26
Download to read offline
A living programming environment for a
living blockchain
by Santiago Bragagnolo - PharoDays - 2017
santiago.bragagnolo@gmail.com
santiago.bragagnolo@inria.fr
skype:santiago.bragagnolo
@sbragagnolo
Disclaimer!
This is not a blockchain mechanisms talk!
( Sorry disappoint you :) )
General technology
explanation
Starting by the fruit:
Smart contracts
• Digital reification of contracts
• Emulate the logic of contractual clauses
• Self-executing
• Self-enforcing
• Reduce transactional costs
• Minimise exceptions
Following by the branch:
Ethereum
• Blockchain based technology
• Open source & public network
• Smart contracts
• State stored in a blockchain
• Byte-code executed in the turing complete EVM
• Many development languages (solidity, serpent, etc)
Arriving to the trunk:
Blockchain
• Open and distributed ledger
• Records a constantly-growing list of transactions in between
two parties. (blocks)
• Resistant to modification by design
• Cryptocurrency: Paying to reinforce the social engagement
with the security
First-citizens in Blockchain
• Block: stamped batch of transactions
• Transaction: Representation of mutations of state
• Movements of money
• Method activation
• Account: Source and target of transactions (account in the accountancy
meaning)
• Contracts (Specific in ethereum)
So what? Architecture of a
proposed application
Pharo
Pharo: Why?
• Blockchain is a multiple actors always growing environment.
• Blockchain is a living environment
• Transactions move money (ether - bitcoin) from one place to other
• Transactions execute smart contracts
• Ethereum is a distributed runtime. Nothing better than a live environment for a
living distributed runtime.
• A lot of code analysis and inspection state-of-the-art tools
Fog
• Pharo client for the Ethereum client (GEth)
• github.com/sbragagnolo/Fog
Fog - features
• Connection, communication, marshalling, etc.
• Block fetching
• Query and create transactions
• Query and create contracts
• Remote method invocation
Fog - features
• Development support
• First-class citizen navigation (GT-Tools)
• Accounts
• Blocks
• Transactions
• Contracts
• Automatic contract mirror generation
• Automatic contract proxy building
Fog - features
• Cache
• General
• Connection
• Session
Some fancy slides :)
Block inspection
• Navigating blocks
• Inspecting blocks individually
• Overview of a collection of blocks through statistics
• Overview of the transactions of a collection of
blocks
Navigating in blocks
Blocks overview
Transactions overview
pragma solidity ^0.4.2;
contract StructTestContract {
enum myenum { A, B, C }
struct mystruct {
bool boolean;
myenum uservalue;
uint32 commonvalue;
}
address _owner;
bool bool1;
int16 midint;
mystruct simpleExample;
bool bool2;
mystruct[] arrayExample;
function StructTestContract (){
_owner = msg.sender;
bool1 = true;
bool2 = true;
midint = 32;
simpleExample.boolean = true;
simpleExample.uservalue = myenum.B;
simpleExample.commonvalue = 6355432;
arrayExample.push(mystruct(true, myenum.A, 134));
arrayExample.push(mystruct(false, myenum.B, 235));
arrayExample.push(mystruct(true, myenum.C, 34));
}
function kill() {
suicide(_owner);
}
Contract source code
Inspecting contract
Inspecting structs
Yet to implement
Fog - Demo
Fog - future
• Finishing session management
• Events support
• Transactional message send recognition
• New AST Definition (Henrique Rocha)
THANKS :)!
by Santiago Bragagnolo - PharoDays - 2017
santiago.bragagnolo@gmail.com
santiago.bragagnolo@inria.fr
skype:santiago.bragagnolo
@sbragagnolo

More Related Content

Similar to A living programming environment for blockchain

Similar to A living programming environment for blockchain (20)

Blockchain and BPM - Reflections on Four Years of Research and Applications
Blockchain and BPM - Reflections on Four Years of Research and ApplicationsBlockchain and BPM - Reflections on Four Years of Research and Applications
Blockchain and BPM - Reflections on Four Years of Research and Applications
 
Blockchain in the Heart of Digital Transformation
Blockchain in the Heart of Digital TransformationBlockchain in the Heart of Digital Transformation
Blockchain in the Heart of Digital Transformation
 
Blockchain architected
Blockchain architectedBlockchain architected
Blockchain architected
 
Ethereum-Cryptocurrency (All about Ethereum)
Ethereum-Cryptocurrency (All about Ethereum) Ethereum-Cryptocurrency (All about Ethereum)
Ethereum-Cryptocurrency (All about Ethereum)
 
Blockchain an introduction_n_li
Blockchain an introduction_n_liBlockchain an introduction_n_li
Blockchain an introduction_n_li
 
An Introduction to Blockchains
An Introduction to BlockchainsAn Introduction to Blockchains
An Introduction to Blockchains
 
Introduction to Ethereum Smart Contracts
Introduction to Ethereum Smart Contracts Introduction to Ethereum Smart Contracts
Introduction to Ethereum Smart Contracts
 
Icsa2018 blockchain tutorial
Icsa2018 blockchain tutorialIcsa2018 blockchain tutorial
Icsa2018 blockchain tutorial
 
Block chain
Block chainBlock chain
Block chain
 
How to design, code, deploy and execute a smart contract
How to design, code, deploy and execute a smart contractHow to design, code, deploy and execute a smart contract
How to design, code, deploy and execute a smart contract
 
Deploy a blockchain web-app with Hyperledger Fabric 1.4 - Concepts & Code
Deploy a blockchain web-app with Hyperledger Fabric 1.4 - Concepts & CodeDeploy a blockchain web-app with Hyperledger Fabric 1.4 - Concepts & Code
Deploy a blockchain web-app with Hyperledger Fabric 1.4 - Concepts & Code
 
Deployablockchainwebappwithhyperledgerfabricpresentation 190820170703
Deployablockchainwebappwithhyperledgerfabricpresentation 190820170703Deployablockchainwebappwithhyperledgerfabricpresentation 190820170703
Deployablockchainwebappwithhyperledgerfabricpresentation 190820170703
 
Blockchain data structures and fundamental
Blockchain data structures and fundamentalBlockchain data structures and fundamental
Blockchain data structures and fundamental
 
WSO2Con USA 2017: Keynote - The Blockchain’s Digital Disruption
WSO2Con USA 2017: Keynote - The Blockchain’s Digital DisruptionWSO2Con USA 2017: Keynote - The Blockchain’s Digital Disruption
WSO2Con USA 2017: Keynote - The Blockchain’s Digital Disruption
 
Ethereum
EthereumEthereum
Ethereum
 
Simone Bronzini - Weaknesses of blockchain applications - Codemotion Milan 2018
Simone Bronzini - Weaknesses of blockchain applications - Codemotion Milan 2018Simone Bronzini - Weaknesses of blockchain applications - Codemotion Milan 2018
Simone Bronzini - Weaknesses of blockchain applications - Codemotion Milan 2018
 
Blockchain
BlockchainBlockchain
Blockchain
 
Understanding Blockchain: Distributed Ledger Technology
Understanding Blockchain: Distributed Ledger TechnologyUnderstanding Blockchain: Distributed Ledger Technology
Understanding Blockchain: Distributed Ledger Technology
 
Introduction to Blockchain and Cryptocurrencies
Introduction to Blockchain and CryptocurrenciesIntroduction to Blockchain and Cryptocurrencies
Introduction to Blockchain and Cryptocurrencies
 
Blockchain (and Bitcoin)
Blockchain (and Bitcoin) Blockchain (and Bitcoin)
Blockchain (and Bitcoin)
 

More from Pharo

More from Pharo (20)

Yesplan: 10 Years later
Yesplan: 10 Years laterYesplan: 10 Years later
Yesplan: 10 Years later
 
Object-Centric Debugging: a preview
Object-Centric Debugging: a previewObject-Centric Debugging: a preview
Object-Centric Debugging: a preview
 
The future of testing in Pharo
The future of testing in PharoThe future of testing in Pharo
The future of testing in Pharo
 
Spec 2.0: The next step on desktop UI
Spec 2.0: The next step on desktop UI Spec 2.0: The next step on desktop UI
Spec 2.0: The next step on desktop UI
 
UI Testing with Spec
 UI Testing with Spec UI Testing with Spec
UI Testing with Spec
 
Pharo 7.0 and 8.0 alpha
Pharo 7.0 and 8.0 alphaPharo 7.0 and 8.0 alpha
Pharo 7.0 and 8.0 alpha
 
PHARO IoT: Installation Improvements and Continuous Integration
PHARO IoT: Installation Improvements and Continuous IntegrationPHARO IoT: Installation Improvements and Continuous Integration
PHARO IoT: Installation Improvements and Continuous Integration
 
Easy REST with OpenAPI
Easy REST with OpenAPIEasy REST with OpenAPI
Easy REST with OpenAPI
 
Comment soup with a pinch of types, served in a leaky bowl
Comment soup with a pinch of types, served in a leaky bowlComment soup with a pinch of types, served in a leaky bowl
Comment soup with a pinch of types, served in a leaky bowl
 
apart Framework: Porting from VisualWorks
apart Framework: Porting from VisualWorksapart Framework: Porting from VisualWorks
apart Framework: Porting from VisualWorks
 
XmppTalk
XmppTalkXmppTalk
XmppTalk
 
Raspberry and Pharo
Raspberry and PharoRaspberry and Pharo
Raspberry and Pharo
 
Welcome: PharoDays 2017
Welcome: PharoDays 2017Welcome: PharoDays 2017
Welcome: PharoDays 2017
 
Robotic Exploration and Mapping with Pharo
Robotic Exploration and Mapping with PharoRobotic Exploration and Mapping with Pharo
Robotic Exploration and Mapping with Pharo
 
Pharo VM Performance
Pharo VM PerformancePharo VM Performance
Pharo VM Performance
 
Git with Style
Git with StyleGit with Style
Git with Style
 
Pharo JS
Pharo JSPharo JS
Pharo JS
 
Seaside & ReactJS
Seaside & ReactJSSeaside & ReactJS
Seaside & ReactJS
 
Material Design and Seaside
Material Design and SeasideMaterial Design and Seaside
Material Design and Seaside
 
Calypso Browser
Calypso BrowserCalypso Browser
Calypso Browser
 

Recently uploaded

TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
mohitmore19
 
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
masabamasaba
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
VishalKumarJha10
 
The title is not connected to what is inside
The title is not connected to what is insideThe title is not connected to what is inside
The title is not connected to what is inside
shinachiaurasa2
 
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
masabamasaba
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
masabamasaba
 

Recently uploaded (20)

Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
VTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learnVTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learn
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
Generic or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisionsGeneric or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisions
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdf
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
 
%in Harare+277-882-255-28 abortion pills for sale in Harare
%in Harare+277-882-255-28 abortion pills for sale in Harare%in Harare+277-882-255-28 abortion pills for sale in Harare
%in Harare+277-882-255-28 abortion pills for sale in Harare
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students
 
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
 
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
 
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
 
Architecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the pastArchitecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the past
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
 
The title is not connected to what is inside
The title is not connected to what is insideThe title is not connected to what is inside
The title is not connected to what is inside
 
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
 

A living programming environment for blockchain

  • 1. A living programming environment for a living blockchain by Santiago Bragagnolo - PharoDays - 2017 santiago.bragagnolo@gmail.com santiago.bragagnolo@inria.fr skype:santiago.bragagnolo @sbragagnolo
  • 2. Disclaimer! This is not a blockchain mechanisms talk! ( Sorry disappoint you :) )
  • 4. Starting by the fruit: Smart contracts • Digital reification of contracts • Emulate the logic of contractual clauses • Self-executing • Self-enforcing • Reduce transactional costs • Minimise exceptions
  • 5. Following by the branch: Ethereum • Blockchain based technology • Open source & public network • Smart contracts • State stored in a blockchain • Byte-code executed in the turing complete EVM • Many development languages (solidity, serpent, etc)
  • 6. Arriving to the trunk: Blockchain • Open and distributed ledger • Records a constantly-growing list of transactions in between two parties. (blocks) • Resistant to modification by design • Cryptocurrency: Paying to reinforce the social engagement with the security
  • 7. First-citizens in Blockchain • Block: stamped batch of transactions • Transaction: Representation of mutations of state • Movements of money • Method activation • Account: Source and target of transactions (account in the accountancy meaning) • Contracts (Specific in ethereum)
  • 8. So what? Architecture of a proposed application
  • 10. Pharo: Why? • Blockchain is a multiple actors always growing environment. • Blockchain is a living environment • Transactions move money (ether - bitcoin) from one place to other • Transactions execute smart contracts • Ethereum is a distributed runtime. Nothing better than a live environment for a living distributed runtime. • A lot of code analysis and inspection state-of-the-art tools
  • 11. Fog • Pharo client for the Ethereum client (GEth) • github.com/sbragagnolo/Fog
  • 12. Fog - features • Connection, communication, marshalling, etc. • Block fetching • Query and create transactions • Query and create contracts • Remote method invocation
  • 13. Fog - features • Development support • First-class citizen navigation (GT-Tools) • Accounts • Blocks • Transactions • Contracts • Automatic contract mirror generation • Automatic contract proxy building
  • 14. Fog - features • Cache • General • Connection • Session
  • 16. Block inspection • Navigating blocks • Inspecting blocks individually • Overview of a collection of blocks through statistics • Overview of the transactions of a collection of blocks
  • 20. pragma solidity ^0.4.2; contract StructTestContract { enum myenum { A, B, C } struct mystruct { bool boolean; myenum uservalue; uint32 commonvalue; } address _owner; bool bool1; int16 midint; mystruct simpleExample; bool bool2; mystruct[] arrayExample; function StructTestContract (){ _owner = msg.sender; bool1 = true; bool2 = true; midint = 32; simpleExample.boolean = true; simpleExample.uservalue = myenum.B; simpleExample.commonvalue = 6355432; arrayExample.push(mystruct(true, myenum.A, 134)); arrayExample.push(mystruct(false, myenum.B, 235)); arrayExample.push(mystruct(true, myenum.C, 34)); } function kill() { suicide(_owner); } Contract source code
  • 25. Fog - future • Finishing session management • Events support • Transactional message send recognition • New AST Definition (Henrique Rocha)
  • 26. THANKS :)! by Santiago Bragagnolo - PharoDays - 2017 santiago.bragagnolo@gmail.com santiago.bragagnolo@inria.fr skype:santiago.bragagnolo @sbragagnolo