controller

package
v0.0.0-...-950e6cb Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2024 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetNameByNameSpace

func GetNameByNameSpace(ns string) string

Types

type LicenseActivator

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

func (*LicenseActivator) Active

func (l *LicenseActivator) Active(license *licensev1.License) error

func (*LicenseActivator) Recharge

func (l *LicenseActivator) Recharge(license *licensev1.License) error

type LicenseReconciler

type LicenseReconciler struct {
	client.Client
	Scheme *runtime.Scheme
	Logger logr.Logger

	ClusterID string
	// contains filtered or unexported fields
}

LicenseReconciler reconciles a License object

func (*LicenseReconciler) Reconcile

func (r *LicenseReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

func (*LicenseReconciler) SetupWithManager

func (r *LicenseReconciler) SetupWithManager(mgr ctrl.Manager, db *database.DataBase, accountDB database2.AccountV2) error

SetupWithManager sets up the controller with the Manager.

type LicenseRecorder

type LicenseRecorder struct {
	// maybe you need more or less information to record license, add/delete if you need
	client.Client
	// contains filtered or unexported fields
}

func (*LicenseRecorder) Find

func (r *LicenseRecorder) Find(ctx context.Context, license *v1.License) (bool, error)

func (*LicenseRecorder) Get

func (r *LicenseRecorder) Get(ctx context.Context, license *v1.License) (*meta.Meta, error)

func (*LicenseRecorder) IsExisted

func (r *LicenseRecorder) IsExisted(ctx context.Context, license *v1.License) (bool, error)

func (*LicenseRecorder) Store

func (r *LicenseRecorder) Store(ctx context.Context, license *v1.License) error

type LicenseValidator

type LicenseValidator struct {
	client.Client
	ClusterID string
}

func (*LicenseValidator) Validate

func (v *LicenseValidator) Validate(license *licensev1.License) (bool, error)

Jump to

Keyboard shortcuts

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