Documentation ¶
Index ¶
- type CreateFn
- type Reconciler
- func (r *Reconciler) DeleteSubscription(ctx context.Context, id string, obj runtime.Object, updater StatusUpdater) error
- func (r *Reconciler) DeleteTopic(ctx context.Context, id string, obj runtime.Object, updater StatusUpdater) error
- func (r *Reconciler) ReconcileSubscription(ctx context.Context, id string, subConfig pubsub.SubscriptionConfig, ...) (*pubsub.Subscription, error)
- func (r *Reconciler) ReconcileTopic(ctx context.Context, id string, topicConfig *pubsub.TopicConfig, ...) (*pubsub.Topic, error)
- type StatusUpdater
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateFn ¶ added in v0.19.0
type CreateFn func(ctx context.Context, projectID string, opts ...option.ClientOption) (*pubsub.Client, error)
CreateFn is a factory function to create a Pub/Sub client. It is copied from gclient/pubsub to avoid unnecessary dependency on gpubsub.
type Reconciler ¶
type Reconciler struct {
// contains filtered or unexported fields
}
func NewReconciler ¶
func NewReconciler(client *pubsub.Client, recorder record.EventRecorder) *Reconciler
func (*Reconciler) DeleteSubscription ¶
func (r *Reconciler) DeleteSubscription(ctx context.Context, id string, obj runtime.Object, updater StatusUpdater) error
func (*Reconciler) DeleteTopic ¶
func (r *Reconciler) DeleteTopic(ctx context.Context, id string, obj runtime.Object, updater StatusUpdater) error
func (*Reconciler) ReconcileSubscription ¶
func (r *Reconciler) ReconcileSubscription(ctx context.Context, id string, subConfig pubsub.SubscriptionConfig, obj runtime.Object, updater StatusUpdater) (*pubsub.Subscription, error)
func (*Reconciler) ReconcileTopic ¶
func (r *Reconciler) ReconcileTopic(ctx context.Context, id string, topicConfig *pubsub.TopicConfig, obj runtime.Object, updater StatusUpdater) (*pubsub.Topic, error)
type StatusUpdater ¶
type StatusUpdater interface { MarkTopicFailed(reason, format string, args ...interface{}) MarkTopicUnknown(reason, format string, args ...interface{}) MarkTopicReady() MarkSubscriptionFailed(reason, format string, args ...interface{}) MarkSubscriptionUnknown(reason, format string, args ...interface{}) MarkSubscriptionReady() }
StatusUpdater is an interface which updates resource status based on pubsub reconciliation results.
Click to show internal directories.
Click to hide internal directories.