akc_go_sdk_v2

package module
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 30, 2021 License: MIT Imports: 0 Imported by: 0

README

Akachain Golang Software Development Kit - v2

Go Report Card

golang SDK that supports writing chaincodes on Hyperledger Fabric version 2+ with minimum setup.

We have written a few dozen of complex chaincodes for production environment of enterprise use cases since 2018. We found that it would give junior developers tremendous help if they are provided with several utilities to quickly interact with the state database as well as mockup tool to quickly test their chaincode without requiring a real Hyperledger Fabric Peer.

Getting started

Obtaining the Akachain go SDK package

go get https://github.com/Akachain/akc-go-sdk-v2

We recommend to use the SDK with gomod

Documentation

Our document is available at pkg.go.dev

Examples

Sample Test Code is available at

sample_test: Basic example that uses SDK to query and execute transaction with a CouchDB state database

License

This source code are made available under the MIT license, located in the LICENSE file. You can do whatever you want with them, we do not bother. But if you have some nice idea that wants to share back with us, please do.

To add MIT license header to new source code files, please use the following snippet

go get -u github.com/google/addlicense
addlicense -c akachain -l mit -y 2021 .

Documentation

Overview

Package akc_go_sdk_v2 provide core functions for developers to build a robust chaincode with minimum setup. There are 2 main sub packages to use

Packages for end developer usages

akc-go-sdk-v2/util provides CRUD utilities to work with CouchDB State Database Reference: https://pkg.go.dev/github.com/Akachain/akc-go-sdk-v2/util

akc-go-sdk-v2/mock provides testing suit to connect to a CouchDB instance and run the chaincode code against it. Reference: https://pkg.go.dev/github.com/Akachain/akc-go-sdk-v2/mock

Directories

Path Synopsis
Package mock provides mock methods to simulate how a peer node interact with CouchDB and simulate a transaction proposal.
Package mock provides mock methods to simulate how a peer node interact with CouchDB and simulate a transaction proposal.
test
contract
Package contract provides a sample smart contract.
Package contract provides a sample smart contract.
Package util provides generic CRUD methods for working with Hyperledger Fabric golang chaincode.
Package util provides generic CRUD methods for working with Hyperledger Fabric golang chaincode.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL