proc

package
v0.9.12 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2019 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNotExecutor      = errors.New("not executor for jet")
	ErrExecutorMismatch = errors.New("sender isn't executor for object")
	ErrNotActivated     = errors.New("object should be activated")
)

Functions

This section is empty.

Types

type CalculateID

type CalculateID struct {
	Result struct {
		ID insolar.ID
	}
	// contains filtered or unexported fields
}

func NewCalculateID

func NewCalculateID(payload []byte, pulse insolar.PulseNumber) *CalculateID

func (*CalculateID) Dep

func (*CalculateID) Proceed

func (p *CalculateID) Proceed(ctx context.Context) error

type Dependencies

type Dependencies struct {
	FetchJet       func(*FetchJet)
	WaitHot        func(*WaitHot)
	EnsureIndex    func(*EnsureIndex)
	SendObject     func(*SendObject)
	GetCode        func(*GetCode)
	GetRequest     func(*GetRequest)
	GetRequestInfo func(*SendRequestInfo)
	SetRequest     func(*SetRequest)
	SetResult      func(*SetResult)
	GetPendings    func(*GetPendings)
	GetJet         func(*GetJet)
	HotObjects     func(*HotObjects)
	PassState      func(*PassState)
	CalculateID    func(*CalculateID)
	SetCode        func(*SetCode)
	SendFilament   func(*SendFilament)
	HasPendings    func(*HasPendings)
	Config         func() configuration.Ledger
}

func NewDependencies

func NewDependencies(

	pcs insolar.PlatformCryptographyScheme,
	jetCoordinator jet.Coordinator,
	jetStorage jet.Storage,
	pulseCalculator pulse.Calculator,
	sender bus.Sender,

	dropModifier drop.Modifier,
	indexLocker object.IndexLocker,
	recordStorage object.AtomicRecordStorage,
	indexStorage object.MemoryIndexStorage,

	jetReleaser executor.JetReleaser,
	hotWaiter executor.JetWaiter,
	writeAccessor executor.WriteAccessor,
	jetFetcher executor.JetFetcher,
	filaments executor.FilamentCalculator,
	requestChecker executor.RequestChecker,
	detachedNotifier executor.DetachedNotifier,

	config configuration.Ledger,
	registry executor.MetricsRegistry,
) *Dependencies

func NewDependenciesMock

func NewDependenciesMock() *Dependencies

NewDependenciesMock returns all dependencies for handlers. It's all empty. Use it ONLY for tests.

type EnsureIndex

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

func NewEnsureIndex

func NewEnsureIndex(obj insolar.ID, jetID insolar.JetID, msg payload.Meta, pulse insolar.PulseNumber) *EnsureIndex

func (*EnsureIndex) Dep

func (*EnsureIndex) Proceed

func (p *EnsureIndex) Proceed(ctx context.Context) error

type FetchJet

type FetchJet struct {
	Result struct {
		Jet insolar.JetID
	}
	// contains filtered or unexported fields
}

func NewFetchJet

func NewFetchJet(target insolar.ID, pn insolar.PulseNumber, msg payload.Meta, pass bool) *FetchJet

func (*FetchJet) Dep

func (p *FetchJet) Dep(
	jets jet.Accessor,
	fetcher executor.JetFetcher,
	c jet.Coordinator,
	s bus.Sender,
)

func (*FetchJet) Proceed

func (p *FetchJet) Proceed(ctx context.Context) error

type GetCode

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

func NewGetCode

func NewGetCode(msg payload.Meta, codeID insolar.ID, pass bool) *GetCode

func (*GetCode) Dep

func (*GetCode) Proceed

func (p *GetCode) Proceed(ctx context.Context) error

type GetJet

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

func NewGetJet

func NewGetJet(msg payload.Meta, objectID insolar.ID, pulse insolar.PulseNumber) *GetJet

func (*GetJet) Dep

func (p *GetJet) Dep(
	jets jet.Accessor,
	sender bus.Sender,
)

func (*GetJet) Proceed

func (p *GetJet) Proceed(ctx context.Context) error

type GetPendings

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

func NewGetPendings

func NewGetPendings(msg payload.Meta, objectID insolar.ID, count int) *GetPendings

func (*GetPendings) Dep

func (*GetPendings) Proceed

func (p *GetPendings) Proceed(ctx context.Context) error

type GetRequest

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

func NewGetRequest

func NewGetRequest(msg payload.Meta, objectID, requestID insolar.ID, pass bool) *GetRequest

func (*GetRequest) Dep

func (p *GetRequest) Dep(
	records object.RecordAccessor,
	sender bus.Sender,
	coordinator jet.Coordinator,
	fetcher executor.JetFetcher,
)

func (*GetRequest) Proceed

func (p *GetRequest) Proceed(ctx context.Context) error

type HasPendings

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

func NewHasPendings

func NewHasPendings(msg payload.Meta, objectID insolar.ID) *HasPendings

func (*HasPendings) Dep

func (hp *HasPendings) Dep(
	index object.IndexAccessor,
	sender bus.Sender,
)

func (*HasPendings) Proceed

func (hp *HasPendings) Proceed(ctx context.Context) error

type HotObjects

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

func NewHotObjects

func NewHotObjects(
	meta payload.Meta,
	pn insolar.PulseNumber,
	jetID insolar.JetID,
	drop drop.Drop,
	indexes []record.Index,
	availableNotifications uint,
) *HotObjects

func (*HotObjects) Dep

func (p *HotObjects) Dep(
	drops drop.Modifier,
	indexes object.MemoryIndexModifier,
	jStore jet.Storage,
	jFetcher executor.JetFetcher,
	jReleaser executor.JetReleaser,
	coordinator jet.Coordinator,
	pCalc pulse.Calculator,
	sender bus.Sender,
	registry executor.MetricsRegistry,
)

func (*HotObjects) Proceed

func (p *HotObjects) Proceed(ctx context.Context) error

type PassState

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

func NewPassState

func NewPassState(meta payload.Meta, stateID insolar.ID, origin payload.Meta) *PassState

func (*PassState) Dep

func (p *PassState) Dep(
	records object.RecordAccessor,
	sender bus.Sender,
)

func (*PassState) Proceed

func (p *PassState) Proceed(ctx context.Context) error

type SendFilament

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

func NewSendFilament

func NewSendFilament(msg payload.Meta, objID insolar.ID, startFrom insolar.ID, readUntil insolar.PulseNumber) *SendFilament

func (*SendFilament) Dep

func (p *SendFilament) Dep(sender bus.Sender, filaments executor.FilamentCalculator)

func (*SendFilament) Proceed

func (p *SendFilament) Proceed(ctx context.Context) error

type SendObject

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

func NewSendObject

func NewSendObject(
	msg payload.Meta,
	objectID insolar.ID,
	requestID *insolar.ID,
) *SendObject

func (*SendObject) Dep

func (p *SendObject) Dep(
	coordinator jet.Coordinator,
	jets jet.Storage,
	jetFetcher executor.JetFetcher,
	records object.RecordAccessor,
	indexes object.IndexAccessor,
	sender bus.Sender,
	filament executor.FilamentCalculator,
)

func (*SendObject) Proceed

func (p *SendObject) Proceed(ctx context.Context) error

type SendRequestInfo

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

func NewSendRequestInfo

func NewSendRequestInfo(
	msg payload.Meta,
	objectID insolar.ID,
	requestID insolar.ID,
	pulse insolar.PulseNumber,
) *SendRequestInfo

func (*SendRequestInfo) Dep

func (p *SendRequestInfo) Dep(
	filament executor.FilamentCalculator,
	sender bus.Sender,
	locker object.IndexLocker,
)

func (*SendRequestInfo) Proceed

func (p *SendRequestInfo) Proceed(ctx context.Context) error

type SetCode

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

func NewSetCode

func NewSetCode(msg payload.Meta, rec record.Virtual, recID insolar.ID, jetID insolar.JetID) *SetCode

func (*SetCode) Proceed

func (p *SetCode) Proceed(ctx context.Context) error

type SetRequest

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

func NewSetRequest

func NewSetRequest(
	msg payload.Meta,
	rec record.Request,
	recID insolar.ID,
	jetID insolar.JetID,
) *SetRequest

func (*SetRequest) Proceed

func (p *SetRequest) Proceed(ctx context.Context) error

type SetResult

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

func NewSetResult

func NewSetResult(
	msg payload.Meta,
	jetID insolar.JetID,
	result record.Result,
	sideEffect record.State,
) *SetResult

func (*SetResult) Proceed

func (p *SetResult) Proceed(ctx context.Context) error

type WaitHot

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

func NewWaitHot

func NewWaitHot(j insolar.JetID, pn insolar.PulseNumber, msg payload.Meta) *WaitHot

func (*WaitHot) Dep

func (p *WaitHot) Dep(
	w executor.JetWaiter,
)

func (*WaitHot) Proceed

func (p *WaitHot) Proceed(ctx context.Context) error

Jump to

Keyboard shortcuts

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