messagebuscontracts

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Workqueue_Slack_Message_Create = "ror.slack.message.create"
	Workqueue_Switchboard_Post     = "ror.switchboard.post"

	Route_Acl_Update      = "acl.update"
	Route_Auth            = "auth"
	Route_Cluster_Created = "cluster.created"

	Route_ResourceCreated = "resource.created"
	Route_ResourceUpdated = "resource.updated"
	Route_ResourceDeleted = "resource.deleted"

	Route_ProviderTanzuClusterCreate = "provider.tanzu.cluster.create"
	Route_ProviderTanzuClusterModify = "provider.tanzu.cluster.modify"
	Route_ProviderTanzuClusterDelete = "provider.tanzu.cluster.delete"
	Route_ProviderTanzuOperatorOrder = "provider.tanzu.operator.order"

	Event_Broadcast           = "event.broadcast"
	Event_ClusterCreated      = "event.cluster.created"
	Event_ClusterOrderUpdated = "event.clusterorder.updated"

	ExchangeRor          = "ror"
	ExchangeRorResources = "ror.resources"
	ExchangeRorEvents    = "ror.events"
	ExchangeTanzu        = "tanzu"
	ExchangeKind         = "kind"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AclUpdateEvent

type AclUpdateEvent struct {
	EventBase
	Action string `json:"action"`
}

type ClusterCreate

type ClusterCreate struct {
	ClusterInput tanzu.TanzuKubernetesClusterInput `json:"clusterInput"`
}

type ClusterCreatedEvent

type ClusterCreatedEvent struct {
	EventBase
	EventClusterBase
	ClusterName   string `json:"clusterName"`
	WorkspaceName string `json:"workspaceName"`
}

type ClusterDelete

type ClusterDelete struct {
	ClusterInput tanzu.TanzuKubernetesClusterInput `json:"clusterInput"`
}

type ClusterModify

type ClusterModify struct {
	ClusterInput tanzu.TanzuKubernetesClusterInput `json:"clusterInput"`
}

type ClusterUpdatedEvent

type ClusterUpdatedEvent struct {
	EventBase
	EventClusterBase
}

type EventBase

type EventBase struct {
	TraceId string `json:"traceId"`
}

type EventClusterBase

type EventClusterBase struct {
	ClusterId string `json:"clusterId"`
}

type OperatorOrder

type OperatorOrder struct {
	TanzuKubernetesCluster apiresourcecontracts.ResourceTanzuKubernetesCluster `json:"tanzuKubernetesCluster"`
}

type ResourceUpdatedEvent

type ResourceUpdatedEvent struct {
	ResourceNamespace apiresourcecontracts.ResourceModel[apiresourcecontracts.ResourceNamespace] `json:"resourceNamespace"`
}

type SlackMessageCreate

type SlackMessageCreate struct {
	EventBase
	Message   string `json:"message"`
	ChannelId string `json:"channelId"`
}

type SwitchboardPost

type SwitchboardPost struct {
	Source SwitchboardSource `json:"source"`

	Severity SwitchboardPostSeverity  `json:"severity"`
	Event    messages.RulesetRuleType `json:"event"`

	Attributes map[string]string `json:"attributes"`
}

type SwitchboardPostSeverity

type SwitchboardPostSeverity string
const (
	SwitchboardPostSeverityFatal SwitchboardPostSeverity = "fatal"
	SwitchboardPostSeverityError SwitchboardPostSeverity = "error"
	SwitchboardPostSeverityWarn  SwitchboardPostSeverity = "warn"
	SwitchboardPostSeverityInfo  SwitchboardPostSeverity = "info"
)

type SwitchboardSource

type SwitchboardSource struct {
	Type SwitchboardSourceType `json:"type"`

	// name-hash. You will only find this one when source type is cluster. Since there is no need to identify ROR. For sanity's sake. It should be ror by default
	ClusterId string `json:"clusterId,omitempty"`

	// Uid of the resource we are looking up
	Uid string `json:"uid"`

	// ApiVersion of the resource we are looking up
	ApiVersion string `json:"apiVersion"`

	// Kind the kind of resource we are looking up
	Kind string `json:"kind"`

	// Namespace the namespace in which the resource lives
	Namespace string `json:"namespace"`
}

type SwitchboardSourceType

type SwitchboardSourceType int
const (
	SwitchboardSourceTypeCluster SwitchboardSourceType = iota
	SwitchboardSourceTypeRor
)

type SwitchboardSubject

type SwitchboardSubject struct {
	Resource string `json:"resource"`
	Event    string `json:"event"`
}

Jump to

Keyboard shortcuts

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