Documentation ¶
Index ¶
- Constants
- Variables
- func GetMsgKey(c client.Object) string
- type K8sItem
- type KlMetadata
- type MessageReply
- type Notifier
- func (n *Notifier) Notify(ctx context.Context, key string, statusUpdate types.ResourceUpdate) error
- func (n *Notifier) Notify2(ctx context.Context, key string, metadata KlMetadata, status rApi.Status, ...) error
- func (n *Notifier) NotifyBilling(ctx context.Context, key string, metadata KlMetadata, billing *ResourceBilling, ...) error
- type Plan
- type ResourceBilling
- type WrappedName
Constants ¶
View Source
const ( Compute k8sResource = "Compute" BlockStorage k8sResource = "BlockStorage" ObjectStorage k8sResource = "ObjectStorage" Lambda k8sResource = "Lambda" Ci k8sResource = "Ci" )
Variables ¶
View Source
var Stages = struct {
Exists stageTT `json:"exists"`
Deleted stageTT `json:"deleted"`
}{
Exists: "EXISTS",
Deleted: "DELETED",
}
Functions ¶
Types ¶
type K8sItem ¶
type KlMetadata ¶
type KlMetadata struct { ClusterId string `json:"clusterId"` AccountId string `json:"accountId"` ProjectId string `json:"projectId"` ResourceId string `json:"resourceId"` GroupVersionKind schema.GroupVersionKind `json:"groupVersionKind"` Labels map[string]string `json:"labels"` EnvironmentId string `json:"environmentId"` }
func ExtractMetadata ¶
func ExtractMetadata(obj client.Object) KlMetadata
type MessageReply ¶
type MessageReply struct { // ChildConditions []metav1.Condition `json:"childConditions,omitempty"` // Conditions []metav1.Condition `json:"conditions,omitempty"` IsReady bool `json:"isReady"` // ToBeDeleted bool `json:"toBeDeleted,omitempty"` Key string `json:"key"` Billing *ResourceBilling `json:"billing-watcher,omitempty"` Metadata KlMetadata `json:"metadata,omitempty"` Stage stageTT `json:"stage"` }
type Notifier ¶
type Notifier struct {
// contains filtered or unexported fields
}
func NewNotifier ¶
func (*Notifier) NotifyBilling ¶
func (n *Notifier) NotifyBilling(ctx context.Context, key string, metadata KlMetadata, billing *ResourceBilling, stage stageTT) error
type ResourceBilling ¶
type WrappedName ¶
func (WrappedName) ParseGroup ¶
func (w WrappedName) ParseGroup() (*schema.GroupVersionKind, error)
func (WrappedName) String ¶
func (w WrappedName) String() (string, error)
Click to show internal directories.
Click to hide internal directories.