managedblockchain

package
v1.10.0 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ManagedBlockchainService

type ManagedBlockchainService struct {
	// contains filtered or unexported fields
}

ManagedBlockchainService is the cloudmock implementation of the Amazon Managed Blockchain API.

func New

func New(accountID, region string) *ManagedBlockchainService

New returns a new ManagedBlockchainService for the given AWS account ID and region.

func (*ManagedBlockchainService) Actions

func (s *ManagedBlockchainService) Actions() []service.Action

Actions returns the list of Managed Blockchain API actions supported by this service.

func (*ManagedBlockchainService) HandleRequest

HandleRequest routes an incoming Managed Blockchain request to the appropriate handler.

func (*ManagedBlockchainService) HealthCheck

func (s *ManagedBlockchainService) HealthCheck() error

HealthCheck always returns nil.

func (*ManagedBlockchainService) Name

func (s *ManagedBlockchainService) Name() string

Name returns the AWS service name used for routing.

type Member

type Member struct {
	ID           string
	NetworkID    string
	Name         string
	Description  string
	Status       string
	CreationDate time.Time
}

Member represents a network member.

type Network

type Network struct {
	ID               string
	Name             string
	Description      string
	Framework        string
	FrameworkVersion string
	Status           string
	CreationDate     time.Time
	// contains filtered or unexported fields
}

Network represents a Managed Blockchain network.

type Node

type Node struct {
	ID               string
	NetworkID        string
	MemberID         string
	InstanceType     string
	AvailabilityZone string
	Status           string
	CreationDate     time.Time
	// contains filtered or unexported fields
}

Node represents a peer node.

type Proposal

type Proposal struct {
	ProposalID           string
	NetworkID            string
	Description          string
	ProposedByMemberID   string
	Status               string
	CreationDate         time.Time
	ExpirationDate       time.Time
	YesVoteCount         int
	NoVoteCount          int
	OutstandingVoteCount int
	Votes                []ProposalVote
}

Proposal represents a network proposal.

type ProposalVote

type ProposalVote struct {
	MemberID string
	Vote     string // YES or NO
}

ProposalVote represents a vote on a proposal.

type Store

type Store struct {
	// contains filtered or unexported fields
}

Store manages Managed Blockchain resources in memory.

func NewStore

func NewStore(accountID, region string) *Store

NewStore returns a new empty Managed Blockchain Store.

func (*Store) CreateNetwork

func (s *Store) CreateNetwork(name, description, framework, frameworkVersion string) (*Network, *Member, error)

CreateNetwork creates a new network.

func (*Store) CreateNode

func (s *Store) CreateNode(networkID, memberID, instanceType, az string) (*Node, error)

CreateNode creates a node in a network.

func (*Store) CreateProposal

func (s *Store) CreateProposal(networkID, description, memberID string) (*Proposal, error)

CreateProposal creates a proposal.

func (*Store) DeleteNetwork

func (s *Store) DeleteNetwork(id string) bool

DeleteNetwork removes a network.

func (*Store) DeleteNode

func (s *Store) DeleteNode(networkID, nodeID string) bool

DeleteNode removes a node.

func (*Store) GetMember

func (s *Store) GetMember(networkID, memberID string) (*Member, bool)

GetMember retrieves a member.

func (*Store) GetNetwork

func (s *Store) GetNetwork(id string) (*Network, bool)

GetNetwork retrieves a network.

func (*Store) GetNode

func (s *Store) GetNode(networkID, nodeID string) (*Node, bool)

GetNode retrieves a node.

func (*Store) GetProposal

func (s *Store) GetProposal(networkID, proposalID string) (*Proposal, bool)

GetProposal retrieves a proposal.

func (*Store) ListMembers

func (s *Store) ListMembers(networkID string) []*Member

ListMembers returns all members for a network.

func (*Store) ListNetworks

func (s *Store) ListNetworks() []*Network

ListNetworks returns all networks.

func (*Store) ListNodes

func (s *Store) ListNodes(networkID string) []*Node

ListNodes returns all nodes for a network.

func (*Store) ListProposals

func (s *Store) ListProposals(networkID string) []*Proposal

ListProposals returns all proposals for a network.

func (*Store) VoteOnProposal

func (s *Store) VoteOnProposal(networkID, proposalID, voterMemberID, vote string) error

VoteOnProposal records a vote on a proposal.

Jump to

Keyboard shortcuts

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