Skip to content
Snippets Groups Projects
user avatar
Luca Moser authored
* Feat: initial commit

* Feat: added setPreferred to TransactionMetadata

* Feat: added a Conflicting() method to the transactionMetadata

* Fix: fixed logic bug

* Feat: refactored fcob

* Refactor: refactored additional code

* Fix: fixed a bug in ForeachConsumers

* Refactor: cleaned up code

* Feat: implemented FCOB consensus into the valuetransfer dapp

* Refactor: refactored FCOB

* Docs: added some additional comments

* Docs: fixed comments

* add branch manager conflict test

* cleans failing test

* Refactor: commit before branch change

* Fix: fixed bug in AggregateBranches

* assert aggr. branch IDs

* expands branch conflict detection test

* add visualisation of branch graph of test

* Feat: added PayloadLiked Event

* Refactor: fixed some missing comments + added liked to marshal

* Feat: reworked the preferred and liked propagation

* Refactor: cleaned up some logic

* Refactor: simplified code

* Refactor: cleaned up more stuff :P

* Refactor: refactor

* Feat: moved test + refactored fcob

* adds more tests

* fixes liked state not getting updated correctly of conflict members

* adds additional liked/preferred propagation test

* Fix: fixed missing preferred propagation to aggregated branches

* Fix: fixed a few bugs in liked propagation

* adapt to new hive.go version

* upgrade hive.go

* Feat: started implementing a wallet

* Feat: extended wallet files

* remove weird test

* use mem db for tests

* more tests

* use store backed sequence

* add option to use in-memory database

* address review comments

* First tests for individual components of AttachPayloadSync

* Fix: fixed missing events in branchmanaer

* Feat: propagate changes from branch to transaction

* Add tests for checkTransactionOutputs

* Feat: started implementing confirmed propagation

* Fix: fixed unreachable code

* Add more tests

* Refactor: refactored some code according to wolfgangs review

* Refactor: cleaned up the code according to DRY

* Refactor: refactored according to wollac

* Refactor: refactored according to wollac

* Refactor: refactored according to wollac

* Refactor: refactored the code to make it more readable

* Refactor: added some doc comments + cleaned up some more code

* :white_check_mark: adds orderedMap unit tests

* :rotating_light: Fix linter warnings

* test: Add queue unit tests

* Add more tests

* :lipstick: Adjust imports order

* WIP more tests

* :white_check_mark: Add TestBookTransaction

* :white_check_mark: Update TestBookTransaction

* Add more tests

* :construction: WIP tests

* :white_check_mark: Add TestCalculateBranchOfTransaction

* :white_check_mark: Add TestMoveTransactionToBranch

* :white_check_mark: Add TestFork

* :white_check_mark: Add TestBookPayload

* Add test for checkPayloadSolidity

* :white_check_mark: Add TestSetTransactionPreferred

* Add more tests

* :white_check_mark: Fix Tangle test

* Feat: started implementing lucas test cases

* Feat: fixed some issued + further tests

* Feat: started adding invalid txs check

* Feat: added removal logic for invalid transactions

* Refactor: removed Println

* :white_check_mark: Add test for 2nd Reattachment

* feat: Add first value transfer integration test

* fix: fix wrong plugin name

* :white_check_mark: Add aggregated branches test cases

* Feat: added a method to generate AggregatedBranchIDs

* :art: Use GenerateAggregatedBranchID in test

* Feat: refactored delete logic

* Fix: fixed broken test

* Feat: added final test cases for invalid txs / payloads

* :construction:

 WIP

* Value tangle concurrency tests (#451)

* Add simple concurrency test

* Add reverse and concurrent transaction and value object solidification tests and fix bug when value object was visited more than once

* Add some documentation to make tests easily understandable

* WIP propagation tests but fixed already couple of bugs

* Fix: fixed some bugs

* Feat: added propagation to inclusion states to tx and its outputs

* Feat: finished the propagation down to the tx and its outputs

* WIP propagation tests and fix bugs

* Add colored tokens test

* Add value tangle test to github workflow

* fix: Fix wrong function name in comments

* refactor: Make testSnapshots disabled in default and minor tweaks

* Feat: fixed some issues and introduced a Debugger

* Refactor: added a few comments

* Split massive test file into slightly more digestible chunks

* Clean up propagation tests

* Feat: fixed bugs

* Feat: enabled missing tests

* Add some documentation and missing checks for aggregated branches

* Clean up tangle tests

* adds snapshot type

* Fix: finalized wasn't propagated when a branch was rejected

* implements ReadFrom and WriteTo for Snapshot

* read in snapshot file if snapshot path is defined

* renames snapshot test file

* WIP debugging concurrency bug of death

* Feat: added more reliable fails in test case

* Fix: fixes a race condition in solidification

* Clean up test

* adds assets volume to integration test containers

* fixes some asserts

* adds non-working conflict integration test

* check transaction availability in partition

* renames integration test

* lower amount of peers

* first passing version of consensus integration test

* remove debug printlns

* do all integration tests again

* increases avg. network delay fcob rule, removes debug printlns

* go mod tidy by Marie Kondō

* renames incl. state. conflict to conflicting

* go fmt tangle.go

* go fmt tangle_test, goimports dapp.go

* goimports again because the dog is sad

* run consensus integration test on the CI

* use explicit pumba version 0.7.2

* pray to the CI gods for the test to pass

* fix panic when tangle.Fork() is called

* readd all tests again

* reset integration framework paras

* removes test snapshot plugin

* get rid of test snapshot plugin

* fixes wrong use of Println

* removes random tool

* removes duplicated value entry in GH CI workflows

* xxx

* wip

* fixes integration test

Co-authored-by: default avatarHans Moog <hm@mkjc.net>
Co-authored-by: default avatarWolfgang Welz <welzwo@gmail.com>
Co-authored-by: default avatarjonastheis <mail@jonastheis.de>
Co-authored-by: default avatarcapossele <angelocapossele@gmail.com>
Co-authored-by: default avatarjkrvivian <jkrvivian@gmail.com>
57fb70b7
History


Prototype node software for an IOTA network without the Coordinator

Developer documentation portal

Discord StackExchange Apache 2.0 license Go version Build status Latest release

AboutDesignImplemented Coordicide modulesWork-in-progress modulesInstallationGetting startedClient-Library and HTTP API referenceSupporting the projectJoining the discussion


About

This repository is where the IOTA Foundation's Research Department runs simulations of the Coordicide modules to study and evaluate their performance.

The aim of this open repository is to give the community the opportunity to follow developments, take part in testing, and learn more about Coordicide.

Note: You can find details about future development plans in our roadmap.

Design

The code in GoShimmer is modular, where each module represents either one of the Coordicide components or a basic node function such as the gossip layer, ledger state, and API.

Coordicide blueprint

This approach allows us to develop each module in parallel and to test GoShimmer with one or more different versions.

Each module is defined in the packages directory and can be enabled, using the plugins directory.

Note: See the main.go file to see which plugins are currently supported.

Implemented Coordicide modules

The master branch is the stable version of the GoShimmer software, which includes a minimal set of modules to allow you to send and gossip zero-value transactions.

The master branch includes the following Coordicide modules:

The autopeering module is divided into two submodules:

  • Peer discovery: Responsible for operations such as discovering new peers and verifying their online status

  • Neighbor selection: Responsible for finding and managing neighbors

Autopeering design

We also have a standalone autopeering simulator in this repository.

Work-in-progress modules

Work-in-progress modules are typically kept on a different branch such as mana, and are not compatible with the master branch. Therefore, nodes that run these branches cannot join the current network because the code either is still too experimental or it includes breaking changes.

The following Coordicide modules are a work in progress:

  • Mana: The mana branch contains a first implementation of the mana module in the packages directory.

  • Cellular Consensus: The ca branch contains a first implementation of the Cellular Consensus module in the packages directory.

  • Fast Probabilistic Consensus: The fpc branch contains a first implementation of the Fast Probabilistic Consensus module in the packages directory. We also have a standalone FPC simulator in this repository.

  • Spam Protection: You can find the initial simulation source code of the rate control in this repository and the source code of the Adaptive Proof of Work simulator here.

As well as these modules, we are working on the following node functions:

Client-Library and HTTP API reference

You can use the Go client-library to interact with GoShimmer (located under github.com/iotaledger/goshimmer/client).

Alternatively, you can check out the API docs to implement your own client or inspect the available HTTP API endpoints.

For code generation, you might want to use the OAS/Swagger specification file directly.

Installation

You have two options to install and run GoShimmer:

  • Use the precompiled executable file
  • Compile the code from source

Execute the precompiled executable file

The release page includes downloadable files for Linux, macOS, and Windows.

To run the node, all you need to do is download and execute one of these files, depending on your operating system.

# Linux and macOS
./goshimmer
# Windows
goshimmer.exe

Compile the code from source

If you want to build your own executable file, you need to follow these steps.

Prerequisites

To complete this guide, you need to have at least version 1.14 of Go installed on your device.

To check if you have Go installed, run the following command:

go version

If Go is installed, you should see the version that's installed.


  1. Clone the repository

    git clone https://github.com/iotaledger/goshimmer.git
  2. Change into the goshimmer directory

  3. Copy and adjust config.default.json

    # Linux and macOS
    cp config.default.json config.json
    # Windows
    copy config.default.json config.json
  4. Use one of the following commands to build your executable file, depending on your operating system

    # Linux and macOS
    go build -o goshimmer
    # Windows
    go build -o  goshimmer.exe

    Note: If you're using Windows PowerShell, enclose goshimmer.exe in single quotation marks. For example: go build -o 'goshimmer.exe'.

Getting started

When you first run GoShimmer, the node starts running and tries to connects to neighbors, using the autopeering module.

To run other modules such as the spammer, you can configure GoShimmer to enable them through plugins.

Note: For a list of all the available configuration parameters, you can run the following command:

# Linux and macOS
./goshimmer -help
# Windows
goshimmer.exe -help

You can configure GoShimmer in the following ways:

  • Use a configuration file called config.json
  • Use command-line options

The repository includes a config.json file, which the executable file will find and use when you execute it.

To use the command line, execute the file with one of the following commands, depending on your operating system

# Linux and macOS
./goshimmer --node.enablePlugins "spammer"
# Windows
goshimmer.exe --node.enablePlugins "spammer"

Here, we use the command-line flags to enable the spammer plugin. This plugin allows you to send spam transactions to your node.

Dashboard

GoShimmer provides access to a SPA dashboard showing TPS, memory chart, neighbors and a Tangle explorer.

You can change its configuration (e.g, bind address, port) under the section dashboard of the config.json file, for example by changing the bind address to 0.0.0.0:8081 to enable the access from remote and/or by enabling the authentication.

To access the dashboard, you can use your browser (the default address is http://127.0.0.1:8081).

dashboard

Supporting the project

If you want to contribute to the code, consider posting a bug report, feature request or a pull request.

When creating a pull request, we recommend that you do the following:

  1. Clone the repository
  2. Create a new branch for your fix or feature. For example, git checkout -b fix/my-fix or git checkout -b feat/my-feature.
  3. Run the go fmt command to make sure your code is well formatted
  4. Document any exported packages
  5. Target your pull request to be merged with dev

Joining the discussion

If you want to get involved in the community, need help getting started, have any issues related to the repository or just want to discuss blockchain, distributed ledgers, and IoT with other people, feel free to join our Discord.