trg

package
v1.48.0 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2026 License: GPL-3.0 Imports: 30 Imported by: 0

Documentation

Overview

Package trg provides integration with the ALICE trigger system.

Package trg provides integration with the ALICE trigger system.

Index

Constants

View Source
const (
	TRG_DIAL_TIMEOUT    = 2 * time.Second
	TRG_PFR_TIMEOUT     = 5 * time.Second
	TRG_LOAD_TIMEOUT    = 5 * time.Second
	TRG_START_TIMEOUT   = 5 * time.Second
	TRG_STOP_TIMEOUT    = 5 * time.Second
	TRG_UNLOAD_TIMEOUT  = 5 * time.Second
	TRG_CLEANUP_TIMEOUT = 5 * time.Second
	TOPIC               = topic.IntegratedService + topic.Separator + "trg"
)

Variables

This section is empty.

Functions

func NewPlugin

func NewPlugin(endpoint string) integration.Plugin

Types

type CtpStatusReader added in v1.48.0

type CtpStatusReader struct {
	*kafka.Reader
}

CtpStatusReader reads CTP status messages from Kafka

func NewCtpStatusReader added in v1.48.0

func NewCtpStatusReader(topic string, groupID string) *CtpStatusReader

NewCtpStatusReader creates a new reader for CTP status messages

func (*CtpStatusReader) Next added in v1.48.0

func (r *CtpStatusReader) Next(ctx context.Context) (*trgpb.Status, error)

Next reads the next CTP status message from Kafka

type Plugin

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

func (*Plugin) CallStack added in v0.29.0

func (p *Plugin) CallStack(data interface{}) (stack map[string]interface{})

func (*Plugin) Destroy

func (p *Plugin) Destroy() error

func (*Plugin) GetConnectionState

func (p *Plugin) GetConnectionState() string

func (*Plugin) GetData

func (p *Plugin) GetData(_ []any) string

func (*Plugin) GetEndpoint

func (p *Plugin) GetEndpoint() string

func (*Plugin) GetEnvironmentsData added in v0.56.0

func (p *Plugin) GetEnvironmentsData(envIds []uid.ID) map[uid.ID]string

func (*Plugin) GetEnvironmentsShortData added in v0.79.0

func (p *Plugin) GetEnvironmentsShortData(envIds []uid.ID) map[uid.ID]string

func (*Plugin) GetName

func (p *Plugin) GetName() string

func (*Plugin) GetPrettyName

func (p *Plugin) GetPrettyName() string

func (*Plugin) Init

func (p *Plugin) Init(instanceId string) error

func (*Plugin) ObjectStack

func (p *Plugin) ObjectStack(_ map[string]string, _ map[string]string) (stack map[string]interface{})

type RpcClient

type RpcClient struct {
	trgecspb.CTPdClient
	// contains filtered or unexported fields
}

func NewClient

func NewClient(cxt context.Context, cancel context.CancelFunc, endpoint string) *RpcClient

func (*RpcClient) Close

func (m *RpcClient) Close() error

func (*RpcClient) GetConnState

func (m *RpcClient) GetConnState() connectivity.State

type Run added in v0.38.1

type Run struct {
	Cardinality RunCardinality
	RunNumber   uint32
	State       State
	Detectors   []system.ID
	Skip        bool
}

type RunCardinality added in v0.38.1

type RunCardinality int
const (
	CTP_STANDALONE RunCardinality
	CTP_GLOBAL
)

type Runs added in v0.38.1

type Runs []Run

type State added in v0.38.1

type State int
const (
	CTP_LOADED State
	CTP_RUNNING
)

type TrgStatus added in v0.38.1

type TrgStatus struct {
	// Fields from TRG RunList queries
	RunCount   int            `json:"runCount,omitempty"`
	Lines      []string       `json:"lines,omitempty"`
	Structured Runs           `json:"structured,omitempty"`
	EnvMap     map[uid.ID]Run `json:"envMap,omitempty"`

	// Fields from CTP status Kafka messages
	Clock                       string   `json:"clock,omitempty"`
	DetectorsInHoldover         []string `json:"detectorsInHoldover,omitempty"`
	ClockTransitionExpectedTime int64    `json:"clockTransitionExpectedTime,omitempty"` // nanoseconds since epoch, 0 if not expected
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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