compose

package module
v0.0.0-...-b89fbb9 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2025 License: GPL-3.0 Imports: 2 Imported by: 0

README

Compose Spec Code

This directory contains the Compose Specification library code.

Modules

  • compose.go: Compose basic types.
  • proto: Protocol Buffers definitions for protocol messages.
  • scp: Synchronous Composability Protocol module.
  • sbcp: Superblock Construction Protocol module.

Generating Go Proto Files

To generate the Go proto files, run:

cd ./compose
protoc --proto_path=proto --go_out=proto --go_opt=paths=source_relative proto/protocol_messages.proto

Documentation

Index

Constants

View Source
const (
	// Duration of a superblock period (10 Ethereum epochs).
	PeriodDuration = 10 * (32 * 12) * time.Second // 10 Ethereum epochs

	// Allowed window (in number of periods) to submit a valid ZK proof for a superblock.
	// After this window, the publisher should trigger a rollback.
	ProofWindow = 24 * 7
)

Variables

This section is empty.

Functions

func CloneByteSlices

func CloneByteSlices(src [][]byte) [][]byte

Types

type BlockHash

type BlockHash [32]byte

type ChainID

type ChainID uint64

func ChainsFromRequest

func ChainsFromRequest(xtRequest XTRequest) []ChainID

type DecisionState

type DecisionState int
const (
	DecisionStatePending DecisionState = iota
	DecisionStateAccepted
	DecisionStateRejected
)

func (*DecisionState) String

func (d *DecisionState) String() string

type EthAddress

type EthAddress [20]byte

func (EthAddress) String

func (a EthAddress) String() string

type Instance

type Instance struct {
	ID             InstanceID
	PeriodID       PeriodID
	SequenceNumber SequenceNumber
	XTRequest      XTRequest
}

func (*Instance) Chains

func (i *Instance) Chains() []ChainID

type InstanceID

type InstanceID [32]byte

func (InstanceID) String

func (id InstanceID) String() string

type PeriodID

type PeriodID uint64

type SequenceNumber

type SequenceNumber uint64

type SessionID

type SessionID uint64

type StateRoot

type StateRoot [32]byte

type SuperblockHash

type SuperblockHash [32]byte

type SuperblockNumber

type SuperblockNumber uint64

type TransactionRequest

type TransactionRequest struct {
	ChainID      ChainID
	Transactions [][]byte
}

type TxHash

type TxHash [32]byte

type XTRequest

type XTRequest struct {
	Transactions []TransactionRequest
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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