All Projects → PlatONnetwork → Platon Go

PlatONnetwork / Platon Go

Licence: lgpl-3.0
Golang implementation of the PlatON protocol

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to Platon Go

Waltz
Waltz is a quorum-based distributed write-ahead log for replicating transactions
Stars: ✭ 328 (-0.91%)
Mutual labels:  distributed-ledger, distributed-systems
Sleuth
A Go library for master-less peer-to-peer autodiscovery and RPC between HTTP services
Stars: ✭ 331 (+0%)
Mutual labels:  distributed-systems, distributed-computing
nebula
A distributed block-based data storage and compute engine
Stars: ✭ 127 (-61.63%)
Mutual labels:  distributed-systems, distributed-computing
Gosiris
An actor framework for Go
Stars: ✭ 222 (-32.93%)
Mutual labels:  distributed-systems, distributed-computing
Distributed-System-Algorithms-Implementation
Algorithms for implementation of Clock Synchronization, Consistency, Mutual Exclusion, Leader Election
Stars: ✭ 39 (-88.22%)
Mutual labels:  distributed-systems, distributed-computing
rce
Distributed, workflow-driven integration environment
Stars: ✭ 42 (-87.31%)
Mutual labels:  distributed-systems, distributed-computing
pat-helland-and-me
Materials related to my talk "Pat Helland and Me"
Stars: ✭ 14 (-95.77%)
Mutual labels:  distributed-systems, distributed-computing
Scalecube Cluster
ScaleCube Cluster is a lightweight Java VM implementation of SWIM: Scalable Weakly-consistent Infection-style Process Group Membership Protocol. features cluster membership, failure detection, and gossip protocol library.
Stars: ✭ 119 (-64.05%)
Mutual labels:  distributed-systems, distributed-computing
swarm-learning
A simplified library for decentralized, privacy preserving machine learning
Stars: ✭ 142 (-57.1%)
Mutual labels:  distributed-computing, distributed-ledger
IoTPy
Python for streams
Stars: ✭ 24 (-92.75%)
Mutual labels:  distributed-systems, distributed-computing
Awesome Parallel Computing
A curated list of awesome parallel computing resources
Stars: ✭ 212 (-35.95%)
Mutual labels:  distributed-systems, distributed-computing
Gleam
Fast, efficient, and scalable distributed map/reduce system, DAG execution, in memory or on disk, written in pure Go, runs standalone or distributedly.
Stars: ✭ 2,949 (+790.94%)
Mutual labels:  distributed-systems, distributed-computing
Qix
Machine Learning、Deep Learning、PostgreSQL、Distributed System、Node.Js、Golang
Stars: ✭ 13,740 (+4051.06%)
Mutual labels:  distributed-systems, distributed-computing
tutorial
Tutorials to help you build your first Swim app
Stars: ✭ 27 (-91.84%)
Mutual labels:  distributed-systems, distributed-computing
Orleans.clustering.kubernetes
Orleans Membership provider for Kubernetes
Stars: ✭ 140 (-57.7%)
Mutual labels:  distributed-systems, distributed-computing
ripple
Simple shared surface streaming application
Stars: ✭ 17 (-94.86%)
Mutual labels:  distributed-systems, distributed-computing
Distributedsystems
My Distributed Systems references
Stars: ✭ 67 (-79.76%)
Mutual labels:  distributed-systems, distributed-computing
Parapet
A purely functional library to build distributed and event-driven systems
Stars: ✭ 106 (-67.98%)
Mutual labels:  distributed-systems, distributed-computing
protoactor-go
Proto Actor - Ultra fast distributed actors for Go, C# and Java/Kotlin
Stars: ✭ 4,138 (+1150.15%)
Mutual labels:  distributed-systems, distributed-computing
realtimemap-dotnet
A showcase for Proto.Actor - an ultra-fast distributed actors solution for Go, C#, and Java/Kotlin.
Stars: ✭ 47 (-85.8%)
Mutual labels:  distributed-systems, distributed-computing

Go PlatON

Welcome to the PlatON-Go source code repository! This is an Ethereum-based、high-performance and high-security implementation of the PlatON protocol. Most of peculiarities according the PlatON's whitepaper(English|中文) has been developed.

Build Status

Building the source

The requirements to build PlatON-Go are:

  • OS:Windows10/Ubuntu18.04
  • Golang :version 1.11+
  • cmake :version 3.0+
  • g++&gcc :version 7.4.0+

'cmake' and 'gcc&g++' are usually built-in with Ubuntu

In addition, the following libraries needs to be installed manually

sudo apt install libgmp-dev libssl-dev

Then, clone the repository

git clone https://github.com/PlatONnetwork/PlatON-Go.git --recursive

Switch to the PlatON-Go repository root directory.

Ubuntu:

make all

Windows:

go run build\ci.go install 

The resulting binary will be placed in '$PlatON-Go/build/bin'(Ubuntu) or in '%GOPATH%\bin'(Windows) .

Getting Started

The project comes with several executables found in the build/bin directory.

Command Description
platon Our main PlatON CLI client. It is the entry point into the PlatON network
keytool a key related tool.

Generate the keys

Each node requires two pairs of public&private keys, the one is called node's keypair, it's generated based on the secp256k1 curve for marking the node identity and signning the block, and the other is called node's blskeypair, it's based on the BLS_12_381 curve and is used for consensus verifing. These two pairs of public-private key need to be generated by the keytool tool.

Switch to the directory where contains 'keytool.exe'(Windows) or 'keytool'(Ubuntu). Node's keypair(Ubuntu for example):

keytool genkeypair
Address   :  0xA9051ACCa5d9a7592056D07659f3F607923173ad
PrivateKey:  1abd1200759d4693f4510fbcf7d5caad743b11b5886dc229da6c0747061fca36
PublicKey :  8917c748513c23db46d23f531cc083d2f6001b4cc2396eb8412d73a3e4450ffc5f5235757abf9873de469498d8cf45f5bb42c215da79d59940e17fcb22dfc127

Node's blskeypair::

keytool genblskeypair
PrivateKey:  7747ec6876bbf8ca0934f05e45917b4213afc5814639355868bbf06d0b3e0f19
PublicKey :  e5eb9915ed2b5fd52cf5ff760873a75a8562956e176968f3cbe5ea2b22e03a7b5efc07fdd5ad66d433b404cb880b560bed6295fa79f8fa649588be02231de2e70a782751dc28dbf516b7bb5d52053b5cdf985d8961a5baafa467e8dda55fe981

Note: The PublicKey generated by the 'genkeypair' command is the NodeID we needed, the PrivateKey is the corresponding node private key, and the PublicKey generated by the 'genblskeypair' command is the node BLS PublicKey, used in the staking and consensus process, PrivateKey is the Node BLS PrivateKey, these two keypairs are common in different operating systems, that is, the public and private keys generated in Windows above, can be used in Ubuntu.

store the two private keys in files:

mkdir -p ./data
touch ./data/nodekey 
echo "{your-nodekey}" > ./data/nodekey
touch ./data/blskey
echo "{your-blskey}" > ./data/blskey

Generate a wallet

platon --datadir ./data account new
Your new account is locked with a password. Please give a password. Do not forget this password.
Passphrase:
Repeat passphrase:
Address: {566c274db7ac6d38da2b075b4ae41f4a5c481d21}

Do remember the password

Connect to the PlatON network

Options description
--identity Custom node name
--datadir Data directory for the databases and keystore
--rpcaddr HTTP-RPC server listening interface (default: "localhost")
--rpcport HTTP-RPC server listening port (default: 6789)
--rpcapi API's offered over the HTTP-RPC interface
--rpc Enable the HTTP-RPC server
--nodiscover Disables the peer discovery mechanism (manual peer addition)
--nodekey P2P node key file
--cbft.blskey BLS key file

Run the following command to launch a PlatON node connecting to the PlatON's mainnet:

$ ./platon --identity "platon" --datadir ./data --port {your-p2p-port} --rpcaddr 127.0.0.1 --rpcport {your-rpc-port} --rpcapi "db,platon,net,web3,admin,personal" --rpc --nodiscover --nodekey ./data/nodekey --cbft.blskey ./data/blskey

OK, it seems that the chain is running correctly, we can check it as follow:

platon attach http://127.0.0.1:6789
Welcome to the PlatON JavaScript console!

instance: PlatONnetwork/platon/v0.7.3-unstable/linux-amd64/go1.10.4
at block: 26 (Wed, 15 Dec 51802 20:22:44 CST)
 datadir: /home/jht/node1/data
 modules: admin:1.0 debug:1.0 net:1.0 personal:1.0 platon:1.0 rpc:1.0 web3:1.0

> platon.blockNumber
29

For more information, please visit our Docs.

Contributing to PlatON-Go

All of codes for PlatON-Go are open source and contributing are very welcome! Before beginning, please take a look at our contributing guidelines. You can also open an issue by clicking here.

Support

If you have any questions or suggestions please contact us at [email protected].

License

The PlatON-Go library (i.e. all code outside of the cmd directory) is licensed under the GNU Lesser General Public License v3.0, also included in our repository in the COPYING.LESSER file.

The PlatON-Go binaries (i.e. all code inside of the cmd directory) is licensed under the GNU General Public License v3.0, also included in our repository in the COPYING file.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].