contractmanager

package
v0.1.0-rc.2 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package contractmanager implements the utility functions for the contract manager controller

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Purchase

type Purchase struct {
	TransactionID string `json:"transactionID"`
	FlavorID      string `json:"flavorID"`
	BuyerID       string `json:"buyerID"`
}

Purchase contains information regarding the purchase for a flavor.

type ReservationReconciler

type ReservationReconciler struct {
	client.Client
	Scheme  *runtime.Scheme
	Gateway *gateway.Gateway
}

ReservationReconciler reconciles a Reservation object.

func (*ReservationReconciler) Reconcile

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

Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state.

For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.11.2/pkg/reconcile

func (*ReservationReconciler) SetupWithManager

func (r *ReservationReconciler) SetupWithManager(mgr ctrl.Manager) error

SetupWithManager sets up the controller with the Manager.

type Selector

type Selector struct {
	FlavourType      string `json:"type,omitempty"`
	CPU              int    `json:"cpu,omitempty"`
	RAM              int    `json:"ram,omitempty"`
	EphemeralStorage int    `json:"ephemeral-storage,omitempty"`
}

Selector represents the criteria for selecting Flavours.

type Transaction

type Transaction struct {
	TransactionID  string    `json:"transactionID"`
	FlavorID       string    `json:"flavorID"`
	ExpirationTime time.Time `json:"startTime,omitempty"`
}

Transaction contains information regarding the transaction for a flavor.

Jump to

Keyboard shortcuts

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