inx

package
v2.0.0-rc.2 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2022 License: Apache-2.0 Imports: 37 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ParamsINX = &ParametersINX{}
View Source
var (
	Plugin *app.Plugin
)

Functions

func NewINXBlockMetadata

func NewINXBlockMetadata(ctx context.Context, blockID iotago.BlockID, metadata *storage.BlockMetadata, tip ...*tipselect.Tip) (*inx.BlockMetadata, error)

func NewLedgerOutput

func NewLedgerOutput(o *utxo.Output) (*inx.LedgerOutput, error)

func NewLedgerSpent

func NewLedgerSpent(s *utxo.Spent) (*inx.LedgerSpent, error)

func NewLedgerUpdateBatchBegin

func NewLedgerUpdateBatchBegin(index iotago.MilestoneIndex, newOutputsCount int, newSpentsCount int) *inx.LedgerUpdate

func NewLedgerUpdateBatchEnd

func NewLedgerUpdateBatchEnd(index iotago.MilestoneIndex, newOutputsCount int, newSpentsCount int) *inx.LedgerUpdate

func NewLedgerUpdateBatchOperationConsumed

func NewLedgerUpdateBatchOperationConsumed(spent *utxo.Spent) (*inx.LedgerUpdate, error)

func NewLedgerUpdateBatchOperationCreated

func NewLedgerUpdateBatchOperationCreated(output *utxo.Output) (*inx.LedgerUpdate, error)

func NewTreasuryUpdate

func NewTreasuryUpdate(index iotago.MilestoneIndex, created *utxo.TreasuryOutput, consumed *utxo.TreasuryOutput) (*inx.TreasuryUpdate, error)

Types

type ParametersINX

type ParametersINX struct {
	// Enabled defines whether the INX plugin is enabled.
	Enabled bool `default:"false" usage:"whether the INX plugin is enabled"`
	// the bind address on which the INX can be accessed from
	BindAddress string `default:"localhost:9029" usage:"the bind address on which the INX can be accessed from"`

	PoW struct {
		// the amount of workers used for calculating PoW when issuing blocks via INX
		WorkerCount int `` /* 131-byte string literal not displayed */
	} `name:"pow"`
}

ParametersINX contains the definition of the parameters used by INX.

type Server

type Server struct {
	inx.UnimplementedINXServer
	// contains filtered or unexported fields
}

func (*Server) ComputeWhiteFlag

func (s *Server) ComputeWhiteFlag(ctx context.Context, req *inx.WhiteFlagRequest) (*inx.WhiteFlagResponse, error)

func (*Server) ConfigurePrometheus

func (s *Server) ConfigurePrometheus()

func (*Server) ListenToBlocks

func (s *Server) ListenToBlocks(_ *inx.NoParams, srv inx.INX_ListenToBlocksServer) error

func (*Server) ListenToConfirmedMilestones

func (s *Server) ListenToConfirmedMilestones(req *inx.MilestoneRangeRequest, srv inx.INX_ListenToConfirmedMilestonesServer) error

func (*Server) ListenToLatestMilestones

func (s *Server) ListenToLatestMilestones(_ *inx.NoParams, srv inx.INX_ListenToLatestMilestonesServer) error

func (*Server) ListenToLedgerUpdates

func (s *Server) ListenToLedgerUpdates(req *inx.MilestoneRangeRequest, srv inx.INX_ListenToLedgerUpdatesServer) error

func (*Server) ListenToMigrationReceipts

func (s *Server) ListenToMigrationReceipts(_ *inx.NoParams, srv inx.INX_ListenToMigrationReceiptsServer) error

func (*Server) ListenToNodeStatus

func (s *Server) ListenToNodeStatus(req *inx.NodeStatusRequest, srv inx.INX_ListenToNodeStatusServer) error

func (*Server) ListenToReferencedBlocks

func (s *Server) ListenToReferencedBlocks(_ *inx.NoParams, srv inx.INX_ListenToReferencedBlocksServer) error

func (*Server) ListenToSolidBlocks

func (s *Server) ListenToSolidBlocks(_ *inx.NoParams, srv inx.INX_ListenToSolidBlocksServer) error

func (*Server) ListenToTipScoreUpdates

func (s *Server) ListenToTipScoreUpdates(_ *inx.NoParams, srv inx.INX_ListenToTipScoreUpdatesServer) error

func (*Server) ListenToTipsMetrics

func (s *Server) ListenToTipsMetrics(req *inx.TipsMetricRequest, srv inx.INX_ListenToTipsMetricsServer) error

func (*Server) ListenToTreasuryUpdates

func (s *Server) ListenToTreasuryUpdates(req *inx.MilestoneRangeRequest, srv inx.INX_ListenToTreasuryUpdatesServer) error

func (*Server) PerformAPIRequest

func (s *Server) PerformAPIRequest(_ context.Context, req *inx.APIRequest) (*inx.APIResponse, error)

func (*Server) ReadBlock

func (s *Server) ReadBlock(_ context.Context, blockID *inx.BlockId) (*inx.RawBlock, error)

func (*Server) ReadBlockMetadata

func (s *Server) ReadBlockMetadata(_ context.Context, blockID *inx.BlockId) (*inx.BlockMetadata, error)

func (*Server) ReadMilestone

func (s *Server) ReadMilestone(_ context.Context, req *inx.MilestoneRequest) (*inx.Milestone, error)

func (*Server) ReadMilestoneCone

func (s *Server) ReadMilestoneCone(req *inx.MilestoneRequest, srv inx.INX_ReadMilestoneConeServer) error

func (*Server) ReadMilestoneConeMetadata

func (s *Server) ReadMilestoneConeMetadata(req *inx.MilestoneRequest, srv inx.INX_ReadMilestoneConeMetadataServer) error

func (*Server) ReadNodeConfiguration

func (s *Server) ReadNodeConfiguration(context.Context, *inx.NoParams) (*inx.NodeConfiguration, error)

func (*Server) ReadNodeStatus

func (s *Server) ReadNodeStatus(context.Context, *inx.NoParams) (*inx.NodeStatus, error)

func (*Server) ReadOutput

func (s *Server) ReadOutput(_ context.Context, id *inx.OutputId) (*inx.OutputResponse, error)

func (*Server) ReadProtocolParameters

func (s *Server) ReadProtocolParameters(_ context.Context, req *inx.MilestoneRequest) (*inx.RawProtocolParameters, error)

func (*Server) ReadUnspentOutputs

func (s *Server) ReadUnspentOutputs(_ *inx.NoParams, srv inx.INX_ReadUnspentOutputsServer) error

func (*Server) RegisterAPIRoute

func (s *Server) RegisterAPIRoute(_ context.Context, req *inx.APIRouteRequest) (*inx.NoParams, error)

func (*Server) RequestTips

func (s *Server) RequestTips(ctx context.Context, req *inx.TipsRequest) (*inx.TipsResponse, error)

func (*Server) Start

func (s *Server) Start()

func (*Server) Stop

func (s *Server) Stop()

func (*Server) SubmitBlock

func (s *Server) SubmitBlock(ctx context.Context, rawBlock *inx.RawBlock) (*inx.BlockId, error)

func (*Server) UnregisterAPIRoute

func (s *Server) UnregisterAPIRoute(_ context.Context, req *inx.APIRouteRequest) (*inx.NoParams, error)

Jump to

Keyboard shortcuts

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