medialive

package
v1.1.2 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2026 License: MIT Imports: 19 Imported by: 0

README

MediaLive

Parity grade: A · SDK aws-sdk-go-v2/service/medialive@v1.97.2 · last audited 2026-07-12 (066717f8a6524d92673f3364ce570fdcbaefec1a)

Coverage

Metric Value
Known gaps 6
Deferred items 0
Resource leaks clean
Known gaps
  • InputDevice request-body parsing (ClaimDevice/UpdateInputDevice/TransferInputDevice) still reads PascalCase keys ("Id"/"TargetCustomerId"/"TargetRegion"/"TransferMessage") that don't match the real lowerCamel request shape -- verified wrong against the SDK serializer, deliberately left alone this pass per the task's InputDevice scope boundary (output-struct casing only). (bd: needs filing)
  • Cluster.ChannelIds / Node.ChannelPlacementGroups are real wire fields gopherstack now emits (matching the real shape) but always as an empty list -- gopherstack doesn't track cluster<->channel or node<->channel-placement-group association. Correctness gap, not a casing gap. (bd: needs filing)
  • CloudWatchAlarmTemplateGroup/EventBridgeRuleTemplateGroup List responses are missing "templateCount" (real Summary-shape field); CloudWatchAlarmTemplate/EventBridgeRuleTemplate Get/Create/Update responses already correctly omit it (verified not present on those shapes). Would need a new backend method to count templates per group. (bd: needs filing)
  • EventBridgeRuleTemplate List response returns the full "eventTargets" array per item instead of the real Summary shape's "eventTargetCount" integer. (bd: needs filing)
  • Reservation model doesn't track "renewalSettings" (a real field on DescribeReservationOutput/Reservation) at all -- PurchaseOffering/UpdateReservation accept but discard any renewalSettings the caller sends. New-field gap, not a casing gap. (bd: needs filing)
  • Deep state/error-code audit of Cluster, Node, SignalMap, Reservation/Offering purchase flow, Batch semantics beyond the wire-casing scope of this pass and sweep 4's fixes above was not re-performed (route matching for all of them was verified correct; op-by-op state-machine correctness beyond what this pass touched was not re-verified).

More

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrConflict = awserr.New("ConflictException", awserr.ErrAlreadyExists)

ErrConflict is returned for state conflict operations.

View Source
var ErrInvalidParameter = awserr.New("BadRequestException", awserr.ErrInvalidParameter)

ErrInvalidParameter is returned for invalid input.

View Source
var ErrNilAppContext = errors.New("AppContext is required")

ErrNilAppContext is returned when Provider.Init is called with a nil AppContext.

View Source
var ErrNotFound = awserr.New("NotFoundException", awserr.ErrNotFound)

ErrNotFound is returned when a resource does not exist.

Functions

This section is empty.

Types

type AccountConfiguration

type AccountConfiguration struct {
	KmsKeyID string
}

AccountConfiguration holds account-wide MediaLive settings.

type BatchFailedResult

type BatchFailedResult struct {
	Arn     string
	ID      string
	Code    string
	Message string
}

BatchFailedResult is a failed result in a batch operation.

type BatchResult

type BatchResult struct {
	Successful []BatchSuccessfulResult
	Failed     []BatchFailedResult
}

BatchResult holds results of a batch start/stop/delete.

type BatchSuccessfulResult

type BatchSuccessfulResult struct {
	Arn   string
	ID    string
	State string
}

BatchSuccessfulResult is a successful result in a batch operation.

type BatchUpdateScheduleResult

type BatchUpdateScheduleResult struct {
	Creates []ScheduleAction
	Deletes []ScheduleAction
}

BatchUpdateScheduleResult holds the result of BatchUpdateSchedule.

type Channel

type Channel struct {
	Tags         map[string]string
	ARN          string
	ID           string
	Name         string
	ChannelClass string
	RoleARN      string
	State        string
}

Channel represents a MediaLive channel. Tags first: reduces GC pointer scan from 104 to 96 bytes.

type ChannelEngineVersion

type ChannelEngineVersion struct {
	ExpirationDate string
	Version        string
}

ChannelEngineVersion is an available channel engine version.

type ChannelPlacementGroup

type ChannelPlacementGroup struct {
	Tags      map[string]string
	ARN       string
	ID        string
	Name      string
	ClusterID string
	State     string
	Channels  []string
	Nodes     []string
}

ChannelPlacementGroup represents a placement group within a cluster.

type ChannelSummary

type ChannelSummary struct {
	ARN          string
	ID           string
	Name         string
	ChannelClass string
	State        string
}

ChannelSummary is a channel in a list response.

type CloudWatchAlarmTemplate

type CloudWatchAlarmTemplate struct {
	CreatedAt          time.Time
	ModifiedAt         time.Time
	Tags               map[string]string
	Arn                string
	ID                 string
	Name               string
	Description        string
	GroupID            string
	GroupIdentifier    string
	MetricName         string
	Namespace          string
	Statistic          string
	ComparisonOperator string
	TargetResourceType string
	TreatMissingData   string
	Threshold          float64
	EvaluationPeriods  int32
	DatapointsToAlarm  int32
	Period             int32
}

CloudWatchAlarmTemplate is a template for generating CloudWatch alarms.

type CloudWatchAlarmTemplateGroup

type CloudWatchAlarmTemplateGroup struct {
	CreatedAt   time.Time
	ModifiedAt  time.Time
	Tags        map[string]string
	Arn         string
	ID          string
	Name        string
	Description string
}

CloudWatchAlarmTemplateGroup is a named group for CloudWatch alarm templates.

type Cluster

type Cluster struct {
	Tags            map[string]string
	ARN             string
	ID              string
	Name            string
	ClusterType     string
	InstanceRoleArn string
	State           string
}

Cluster represents a MediaLive Anywhere Cluster resource. Tags first: reduces GC pointer scan.

type ClusterSummary

type ClusterSummary struct {
	ARN             string
	ID              string
	Name            string
	ClusterType     string
	InstanceRoleArn string
	State           string
}

ClusterSummary is a Cluster in a list response.

type EventBridgeRuleTemplate

type EventBridgeRuleTemplate struct {
	CreatedAt       time.Time
	ModifiedAt      time.Time
	Tags            map[string]string
	Arn             string
	ID              string
	Name            string
	Description     string
	GroupID         string
	GroupIdentifier string
	EventType       string
	EventTargets    []EventBridgeRuleTemplateTarget
}

EventBridgeRuleTemplate is a template for EventBridge rules.

type EventBridgeRuleTemplateGroup

type EventBridgeRuleTemplateGroup struct {
	CreatedAt   time.Time
	ModifiedAt  time.Time
	Tags        map[string]string
	Arn         string
	ID          string
	Name        string
	Description string
}

EventBridgeRuleTemplateGroup is a named group for EventBridge rule templates.

type EventBridgeRuleTemplateTarget

type EventBridgeRuleTemplateTarget struct {
	Arn string `json:"arn"`
}

EventBridgeRuleTemplateTarget is a target ARN for an EventBridge rule.

type Handler

type Handler struct {
	Backend StorageBackend
}

Handler handles MediaLive HTTP requests.

func NewHandler

func NewHandler(b StorageBackend) *Handler

NewHandler constructs a new Handler.

func (*Handler) ExtractOperation

func (h *Handler) ExtractOperation(c *echo.Context) string

ExtractOperation classifies the request into an operation name.

func (*Handler) ExtractResource

func (h *Handler) ExtractResource(c *echo.Context) string

ExtractResource returns the resource identifier from the request.

func (*Handler) GetSupportedOperations

func (h *Handler) GetSupportedOperations() []string

GetSupportedOperations returns all supported operations.

func (*Handler) Handler

func (h *Handler) Handler() echo.HandlerFunc

Handler returns the Echo handler function.

func (*Handler) MatchPriority

func (h *Handler) MatchPriority() int

MatchPriority returns the routing priority.

func (*Handler) Name

func (h *Handler) Name() string

Name returns the service name.

func (*Handler) Reset

func (h *Handler) Reset()

Reset resets the backend.

func (*Handler) Restore

func (h *Handler) Restore(ctx context.Context, data []byte) error

Restore implements persistence.Persistable by delegating to the backend.

func (*Handler) RouteMatcher

func (h *Handler) RouteMatcher() service.Matcher

RouteMatcher returns a function that matches MediaLive requests by path.

func (*Handler) Snapshot

func (h *Handler) Snapshot(ctx context.Context) []byte

Snapshot implements persistence.Persistable by delegating to the backend.

h.Backend is the StorageBackend interface, which already declares Snapshot(ctx context.Context) []byte (see interfaces.go) with a shape matching persistence.Persistable exactly, so this can call it directly -- no local type assertion needed. But interface membership alone does not help: h.Backend is a named field, not an embedded one, so InMemoryBackend's methods are never promoted onto *Handler. Without this delegation, cli.go's setupPersistence type-asserts the registered service.Registerable (this *Handler) against persistence.Persistable, fails silently, and never registers medialive for snapshot/restore despite the backend being fully capable. Mirrors services/securityhub's Handler-level delegation.

type IPPool

type IPPool struct {
	Cidr string `json:"cidr"`
}

IPPool is a CIDR pool for a Network.

type InMemoryBackend

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

InMemoryBackend is an in-memory implementation of StorageBackend.

func NewInMemoryBackend

func NewInMemoryBackend(accountID, region string) *InMemoryBackend

NewInMemoryBackend creates a new InMemoryBackend.

func (*InMemoryBackend) AcceptInputDeviceTransfer

func (b *InMemoryBackend) AcceptInputDeviceTransfer(deviceID string) error

AcceptInputDeviceTransfer accepts an incoming transfer and completes it.

func (*InMemoryBackend) AccountID

func (b *InMemoryBackend) AccountID() string

AccountID returns the configured account ID.

func (*InMemoryBackend) BatchDelete

func (b *InMemoryBackend) BatchDelete(
	channelIDs, inputIDs, multiplexIDs, inputSecurityGroupIDs []string,
) (*BatchResult, error)

BatchDelete deletes channels/inputs/multiplexes/input-security-groups in bulk.

func (*InMemoryBackend) BatchStart

func (b *InMemoryBackend) BatchStart(
	channelIDs, multiplexIDs []string,
) (*BatchResult, error)

BatchStart starts channels/multiplexes in bulk (BatchStartInput has no inputIds field in the real API).

func (*InMemoryBackend) BatchStop

func (b *InMemoryBackend) BatchStop(
	channelIDs, multiplexIDs []string,
) (*BatchResult, error)

BatchStop stops channels/multiplexes in bulk (BatchStopInput has no inputIds field in the real API).

func (*InMemoryBackend) BatchUpdateSchedule

func (b *InMemoryBackend) BatchUpdateSchedule(
	channelID string,
	creates []ScheduleAction,
	deleteActionNames []string,
) (*BatchUpdateScheduleResult, error)

BatchUpdateSchedule adds/removes schedule actions for a channel.

func (*InMemoryBackend) CancelInputDeviceTransfer

func (b *InMemoryBackend) CancelInputDeviceTransfer(deviceID string) error

CancelInputDeviceTransfer cancels an outgoing transfer.

func (*InMemoryBackend) ClaimDevice

func (b *InMemoryBackend) ClaimDevice(id string) (*InputDevice, error)

ClaimDevice registers a device (by ID) into this account.

func (*InMemoryBackend) CreateChannel

func (b *InMemoryBackend) CreateChannel(
	name, channelClass, roleArn string,
	tags map[string]string,
) (*Channel, error)

CreateChannel creates a new channel.

func (*InMemoryBackend) CreateChannelPlacementGroup

func (b *InMemoryBackend) CreateChannelPlacementGroup(
	clusterID, name string,
	nodes []string,
	tags map[string]string,
) (*ChannelPlacementGroup, error)

CreateChannelPlacementGroup creates a placement group within a cluster.

func (*InMemoryBackend) CreateCloudWatchAlarmTemplate

func (b *InMemoryBackend) CreateCloudWatchAlarmTemplate(
	name string,
	description string,
	groupIdentifier string,
	metricName string,
	namespace string,
	statistic string,
	comparisonOperator string,
	targetResourceType string,
	treatMissingData string,
	threshold float64,
	evaluationPeriods, datapointsToAlarm, period int32,
	tags map[string]string,
) (*CloudWatchAlarmTemplate, error)

CreateCloudWatchAlarmTemplate creates a new CW alarm template.

func (*InMemoryBackend) CreateCloudWatchAlarmTemplateGroup

func (b *InMemoryBackend) CreateCloudWatchAlarmTemplateGroup(
	name, description string, tags map[string]string,
) (*CloudWatchAlarmTemplateGroup, error)

CreateCloudWatchAlarmTemplateGroup creates a new CW alarm template group.

func (*InMemoryBackend) CreateCluster

func (b *InMemoryBackend) CreateCluster(
	name, clusterType, instanceRoleArn string,
	tags map[string]string,
) (*Cluster, error)

CreateCluster creates a new Cluster.

func (*InMemoryBackend) CreateEventBridgeRuleTemplate

func (b *InMemoryBackend) CreateEventBridgeRuleTemplate(
	name, description, groupIdentifier, eventType string,
	eventTargets []EventBridgeRuleTemplateTarget,
	tags map[string]string,
) (*EventBridgeRuleTemplate, error)

CreateEventBridgeRuleTemplate creates a new EB rule template.

func (*InMemoryBackend) CreateEventBridgeRuleTemplateGroup

func (b *InMemoryBackend) CreateEventBridgeRuleTemplateGroup(
	name, description string, tags map[string]string,
) (*EventBridgeRuleTemplateGroup, error)

CreateEventBridgeRuleTemplateGroup creates a new EB rule template group.

func (*InMemoryBackend) CreateInput

func (b *InMemoryBackend) CreateInput(
	name, inputType, roleArn string,
	tags map[string]string,
) (*Input, error)

CreateInput creates a new input.

func (*InMemoryBackend) CreateInputSecurityGroup

func (b *InMemoryBackend) CreateInputSecurityGroup(
	whitelistRules []WhitelistRule,
	tags map[string]string,
) (*InputSecurityGroup, error)

CreateInputSecurityGroup creates a new input security group.

func (*InMemoryBackend) CreateMultiplex

func (b *InMemoryBackend) CreateMultiplex(
	name string,
	availabilityZones []string,
	settings MultiplexSettings,
	tags map[string]string,
) (*Multiplex, error)

CreateMultiplex creates a new Multiplex.

func (*InMemoryBackend) CreateMultiplexProgram

func (b *InMemoryBackend) CreateMultiplexProgram(
	multiplexID string,
	prog MultiplexProgramSettings,
) (*MultiplexProgram, error)

CreateMultiplexProgram creates a program within a Multiplex.

func (*InMemoryBackend) CreateNetwork

func (b *InMemoryBackend) CreateNetwork(
	name string,
	ipPools []IPPool,
	routes []Route,
	tags map[string]string,
) (*Network, error)

CreateNetwork creates a new Network.

func (*InMemoryBackend) CreateNode

func (b *InMemoryBackend) CreateNode(
	clusterID, name, role string,
	tags map[string]string,
) (*Node, error)

CreateNode creates a Node within a Cluster.

func (*InMemoryBackend) CreateNodeRegistrationScript

func (b *InMemoryBackend) CreateNodeRegistrationScript(clusterID string) (string, error)

CreateNodeRegistrationScript returns a registration script for a Cluster Node.

func (*InMemoryBackend) CreatePartnerInput

func (b *InMemoryBackend) CreatePartnerInput(
	inputID string,
	tags map[string]string,
) (*Input, error)

CreatePartnerInput creates a partner input linked to an existing input.

func (*InMemoryBackend) CreateSdiSource

func (b *InMemoryBackend) CreateSdiSource(
	name, sdiType, mode string,
	_ map[string]string,
) (*SdiSource, error)

CreateSdiSource creates a new SDI source.

func (*InMemoryBackend) CreateSignalMap

func (b *InMemoryBackend) CreateSignalMap(
	name, description, discoveryEntryPointArn string,
	cwGroupIDs, ebGroupIDs []string,
	tags map[string]string,
) (*SignalMap, error)

CreateSignalMap creates a new signal map.

func (*InMemoryBackend) CreateTags

func (b *InMemoryBackend) CreateTags(resourceARN string, tags map[string]string) error

CreateTags adds tags to a resource.

func (*InMemoryBackend) DeleteChannel

func (b *InMemoryBackend) DeleteChannel(channelID string) (*Channel, error)

DeleteChannel deletes a channel.

func (*InMemoryBackend) DeleteChannelPlacementGroup

func (b *InMemoryBackend) DeleteChannelPlacementGroup(
	clusterID, groupID string,
) (*ChannelPlacementGroup, error)

DeleteChannelPlacementGroup deletes a placement group.

func (*InMemoryBackend) DeleteCloudWatchAlarmTemplate

func (b *InMemoryBackend) DeleteCloudWatchAlarmTemplate(identifier string) error

DeleteCloudWatchAlarmTemplate deletes a CW alarm template.

func (*InMemoryBackend) DeleteCloudWatchAlarmTemplateGroup

func (b *InMemoryBackend) DeleteCloudWatchAlarmTemplateGroup(identifier string) error

DeleteCloudWatchAlarmTemplateGroup deletes a CW alarm template group.

func (*InMemoryBackend) DeleteCluster

func (b *InMemoryBackend) DeleteCluster(clusterID string) (*Cluster, error)

DeleteCluster deletes a Cluster.

func (*InMemoryBackend) DeleteEventBridgeRuleTemplate

func (b *InMemoryBackend) DeleteEventBridgeRuleTemplate(identifier string) error

DeleteEventBridgeRuleTemplate deletes an EB rule template.

func (*InMemoryBackend) DeleteEventBridgeRuleTemplateGroup

func (b *InMemoryBackend) DeleteEventBridgeRuleTemplateGroup(identifier string) error

DeleteEventBridgeRuleTemplateGroup deletes an EB rule template group.

func (*InMemoryBackend) DeleteInput

func (b *InMemoryBackend) DeleteInput(inputID string) error

DeleteInput deletes an input.

func (*InMemoryBackend) DeleteInputSecurityGroup

func (b *InMemoryBackend) DeleteInputSecurityGroup(groupID string) error

DeleteInputSecurityGroup deletes an input security group.

func (*InMemoryBackend) DeleteMultiplex

func (b *InMemoryBackend) DeleteMultiplex(multiplexID string) (*Multiplex, error)

DeleteMultiplex deletes a Multiplex.

func (*InMemoryBackend) DeleteMultiplexProgram

func (b *InMemoryBackend) DeleteMultiplexProgram(
	multiplexID, programName string,
) (*MultiplexProgram, error)

DeleteMultiplexProgram removes a program from a Multiplex.

func (*InMemoryBackend) DeleteNetwork

func (b *InMemoryBackend) DeleteNetwork(networkID string) (*Network, error)

DeleteNetwork deletes a Network.

func (*InMemoryBackend) DeleteNode

func (b *InMemoryBackend) DeleteNode(clusterID, nodeID string) (*Node, error)

DeleteNode removes a Node from a Cluster.

func (*InMemoryBackend) DeleteReservation

func (b *InMemoryBackend) DeleteReservation(reservationID string) (*Reservation, error)

DeleteReservation cancels a reservation.

func (*InMemoryBackend) DeleteSchedule

func (b *InMemoryBackend) DeleteSchedule(channelID string) error

DeleteSchedule removes all schedule actions for a channel.

func (*InMemoryBackend) DeleteSdiSource

func (b *InMemoryBackend) DeleteSdiSource(sdiSourceID string) (*SdiSource, error)

DeleteSdiSource deletes an SDI source.

func (*InMemoryBackend) DeleteSignalMap

func (b *InMemoryBackend) DeleteSignalMap(identifier string) error

DeleteSignalMap deletes a signal map.

func (*InMemoryBackend) DeleteTags

func (b *InMemoryBackend) DeleteTags(resourceARN string, tagKeys []string) error

DeleteTags removes tag keys from a resource.

func (*InMemoryBackend) DescribeAccountConfiguration

func (b *InMemoryBackend) DescribeAccountConfiguration() (*AccountConfiguration, error)

DescribeAccountConfiguration returns the account-wide configuration.

func (*InMemoryBackend) DescribeChannel

func (b *InMemoryBackend) DescribeChannel(channelID string) (*Channel, error)

DescribeChannel returns a channel by ID.

func (*InMemoryBackend) DescribeChannelPlacementGroup

func (b *InMemoryBackend) DescribeChannelPlacementGroup(
	clusterID, groupID string,
) (*ChannelPlacementGroup, error)

DescribeChannelPlacementGroup returns a placement group by cluster and group ID.

func (*InMemoryBackend) DescribeCluster

func (b *InMemoryBackend) DescribeCluster(clusterID string) (*Cluster, error)

DescribeCluster returns a Cluster by ID.

func (*InMemoryBackend) DescribeInput

func (b *InMemoryBackend) DescribeInput(inputID string) (*Input, error)

DescribeInput returns an input by ID.

func (*InMemoryBackend) DescribeInputDevice

func (b *InMemoryBackend) DescribeInputDevice(deviceID string) (*InputDevice, error)

DescribeInputDevice returns an input device by ID.

func (*InMemoryBackend) DescribeInputDeviceThumbnail

func (b *InMemoryBackend) DescribeInputDeviceThumbnail(deviceID string) (*InputDevice, error)

DescribeInputDeviceThumbnail returns the device (thumbnail image data is not emulated).

func (*InMemoryBackend) DescribeInputSecurityGroup

func (b *InMemoryBackend) DescribeInputSecurityGroup(groupID string) (*InputSecurityGroup, error)

DescribeInputSecurityGroup returns an input security group by ID.

func (*InMemoryBackend) DescribeMultiplex

func (b *InMemoryBackend) DescribeMultiplex(multiplexID string) (*Multiplex, error)

DescribeMultiplex returns a Multiplex by ID.

func (*InMemoryBackend) DescribeMultiplexProgram

func (b *InMemoryBackend) DescribeMultiplexProgram(
	multiplexID, programName string,
) (*MultiplexProgram, error)

DescribeMultiplexProgram returns a program by multiplex ID and program name.

func (*InMemoryBackend) DescribeNetwork

func (b *InMemoryBackend) DescribeNetwork(networkID string) (*Network, error)

DescribeNetwork returns a Network by ID.

func (*InMemoryBackend) DescribeNode

func (b *InMemoryBackend) DescribeNode(clusterID, nodeID string) (*Node, error)

DescribeNode returns a Node by cluster ID and node ID.

func (*InMemoryBackend) DescribeOffering

func (b *InMemoryBackend) DescribeOffering(offeringID string) (*Offering, error)

DescribeOffering returns a single offering by ID.

func (*InMemoryBackend) DescribeReservation

func (b *InMemoryBackend) DescribeReservation(reservationID string) (*Reservation, error)

DescribeReservation returns a single reservation.

func (*InMemoryBackend) DescribeSchedule

func (b *InMemoryBackend) DescribeSchedule(channelID string) ([]ScheduleAction, error)

DescribeSchedule returns the schedule actions for a channel.

func (*InMemoryBackend) DescribeSdiSource

func (b *InMemoryBackend) DescribeSdiSource(sdiSourceID string) (*SdiSource, error)

DescribeSdiSource returns an SDI source by ID.

func (*InMemoryBackend) DescribeThumbnails

func (b *InMemoryBackend) DescribeThumbnails(channelID string) (*Channel, error)

DescribeThumbnails returns the channel (thumbnails are not emulated as image data).

func (*InMemoryBackend) GetCloudWatchAlarmTemplate

func (b *InMemoryBackend) GetCloudWatchAlarmTemplate(
	identifier string,
) (*CloudWatchAlarmTemplate, error)

GetCloudWatchAlarmTemplate returns a CW alarm template by identifier.

func (*InMemoryBackend) GetCloudWatchAlarmTemplateGroup

func (b *InMemoryBackend) GetCloudWatchAlarmTemplateGroup(
	identifier string,
) (*CloudWatchAlarmTemplateGroup, error)

GetCloudWatchAlarmTemplateGroup returns a CW alarm template group by identifier.

func (*InMemoryBackend) GetEventBridgeRuleTemplate

func (b *InMemoryBackend) GetEventBridgeRuleTemplate(
	identifier string,
) (*EventBridgeRuleTemplate, error)

GetEventBridgeRuleTemplate returns an EB rule template.

func (*InMemoryBackend) GetEventBridgeRuleTemplateGroup

func (b *InMemoryBackend) GetEventBridgeRuleTemplateGroup(
	identifier string,
) (*EventBridgeRuleTemplateGroup, error)

GetEventBridgeRuleTemplateGroup returns an EB rule template group.

func (*InMemoryBackend) GetSignalMap

func (b *InMemoryBackend) GetSignalMap(identifier string) (*SignalMap, error)

GetSignalMap returns a signal map by identifier.

func (*InMemoryBackend) ListAlerts

func (b *InMemoryBackend) ListAlerts(channelID string) ([]map[string]any, error)

ListAlerts returns alerts for a channel (always empty in emulation).

func (*InMemoryBackend) ListChannelPlacementGroups

func (b *InMemoryBackend) ListChannelPlacementGroups(
	clusterID string,
	maxResults int,
	nextToken string,
) ([]*ChannelPlacementGroup, string, error)

ListChannelPlacementGroups returns a paginated list of placement groups in a cluster.

func (*InMemoryBackend) ListChannels

func (b *InMemoryBackend) ListChannels(
	maxResults int,
	nextToken string,
) ([]*ChannelSummary, string, error)

ListChannels returns a paginated list of channels.

func (*InMemoryBackend) ListCloudWatchAlarmTemplateGroups

func (b *InMemoryBackend) ListCloudWatchAlarmTemplateGroups(
	maxResults int,
	nextToken string,
) ([]*CloudWatchAlarmTemplateGroup, string, error)

ListCloudWatchAlarmTemplateGroups returns all CW alarm template groups.

func (*InMemoryBackend) ListCloudWatchAlarmTemplates

func (b *InMemoryBackend) ListCloudWatchAlarmTemplates(
	maxResults int,
	nextToken string,
) ([]*CloudWatchAlarmTemplate, string, error)

ListCloudWatchAlarmTemplates returns all CW alarm templates.

func (*InMemoryBackend) ListClusterAlerts

func (b *InMemoryBackend) ListClusterAlerts(
	clusterID string,
	_ int,
	_ string,
) ([]map[string]any, string, error)

ListClusterAlerts returns alerts for a Cluster.

func (*InMemoryBackend) ListClusters

func (b *InMemoryBackend) ListClusters(
	maxResults int,
	nextToken string,
) ([]*ClusterSummary, string, error)

ListClusters returns a paginated list of Clusters.

func (*InMemoryBackend) ListEventBridgeRuleTemplateGroups

func (b *InMemoryBackend) ListEventBridgeRuleTemplateGroups(
	maxResults int,
	nextToken string,
) ([]*EventBridgeRuleTemplateGroup, string, error)

ListEventBridgeRuleTemplateGroups returns all EB rule template groups.

func (*InMemoryBackend) ListEventBridgeRuleTemplates

func (b *InMemoryBackend) ListEventBridgeRuleTemplates(
	maxResults int,
	nextToken string,
) ([]*EventBridgeRuleTemplate, string, error)

ListEventBridgeRuleTemplates returns all EB rule templates.

func (*InMemoryBackend) ListInputDeviceTransfers

func (b *InMemoryBackend) ListInputDeviceTransfers(
	transferType string,
	maxResults int,
	nextToken string,
) ([]*InputDeviceTransfer, string, error)

ListInputDeviceTransfers lists devices with pending transfers. transferType must be "OUTGOING" or "INCOMING"; in this mock both resolve against the same pending-transfer store (we don't track the recipient side separately).

func (*InMemoryBackend) ListInputDevices

func (b *InMemoryBackend) ListInputDevices(
	maxResults int,
	nextToken string,
) ([]*InputDevice, string, error)

ListInputDevices returns a paginated list of input devices.

func (*InMemoryBackend) ListInputSecurityGroups

func (b *InMemoryBackend) ListInputSecurityGroups(
	maxResults int,
	nextToken string,
) ([]*InputSecurityGroupSummary, string, error)

ListInputSecurityGroups returns a paginated list of input security groups.

func (*InMemoryBackend) ListInputs

func (b *InMemoryBackend) ListInputs(
	maxResults int,
	nextToken string,
) ([]*InputSummary, string, error)

ListInputs returns a paginated list of inputs.

func (*InMemoryBackend) ListMultiplexAlerts

func (b *InMemoryBackend) ListMultiplexAlerts(multiplexID string) ([]map[string]any, error)

ListMultiplexAlerts returns alerts for a multiplex (always empty in emulation).

func (*InMemoryBackend) ListMultiplexPrograms

func (b *InMemoryBackend) ListMultiplexPrograms(
	multiplexID string,
	maxResults int,
	nextToken string,
) ([]*MultiplexProgramSummary, string, error)

ListMultiplexPrograms returns a paginated list of programs for a Multiplex.

func (*InMemoryBackend) ListMultiplexes

func (b *InMemoryBackend) ListMultiplexes(
	maxResults int,
	nextToken string,
) ([]*MultiplexSummary, string, error)

ListMultiplexes returns a paginated list of multiplexes.

func (*InMemoryBackend) ListNetworks

func (b *InMemoryBackend) ListNetworks(
	maxResults int,
	nextToken string,
) ([]*Network, string, error)

ListNetworks returns a paginated list of Networks.

func (*InMemoryBackend) ListNodes

func (b *InMemoryBackend) ListNodes(
	clusterID string,
	maxResults int,
	nextToken string,
) ([]*NodeSummary, string, error)

ListNodes returns a paginated list of Nodes in a Cluster.

func (*InMemoryBackend) ListOfferings

func (b *InMemoryBackend) ListOfferings(
	maxResults int,
	nextToken string,
) ([]*Offering, string, error)

ListOfferings returns the seeded offering catalog.

func (*InMemoryBackend) ListReservations

func (b *InMemoryBackend) ListReservations(
	maxResults int,
	nextToken string,
) ([]*Reservation, string, error)

ListReservations returns all reservations.

func (*InMemoryBackend) ListSdiSources

func (b *InMemoryBackend) ListSdiSources(
	maxResults int,
	nextToken string,
) ([]*SdiSource, string, error)

ListSdiSources returns a paginated list of SDI sources.

func (*InMemoryBackend) ListSignalMaps

func (b *InMemoryBackend) ListSignalMaps(
	maxResults int,
	nextToken string,
) ([]*SignalMap, string, error)

ListSignalMaps returns all signal maps.

func (*InMemoryBackend) ListTagsForResource

func (b *InMemoryBackend) ListTagsForResource(resourceARN string) (map[string]string, error)

ListTagsForResource returns all tags for a resource.

func (*InMemoryBackend) ListVersions

func (b *InMemoryBackend) ListVersions() []ChannelEngineVersion

ListVersions returns the available channel engine versions.

func (*InMemoryBackend) PurchaseOffering

func (b *InMemoryBackend) PurchaseOffering(
	offeringID, name string,
	count int32,
	tags map[string]string,
) (*Reservation, error)

PurchaseOffering creates a Reservation from an Offering.

func (*InMemoryBackend) RebootInputDevice

func (b *InMemoryBackend) RebootInputDevice(deviceID string) error

RebootInputDevice initiates a reboot of the device (no-op in emulation).

func (*InMemoryBackend) Region

func (b *InMemoryBackend) Region() string

Region returns the configured region.

func (*InMemoryBackend) RejectInputDeviceTransfer

func (b *InMemoryBackend) RejectInputDeviceTransfer(deviceID string) error

RejectInputDeviceTransfer rejects an incoming transfer.

func (*InMemoryBackend) Reset

func (b *InMemoryBackend) Reset()

Reset clears all stored data.

func (*InMemoryBackend) RestartChannelPipelines

func (b *InMemoryBackend) RestartChannelPipelines(
	channelID string,
	_ []string,
) (*Channel, error)

RestartChannelPipelines restarts a channel's pipelines (returns the channel).

func (*InMemoryBackend) Restore

func (b *InMemoryBackend) Restore(ctx context.Context, data []byte) error

Restore deserializes state from JSON.

func (*InMemoryBackend) Snapshot

func (b *InMemoryBackend) Snapshot(ctx context.Context) []byte

Snapshot serializes current state to JSON.

func (*InMemoryBackend) StartChannel

func (b *InMemoryBackend) StartChannel(channelID string) (*Channel, error)

StartChannel transitions a channel toward RUNNING. The stored state advances immediately to RUNNING (deterministic emulation), but the API response carries STARTING to match the real AWS intermediate-state contract.

func (*InMemoryBackend) StartDeleteMonitorDeployment

func (b *InMemoryBackend) StartDeleteMonitorDeployment(identifier string) (*SignalMap, error)

StartDeleteMonitorDeployment tears down the monitor deployment for a signal map.

func (*InMemoryBackend) StartInputDevice

func (b *InMemoryBackend) StartInputDevice(deviceID string) error

StartInputDevice starts an input device (no-op aside from existence check).

func (*InMemoryBackend) StartInputDeviceMaintenanceWindow

func (b *InMemoryBackend) StartInputDeviceMaintenanceWindow(deviceID string) error

StartInputDeviceMaintenanceWindow opens a maintenance window for the device.

func (*InMemoryBackend) StartMonitorDeployment

func (b *InMemoryBackend) StartMonitorDeployment(identifier string) (*SignalMap, error)

StartMonitorDeployment deploys monitoring for a signal map.

func (*InMemoryBackend) StartMultiplex

func (b *InMemoryBackend) StartMultiplex(multiplexID string) (*Multiplex, error)

StartMultiplex transitions a Multiplex toward RUNNING. Stored state advances immediately; response carries STARTING per AWS contract.

func (*InMemoryBackend) StartUpdateSignalMap

func (b *InMemoryBackend) StartUpdateSignalMap(
	identifier, name, description string,
	cwGroupIDs, ebGroupIDs []string,
) (*SignalMap, error)

StartUpdateSignalMap updates a signal map's configuration.

func (*InMemoryBackend) StopChannel

func (b *InMemoryBackend) StopChannel(channelID string) (*Channel, error)

StopChannel transitions a channel toward IDLE. The stored state advances immediately to IDLE (deterministic emulation), but the API response carries STOPPING to match the real AWS intermediate-state contract.

func (*InMemoryBackend) StopInputDevice

func (b *InMemoryBackend) StopInputDevice(deviceID string) error

StopInputDevice stops an input device (no-op aside from existence check).

func (*InMemoryBackend) StopMultiplex

func (b *InMemoryBackend) StopMultiplex(multiplexID string) (*Multiplex, error)

StopMultiplex transitions a Multiplex toward IDLE. Stored state advances immediately; response carries STOPPING per AWS contract.

func (*InMemoryBackend) TransferInputDevice

func (b *InMemoryBackend) TransferInputDevice(
	deviceID, targetCustomerID, targetRegion, message string,
) error

TransferInputDevice initiates a transfer of the device to another account.

func (*InMemoryBackend) UpdateAccountConfiguration

func (b *InMemoryBackend) UpdateAccountConfiguration(
	kmsKeyID string,
) (*AccountConfiguration, error)

UpdateAccountConfiguration updates the account-wide configuration.

func (*InMemoryBackend) UpdateChannel

func (b *InMemoryBackend) UpdateChannel(channelID, name, roleArn string) (*Channel, error)

UpdateChannel updates a channel's mutable fields.

func (*InMemoryBackend) UpdateChannelClass

func (b *InMemoryBackend) UpdateChannelClass(channelID, channelClass string) (*Channel, error)

UpdateChannelClass changes a channel's class.

func (*InMemoryBackend) UpdateChannelPlacementGroup

func (b *InMemoryBackend) UpdateChannelPlacementGroup(
	clusterID, groupID, name string,
	nodes []string,
) (*ChannelPlacementGroup, error)

UpdateChannelPlacementGroup updates a placement group's mutable fields.

func (*InMemoryBackend) UpdateCloudWatchAlarmTemplate

func (b *InMemoryBackend) UpdateCloudWatchAlarmTemplate(
	identifier string,
	name string,
	description string,
	groupIdentifier string,
	metricName string,
	namespace string,
	statistic string,
	comparisonOperator string,
	targetResourceType string,
	treatMissingData string,
	threshold float64,
	evaluationPeriods, datapointsToAlarm, period int32,
) (*CloudWatchAlarmTemplate, error)

UpdateCloudWatchAlarmTemplate updates a CW alarm template.

func (*InMemoryBackend) UpdateCloudWatchAlarmTemplateGroup

func (b *InMemoryBackend) UpdateCloudWatchAlarmTemplateGroup(
	identifier, name, description string,
) (*CloudWatchAlarmTemplateGroup, error)

UpdateCloudWatchAlarmTemplateGroup updates a CW alarm template group.

func (*InMemoryBackend) UpdateCluster

func (b *InMemoryBackend) UpdateCluster(clusterID, name string) (*Cluster, error)

UpdateCluster updates a Cluster's mutable fields.

func (*InMemoryBackend) UpdateEventBridgeRuleTemplate

func (b *InMemoryBackend) UpdateEventBridgeRuleTemplate(
	identifier, name, description, groupIdentifier, eventType string,
	eventTargets []EventBridgeRuleTemplateTarget,
) (*EventBridgeRuleTemplate, error)

UpdateEventBridgeRuleTemplate updates an EB rule template.

func (*InMemoryBackend) UpdateEventBridgeRuleTemplateGroup

func (b *InMemoryBackend) UpdateEventBridgeRuleTemplateGroup(
	identifier, name, description string,
) (*EventBridgeRuleTemplateGroup, error)

UpdateEventBridgeRuleTemplateGroup updates an EB rule template group.

func (*InMemoryBackend) UpdateInput

func (b *InMemoryBackend) UpdateInput(inputID, name, roleArn string) (*Input, error)

UpdateInput updates an input's mutable fields.

func (*InMemoryBackend) UpdateInputDevice

func (b *InMemoryBackend) UpdateInputDevice(deviceID, name string) (*InputDevice, error)

UpdateInputDevice updates the name of an input device.

func (*InMemoryBackend) UpdateInputSecurityGroup

func (b *InMemoryBackend) UpdateInputSecurityGroup(
	groupID string,
	whitelistRules []WhitelistRule,
) (*InputSecurityGroup, error)

UpdateInputSecurityGroup updates an input security group's whitelist rules.

func (*InMemoryBackend) UpdateMultiplex

func (b *InMemoryBackend) UpdateMultiplex(
	multiplexID, name string,
	settings MultiplexSettings,
) (*Multiplex, error)

UpdateMultiplex updates a Multiplex's mutable fields.

func (*InMemoryBackend) UpdateMultiplexProgram

func (b *InMemoryBackend) UpdateMultiplexProgram(
	multiplexID string,
	prog MultiplexProgramSettings,
) (*MultiplexProgram, error)

UpdateMultiplexProgram updates a program's settings.

func (*InMemoryBackend) UpdateNetwork

func (b *InMemoryBackend) UpdateNetwork(
	networkID, name string,
	ipPools []IPPool,
	routes []Route,
) (*Network, error)

UpdateNetwork updates a Network's mutable fields.

func (*InMemoryBackend) UpdateNode

func (b *InMemoryBackend) UpdateNode(clusterID, nodeID, name, role string) (*Node, error)

UpdateNode updates a Node's mutable fields.

func (*InMemoryBackend) UpdateNodeState

func (b *InMemoryBackend) UpdateNodeState(clusterID, nodeID, state string) (*Node, error)

UpdateNodeState updates the state of a Node.

func (*InMemoryBackend) UpdateReservation

func (b *InMemoryBackend) UpdateReservation(reservationID, name string) (*Reservation, error)

UpdateReservation updates a reservation's name.

func (*InMemoryBackend) UpdateSdiSource

func (b *InMemoryBackend) UpdateSdiSource(
	sdiSourceID, name, sdiType, mode string,
) (*SdiSource, error)

UpdateSdiSource updates an SDI source's mutable fields.

type Input

type Input struct {
	Tags      map[string]string
	ARN       string
	ID        string
	Name      string
	InputType string
	RoleARN   string
	State     string
}

Input represents a MediaLive input. Tags first: reduces GC pointer scan from 104 to 96 bytes.

type InputDevice

type InputDevice struct {
	Tags                    map[string]string
	ARN                     string
	ID                      string
	Name                    string
	SerialNumber            string
	MacAddress              string
	DeviceType              string
	ConnectionState         string
	DeviceSettingsSyncState string
	DeviceUpdateStatus      string
	MaintenanceWindowActive bool
}

InputDevice represents a MediaLive input device.

type InputDeviceTransfer

type InputDeviceTransfer struct {
	DeviceID         string
	TargetCustomerID string
	TransferType     string
	Message          string
}

InputDeviceTransfer represents a pending input device transfer.

type InputSecurityGroup

type InputSecurityGroup struct {
	Tags           map[string]string
	ARN            string
	ID             string
	State          string
	WhitelistRules []WhitelistRule
}

InputSecurityGroup represents a MediaLive input security group. Tags first, then strings, then slice: reduces GC pointer scan from 80 to 64 bytes.

type InputSecurityGroupSummary

type InputSecurityGroupSummary struct {
	ARN            string
	ID             string
	State          string
	WhitelistRules []WhitelistRule
}

InputSecurityGroupSummary is a security group in a list response.

type InputSummary

type InputSummary struct {
	ARN       string
	ID        string
	Name      string
	InputType string
	State     string
}

InputSummary is an input in a list response.

type Multiplex

type Multiplex struct {
	Tags              map[string]string
	ARN               string
	ID                string
	Name              string
	State             string
	AvailabilityZones []string
	Settings          MultiplexSettings
	ProgramCount      int
}

Multiplex represents a MediaLive Multiplex resource. Tags first, value struct last: reduces GC pointer scan.

type MultiplexProgram

type MultiplexProgram struct {
	ChannelID   string
	ProgramName string
	Settings    MultiplexProgramSettings
}

MultiplexProgram represents a program within a Multiplex. Strings first, value struct last: reduces GC pointer scan.

type MultiplexProgramSettings

type MultiplexProgramSettings struct {
	ServiceDescriptor        ServiceDescriptor
	ProgramName              string
	PreferredChannelPipeline string
	ProgramNumber            int
}

MultiplexProgramSettings holds the settings for a MultiplexProgram.

type MultiplexProgramSummary

type MultiplexProgramSummary struct {
	ProgramName string
	ChannelID   string
}

MultiplexProgramSummary is a program in a list response.

type MultiplexSettings

type MultiplexSettings struct {
	TransportStreamBitrate              int
	TransportStreamID                   int
	TransportStreamReservedBitrate      int
	MaximumVideoBufferDelayMilliseconds int
}

MultiplexSettings holds transport-stream parameters for a Multiplex.

type MultiplexSummary

type MultiplexSummary struct {
	ARN               string
	ID                string
	Name              string
	State             string
	AvailabilityZones []string
	ProgramCount      int
}

MultiplexSummary is a Multiplex in a list response.

type Network

type Network struct {
	Tags                 map[string]string
	ARN                  string
	ID                   string
	Name                 string
	State                string
	AssociatedClusterIDs []string
	IPPools              []IPPool
	Routes               []Route
}

Network represents a MediaLive Anywhere network resource.

type Node

type Node struct {
	Tags            map[string]string
	ARN             string
	ID              string
	Name            string
	ClusterID       string
	Role            string
	State           string
	ConnectionState string
}

Node represents a MediaLive Anywhere Node within a Cluster. Tags first: reduces GC pointer scan.

type NodeSummary

type NodeSummary struct {
	ARN             string
	ID              string
	Name            string
	ClusterID       string
	Role            string
	State           string
	ConnectionState string
}

NodeSummary is a Node in a list response.

type Offering

type Offering struct {
	ResourceSpecification OfferingResourceSpecification
	Arn                   string
	OfferingID            string
	OfferingDescription   string
	OfferingType          string
	CurrencyCode          string
	DurationUnits         string
	Region                string
	FixedPrice            float64
	UsagePrice            float64
	Duration              int32
}

Offering is a pre-defined reserved resource listing from the MediaLive catalog.

type OfferingResourceSpecification

type OfferingResourceSpecification struct {
	ResourceType     string `json:"resourceType"`
	VideoQuality     string `json:"videoQuality"`
	Resolution       string `json:"resolution"`
	SpecialFeature   string `json:"specialFeature"`
	MaximumBitrate   string `json:"maximumBitrate"`
	MaximumFramerate string `json:"maximumFramerate"`
	Codec            string `json:"codec"`
}

OfferingResourceSpecification describes the resource type for an offering.

type Provider

type Provider struct{}

Provider implements service.Provider for the MediaLive service.

func (*Provider) Init

Init initializes the MediaLive backend and handler.

func (*Provider) Name

func (p *Provider) Name() string

Name returns the logical name of the provider.

type Reservation

type Reservation struct {
	Tags                  map[string]string
	ResourceSpecification OfferingResourceSpecification
	CurrencyCode          string
	Start                 string
	Name                  string
	OfferingID            string
	OfferingDescription   string
	OfferingType          string
	Arn                   string
	ReservationID         string
	End                   string
	Region                string
	State                 string
	DurationUnits         string
	UsagePrice            float64
	FixedPrice            float64
	Duration              int32
	Count                 int32
}

Reservation is a purchased Offering.

type Route

type Route struct {
	Cidr    string `json:"cidr"`
	Gateway string `json:"gateway"`
}

Route is a static route for a Network.

type ScheduleAction

type ScheduleAction struct {
	ActionName string
	ActionType string
}

ScheduleAction represents a single schedule action for BatchUpdateSchedule.

type SdiSource

type SdiSource struct {
	ARN    string
	ID     string
	Name   string
	Type   string
	Mode   string
	State  string
	Inputs []string
}

SdiSource represents a MediaLive SDI source resource.

type ServiceDescriptor

type ServiceDescriptor struct {
	ProviderName string
	ServiceName  string
}

ServiceDescriptor holds provider/service name for a program.

type SignalMap

type SignalMap struct {
	CreatedAt                       time.Time
	ModifiedAt                      time.Time
	Tags                            map[string]string
	Arn                             string
	ID                              string
	Name                            string
	Description                     string
	DiscoveryEntryPointArn          string
	Status                          string
	MonitorDeploymentStatus         string
	CloudWatchAlarmTemplateGroupIDs []string
	EventBridgeRuleTemplateGroupIDs []string
}

SignalMap represents a MediaLive signal map resource.

type StorageBackend

type StorageBackend interface {
	// Channels
	CreateChannel(name, channelClass, roleArn string, tags map[string]string) (*Channel, error)
	DescribeChannel(channelID string) (*Channel, error)
	UpdateChannel(channelID, name, roleArn string) (*Channel, error)
	DeleteChannel(channelID string) (*Channel, error)
	ListChannels(maxResults int, nextToken string) ([]*ChannelSummary, string, error)
	StartChannel(channelID string) (*Channel, error)
	StopChannel(channelID string) (*Channel, error)

	// Inputs
	CreateInput(name, inputType, roleArn string, tags map[string]string) (*Input, error)
	DescribeInput(inputID string) (*Input, error)
	UpdateInput(inputID, name, roleArn string) (*Input, error)
	DeleteInput(inputID string) error
	ListInputs(maxResults int, nextToken string) ([]*InputSummary, string, error)

	// InputSecurityGroups
	CreateInputSecurityGroup(
		whitelistRules []WhitelistRule,
		tags map[string]string,
	) (*InputSecurityGroup, error)
	DescribeInputSecurityGroup(groupID string) (*InputSecurityGroup, error)
	UpdateInputSecurityGroup(
		groupID string,
		whitelistRules []WhitelistRule,
	) (*InputSecurityGroup, error)
	DeleteInputSecurityGroup(groupID string) error
	ListInputSecurityGroups(
		maxResults int,
		nextToken string,
	) ([]*InputSecurityGroupSummary, string, error)

	// Multiplexes
	CreateMultiplex(
		name string,
		availabilityZones []string,
		settings MultiplexSettings,
		tags map[string]string,
	) (*Multiplex, error)
	DescribeMultiplex(multiplexID string) (*Multiplex, error)
	UpdateMultiplex(multiplexID, name string, settings MultiplexSettings) (*Multiplex, error)
	DeleteMultiplex(multiplexID string) (*Multiplex, error)
	ListMultiplexes(maxResults int, nextToken string) ([]*MultiplexSummary, string, error)
	StartMultiplex(multiplexID string) (*Multiplex, error)
	StopMultiplex(multiplexID string) (*Multiplex, error)

	// MultiplexPrograms
	CreateMultiplexProgram(
		multiplexID string,
		prog MultiplexProgramSettings,
	) (*MultiplexProgram, error)
	DescribeMultiplexProgram(multiplexID, programName string) (*MultiplexProgram, error)
	UpdateMultiplexProgram(
		multiplexID string,
		prog MultiplexProgramSettings,
	) (*MultiplexProgram, error)
	DeleteMultiplexProgram(multiplexID, programName string) (*MultiplexProgram, error)
	ListMultiplexPrograms(
		multiplexID string,
		maxResults int,
		nextToken string,
	) ([]*MultiplexProgramSummary, string, error)

	// Tags
	CreateTags(resourceARN string, tags map[string]string) error
	DeleteTags(resourceARN string, tagKeys []string) error
	ListTagsForResource(resourceARN string) (map[string]string, error)

	// InputDevices
	ClaimDevice(id string) (*InputDevice, error)
	ListInputDevices(maxResults int, nextToken string) ([]*InputDevice, string, error)
	DescribeInputDevice(deviceID string) (*InputDevice, error)
	UpdateInputDevice(deviceID, name string) (*InputDevice, error)
	RebootInputDevice(deviceID string) error
	TransferInputDevice(deviceID, targetCustomerID, targetRegion, message string) error
	AcceptInputDeviceTransfer(deviceID string) error
	CancelInputDeviceTransfer(deviceID string) error
	RejectInputDeviceTransfer(deviceID string) error
	ListInputDeviceTransfers(
		transferType string,
		maxResults int,
		nextToken string,
	) ([]*InputDeviceTransfer, string, error)

	// Clusters
	CreateCluster(
		name, clusterType, instanceRoleArn string,
		tags map[string]string,
	) (*Cluster, error)
	DescribeCluster(clusterID string) (*Cluster, error)
	UpdateCluster(clusterID, name string) (*Cluster, error)
	DeleteCluster(clusterID string) (*Cluster, error)
	ListClusters(maxResults int, nextToken string) ([]*ClusterSummary, string, error)

	// Nodes
	CreateNode(clusterID, name, role string, tags map[string]string) (*Node, error)
	DescribeNode(clusterID, nodeID string) (*Node, error)
	UpdateNode(clusterID, nodeID, name, role string) (*Node, error)
	UpdateNodeState(clusterID, nodeID, state string) (*Node, error)
	DeleteNode(clusterID, nodeID string) (*Node, error)
	ListNodes(clusterID string, maxResults int, nextToken string) ([]*NodeSummary, string, error)
	CreateNodeRegistrationScript(clusterID string) (string, error)
	ListClusterAlerts(
		clusterID string,
		maxResults int,
		nextToken string,
	) ([]map[string]any, string, error)

	// SignalMaps
	CreateSignalMap(
		name, description, discoveryEntryPointArn string,
		cwGroupIDs, ebGroupIDs []string,
		tags map[string]string,
	) (*SignalMap, error)
	GetSignalMap(identifier string) (*SignalMap, error)
	ListSignalMaps(maxResults int, nextToken string) ([]*SignalMap, string, error)
	DeleteSignalMap(identifier string) error
	StartUpdateSignalMap(
		identifier, name, description string,
		cwGroupIDs, ebGroupIDs []string,
	) (*SignalMap, error)
	StartMonitorDeployment(identifier string) (*SignalMap, error)

	// CloudWatch Alarm Template Groups
	CreateCloudWatchAlarmTemplateGroup(
		name, description string,
		tags map[string]string,
	) (*CloudWatchAlarmTemplateGroup, error)
	GetCloudWatchAlarmTemplateGroup(identifier string) (*CloudWatchAlarmTemplateGroup, error)
	ListCloudWatchAlarmTemplateGroups(
		maxResults int,
		nextToken string,
	) ([]*CloudWatchAlarmTemplateGroup, string, error)
	UpdateCloudWatchAlarmTemplateGroup(
		identifier, name, description string,
	) (*CloudWatchAlarmTemplateGroup, error)
	DeleteCloudWatchAlarmTemplateGroup(identifier string) error

	// CloudWatch Alarm Templates
	CreateCloudWatchAlarmTemplate(
		name string,
		description string,
		groupIdentifier string,
		metricName string,
		namespace string,
		statistic string,
		comparisonOperator string,
		targetResourceType string,
		treatMissingData string,
		threshold float64,
		evaluationPeriods, datapointsToAlarm, period int32,
		tags map[string]string,
	) (*CloudWatchAlarmTemplate, error)
	GetCloudWatchAlarmTemplate(identifier string) (*CloudWatchAlarmTemplate, error)
	ListCloudWatchAlarmTemplates(
		maxResults int,
		nextToken string,
	) ([]*CloudWatchAlarmTemplate, string, error)
	UpdateCloudWatchAlarmTemplate(
		identifier string,
		name string,
		description string,
		groupIdentifier string,
		metricName string,
		namespace string,
		statistic string,
		comparisonOperator string,
		targetResourceType string,
		treatMissingData string,
		threshold float64,
		evaluationPeriods, datapointsToAlarm, period int32,
	) (*CloudWatchAlarmTemplate, error)
	DeleteCloudWatchAlarmTemplate(identifier string) error

	// EventBridge Rule Template Groups
	CreateEventBridgeRuleTemplateGroup(
		name, description string,
		tags map[string]string,
	) (*EventBridgeRuleTemplateGroup, error)
	GetEventBridgeRuleTemplateGroup(identifier string) (*EventBridgeRuleTemplateGroup, error)
	ListEventBridgeRuleTemplateGroups(
		maxResults int,
		nextToken string,
	) ([]*EventBridgeRuleTemplateGroup, string, error)
	UpdateEventBridgeRuleTemplateGroup(
		identifier, name, description string,
	) (*EventBridgeRuleTemplateGroup, error)
	DeleteEventBridgeRuleTemplateGroup(identifier string) error

	// EventBridge Rule Templates
	CreateEventBridgeRuleTemplate(
		name, description, groupIdentifier, eventType string,
		eventTargets []EventBridgeRuleTemplateTarget,
		tags map[string]string,
	) (*EventBridgeRuleTemplate, error)
	GetEventBridgeRuleTemplate(identifier string) (*EventBridgeRuleTemplate, error)
	ListEventBridgeRuleTemplates(
		maxResults int,
		nextToken string,
	) ([]*EventBridgeRuleTemplate, string, error)
	UpdateEventBridgeRuleTemplate(
		identifier, name, description, groupIdentifier, eventType string,
		eventTargets []EventBridgeRuleTemplateTarget,
	) (*EventBridgeRuleTemplate, error)
	DeleteEventBridgeRuleTemplate(identifier string) error

	// Offerings (read-only catalog)
	ListOfferings(maxResults int, nextToken string) ([]*Offering, string, error)
	DescribeOffering(offeringID string) (*Offering, error)

	// Reservations
	PurchaseOffering(
		offeringID, name string,
		count int32,
		tags map[string]string,
	) (*Reservation, error)
	ListReservations(maxResults int, nextToken string) ([]*Reservation, string, error)
	DescribeReservation(reservationID string) (*Reservation, error)
	DeleteReservation(reservationID string) (*Reservation, error)
	UpdateReservation(reservationID, name string) (*Reservation, error)

	// Batch ops
	// BatchStart/BatchStop take only channel and multiplex IDs -- the real
	// BatchStartInput/BatchStopInput shapes have NO inputIds field (verified
	// against aws-sdk-go-v2/service/medialive's api_op_BatchStart.go /
	// api_op_BatchStop.go; only ChannelIds+MultiplexIds).
	BatchStart(channelIDs, multiplexIDs []string) (*BatchResult, error)
	BatchStop(channelIDs, multiplexIDs []string) (*BatchResult, error)
	// BatchDelete takes channel, input, multiplex, AND input-security-group
	// IDs -- BatchDeleteInput is the one Batch* shape with all four fields.
	BatchDelete(channelIDs, inputIDs, multiplexIDs, inputSecurityGroupIDs []string) (*BatchResult, error)
	BatchUpdateSchedule(
		channelID string,
		creates []ScheduleAction,
		deleteActionNames []string,
	) (*BatchUpdateScheduleResult, error)

	// Networks
	CreateNetwork(
		name string,
		ipPools []IPPool,
		routes []Route,
		tags map[string]string,
	) (*Network, error)
	DescribeNetwork(networkID string) (*Network, error)
	UpdateNetwork(networkID, name string, ipPools []IPPool, routes []Route) (*Network, error)
	DeleteNetwork(networkID string) (*Network, error)
	ListNetworks(maxResults int, nextToken string) ([]*Network, string, error)

	// SdiSources
	CreateSdiSource(name, sdiType, mode string, tags map[string]string) (*SdiSource, error)
	DescribeSdiSource(sdiSourceID string) (*SdiSource, error)
	UpdateSdiSource(sdiSourceID, name, sdiType, mode string) (*SdiSource, error)
	DeleteSdiSource(sdiSourceID string) (*SdiSource, error)
	ListSdiSources(maxResults int, nextToken string) ([]*SdiSource, string, error)

	// ChannelPlacementGroups (nested under a cluster)
	CreateChannelPlacementGroup(
		clusterID, name string,
		nodes []string,
		tags map[string]string,
	) (*ChannelPlacementGroup, error)
	DescribeChannelPlacementGroup(clusterID, groupID string) (*ChannelPlacementGroup, error)
	UpdateChannelPlacementGroup(
		clusterID, groupID, name string,
		nodes []string,
	) (*ChannelPlacementGroup, error)
	DeleteChannelPlacementGroup(clusterID, groupID string) (*ChannelPlacementGroup, error)
	ListChannelPlacementGroups(
		clusterID string,
		maxResults int,
		nextToken string,
	) ([]*ChannelPlacementGroup, string, error)

	// Account configuration
	DescribeAccountConfiguration() (*AccountConfiguration, error)
	UpdateAccountConfiguration(kmsKeyID string) (*AccountConfiguration, error)

	// Schedule
	DescribeSchedule(channelID string) ([]ScheduleAction, error)
	DeleteSchedule(channelID string) error

	// Alerts and versions
	ListAlerts(channelID string) ([]map[string]any, error)
	ListMultiplexAlerts(multiplexID string) ([]map[string]any, error)
	ListVersions() []ChannelEngineVersion

	// Channel lifecycle extras
	UpdateChannelClass(channelID, channelClass string) (*Channel, error)
	RestartChannelPipelines(channelID string, pipelineIDs []string) (*Channel, error)
	DescribeThumbnails(channelID string) (*Channel, error)

	// InputDevice lifecycle extras
	StartInputDevice(deviceID string) error
	StopInputDevice(deviceID string) error
	StartInputDeviceMaintenanceWindow(deviceID string) error
	DescribeInputDeviceThumbnail(deviceID string) (*InputDevice, error)

	// SignalMap monitor deployment teardown
	StartDeleteMonitorDeployment(identifier string) (*SignalMap, error)

	// Partner inputs
	CreatePartnerInput(inputID string, tags map[string]string) (*Input, error)

	AccountID() string
	Region() string
	Reset()
	Snapshot(ctx context.Context) []byte
	Restore(ctx context.Context, data []byte) error
}

StorageBackend is the interface for MediaLive storage operations.

type WhitelistRule

type WhitelistRule struct {
	Cidr string `json:"cidr"`
}

WhitelistRule is a CIDR-based whitelist entry.

Jump to

Keyboard shortcuts

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