Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFC: IRI v1.8.1 transactions and bundles #20

Open
wants to merge 64 commits into
base: master
from

Conversation

@thibault-martinez
Copy link
Member

thibault-martinez commented Oct 14, 2019

Rendered

Tracking issue: iotaledger/bee#63

This RFC proposes the implementation of the Transaction and Bundle types to track definition of transactions and bundles as of iri v1.8.1 (the IOTA reference implementation).

The initial plan was to split Transaction RFC and Bundle RFC, we decided to merge them after careful considerations:

  • they are way too tied to be considered apart;
  • we've been moving a lot of logic from Transaction to Bundle;
@rufsam rufsam marked this pull request as ready for review Oct 15, 2019
This was referenced Oct 15, 2019
@oopsmonk

This comment was marked as resolved.

Copy link
Member

oopsmonk commented Oct 16, 2019

Rendered

wrong link.

thibault-martinez and others added 2 commits Oct 16, 2019
…ction-and-bundle.md

Co-Authored-By: Sam Chen <sam.chen@iota.org>
SuperFluffy added 4 commits Oct 29, 2019
Copy link

wusyong left a comment

LGTM. But maybe we could just leave documentation on code blocks to implement phase.


The fundamental communication unit in the IOTA protocol is the transaction. Messages, including payment settlements and
plain data, are propagated through the IOTA network in transactions. Message that are too large are split up into bundles
of several transactions and sent one by one.

This comment has been minimized.

Copy link
@Alex6323

Alex6323 Oct 30, 2019

I have a proposal for that paragraph which I find more clear:

Messages in the IOTA network can either represent payment settlements or serve as plain data carriers. In IOTA terminology messages are referred to as 'Bundles', which - depending on the message size - consist of one or more transactions. A transaction is the smallest communication unit. It has a fixed size, while messages in general can have arbitrary size. (maybe support this explanation with an example, e.g. security 3 transfer)

This comment has been minimized.

Copy link
@rufsam

rufsam Oct 31, 2019

Member

Agree Alex, sounds better and is easier to understand.

type level. During the construction phase we check that all transactions are consistent and adhere to IOTA convention,
but we don't, for example:

+ attempt to represent different the different types of transactions on the type level;

This comment has been minimized.

Copy link
@Alex6323

Alex6323 Oct 30, 2019

remove one 'different'


The fundamental communication unit in the IOTA protocol is the transaction. Messages, including payment settlements and
plain data, are propagated through the IOTA network in transactions. Message that are too large are split up into bundles
of several transactions and sent one by one.

This comment has been minimized.

Copy link
@rufsam

rufsam Oct 31, 2019

Member

Agree Alex, sounds better and is easier to understand.

SuperFluffy added 6 commits Nov 4, 2019
the same as `Transaction`.

```rust
pub struct TransactionBuilder {

This comment has been minimized.

Copy link
@rufsam

rufsam Nov 4, 2019

Member

Just a little thing here, but the TransactionBuilder actually doesn't build the Transaction, it's the BundleBuilder which fills indices, bundle hash, etc. and finally builds it right?
So maybe we should call it TransctionDraft instead of TransactionBuilder, as you suggested before
Letting the BundleBuilder then direclty operate on the TransctionDraft (with all fields there: bundlehash, indices, timestamps, ... ) seems clean to me 👍

SuperFluffy added 5 commits Nov 5, 2019
@SuperFluffy

This comment has been minimized.

Copy link
Contributor

SuperFluffy commented Nov 7, 2019

The team discussed the current proposal and agreed to transition it to the pre-activated stage.

Even though there are some blockers preventing the RFC (and by extension, its implementation) to be merged, the team agreed on the general idea behind this RFC.

In particular, the following general design points were considered to be relevant:

  • this proposal tries to only implement the transaction and bundle layout as of iri v1.8.1, which includes the explicit dependency on its signature, sponge/hashing, and proof of work algorithms. In particular, this proposal shall not attempt to be generic over these, because a change in either of these algorithms would constitute a breaking change with respect to the IOTA main net, thus requiring a new implementation from scratch anways;
  • this proposal is as simple as possible by only providing the ability to manually construct transactions and bundles by pushing transactions into them. This proposal does not attempt to have any more sophisticated means of constructing bundles such as determining the number of transactions needed to send a message and pushing those onto a stack.
  • this proposal tries to encode as many things as possible on the type level while still staying fairly minimal.
@SuperFluffy SuperFluffy changed the title RFC: `Transaction` & `Bundle` module RFC: iri v181 transactions and bundles Nov 7, 2019
@SuperFluffy SuperFluffy changed the title RFC: iri v181 transactions and bundles RFC: IRI v181 transactions and bundles Nov 7, 2019
@SuperFluffy SuperFluffy changed the title RFC: IRI v181 transactions and bundles RFC: IRI v1.8.1 transactions and bundles Nov 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
7 participants
You can’t perform that action at this time.