read_write_layer

package
v0.104.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetContext

func GetContext(ctx context.Context, c client.Reader, key client.ObjectKey, lsContext *lsv1alpha1.Context, readID ReadID) error

read methods for context

func GetDeployItem

func GetDeployItem(ctx context.Context, c client.Reader, key client.ObjectKey, deployItem *lsv1alpha1.DeployItem, readID ReadID) error

read methods for deploy items

func GetExecution

func GetExecution(ctx context.Context, c client.Reader, key client.ObjectKey, execution *lsv1alpha1.Execution, readID ReadID) error

read methods for executions

func GetHealthCheck

func GetHealthCheck(ctx context.Context, c client.Reader, key client.ObjectKey, health *lsv1alpha1.LsHealthCheck, readID ReadID) error

func GetInstallation

func GetInstallation(ctx context.Context, c client.Reader, key client.ObjectKey, installation *lsv1alpha1.Installation, readID ReadID) error

read methods for installations

func GetMetaData

func GetMetaData(ctx context.Context, c client.Reader, key client.ObjectKey, metadata *v12.PartialObjectMetadata, readID ReadID) error

read methods for metadata

func GetObject

func GetObject(ctx context.Context, c client.Reader, key client.ObjectKey, object client.Object, readID ReadID) error

read methods for object

func GetPod

func GetPod(ctx context.Context, c client.Reader, key client.ObjectKey, pod *v1.Pod, readID ReadID) error

read methods for pods

func GetSecret

func GetSecret(ctx context.Context, c client.Reader, key client.ObjectKey, secret *v1.Secret, readID ReadID) error

func GetSyncObject

func GetSyncObject(ctx context.Context, c client.Reader, key client.ObjectKey, syncObject *lsv1alpha1.SyncObject, readID ReadID) error

read methods for sync objects

func GetTarget

func GetTarget(ctx context.Context, c client.Reader, key client.ObjectKey, target *lsv1alpha1.Target, readID ReadID) error

func GetUnstructured

func GetUnstructured(ctx context.Context, c client.Reader, key client.ObjectKey, unstruc *unstructured.Unstructured, readID ReadID) error

read methods for unstructured

func ListDataObjects

func ListDataObjects(ctx context.Context, c client.Reader, dataObjects *lsv1alpha1.DataObjectList, readID ReadID, opts ...client.ListOption) error

func ListDeployItems

func ListDeployItems(ctx context.Context, c client.Reader, deployItems *lsv1alpha1.DeployItemList, readID ReadID, opts ...client.ListOption) error

func ListExecutions

func ListExecutions(ctx context.Context, c client.Reader, executions *lsv1alpha1.ExecutionList, readID ReadID, opts ...client.ListOption) error

func ListHealthChecks

func ListHealthChecks(ctx context.Context, c client.Reader, healthChecks *lsv1alpha1.LsHealthCheckList, readID ReadID, opts ...client.ListOption) error

func ListInstallations

func ListInstallations(ctx context.Context, c client.Reader, installations *lsv1alpha1.InstallationList, readID ReadID, opts ...client.ListOption) error

func ListManagedDeployItems

func ListManagedDeployItems(ctx context.Context, c client.Reader, execKey client.ObjectKey, readID ReadID) (*lsv1alpha1.DeployItemList, error)

func ListMetaData

func ListMetaData(ctx context.Context, c client.Reader, metadataList *v12.PartialObjectMetadataList, readID ReadID, opts ...client.ListOption) error

func ListNamespaces

func ListNamespaces(ctx context.Context, c client.Reader, namespaces *v1.NamespaceList, readID ReadID, opts ...client.ListOption) error

read methods for namespaces

func ListPods

func ListPods(ctx context.Context, c client.Reader, pods *v1.PodList, readID ReadID, opts ...client.ListOption) error

func ListSecrets

func ListSecrets(ctx context.Context, c client.Reader, secrets *v1.SecretList, readID ReadID, opts ...client.ListOption) error

func ListSyncObjects

func ListSyncObjects(ctx context.Context, c client.Reader, syncObjects *lsv1alpha1.SyncObjectList, readID ReadID, opts ...client.ListOption) error

func ListTargetSyncs

func ListTargetSyncs(ctx context.Context, c client.Reader, targetSyncs *lsv1alpha1.TargetSyncList, readID ReadID, opts ...client.ListOption) error

func ListTargets

func ListTargets(ctx context.Context, c client.Reader, targets *lsv1alpha1.TargetList, readID ReadID, opts ...client.ListOption) error

func ListUnstructured

func ListUnstructured(ctx context.Context, c client.Reader, unstrucs *unstructured.UnstructuredList, readID ReadID, opts ...client.ListOption) error

Types

type ReadID

type ReadID string
const (
	// Constants to identify different read operations. Every constant must be used only once.
	R000000 ReadID = "r000000" // for tests
	R000001 ReadID = "r000001"
	R000002 ReadID = "r000002"
	R000003 ReadID = "r000003"
	R000004 ReadID = "r000004"
	R000005 ReadID = "r000005"
	R000006 ReadID = "r000006"
	R000007 ReadID = "r000007"
	R000008 ReadID = "r000008"
	R000009 ReadID = "r000009"
	R000010 ReadID = "r000010"
	R000011 ReadID = "r000011"
	R000012 ReadID = "r000012"
	R000013 ReadID = "r000013"
	R000014 ReadID = "r000014"
	R000015 ReadID = "r000015"
	R000016 ReadID = "r000016"
	R000017 ReadID = "r000017"
	R000018 ReadID = "r000018"
	R000019 ReadID = "r000019"
	R000020 ReadID = "r000020"
	R000021 ReadID = "r000021"
	R000022 ReadID = "r000022"
	R000023 ReadID = "r000023"
	R000024 ReadID = "r000024"
	R000025 ReadID = "r000025"
	R000026 ReadID = "r000026"
	R000027 ReadID = "r000027"
	R000028 ReadID = "r000028"
	R000029 ReadID = "r000029"
	R000030 ReadID = "r000030"
	R000031 ReadID = "r000031"
	R000032 ReadID = "r000032"
	R000033 ReadID = "r000033"
	R000034 ReadID = "r000034"
	R000035 ReadID = "r000035"
	R000036 ReadID = "r000036"
	R000037 ReadID = "r000037"
	R000038 ReadID = "r000038"
	R000039 ReadID = "r000039"
	R000040 ReadID = "r000040"
	R000041 ReadID = "r000041"
	R000042 ReadID = "r000042"
	R000043 ReadID = "r000043"
	R000044 ReadID = "r000044"
	R000045 ReadID = "r000045"
	R000046 ReadID = "r000046"
	R000047 ReadID = "r000047"
	R000048 ReadID = "r000048"
	R000049 ReadID = "r000049"
	R000050 ReadID = "r000050"
	R000051 ReadID = "r000051"
	R000052 ReadID = "r000052"
	R000053 ReadID = "r000053"
	R000054 ReadID = "r000054"
	R000055 ReadID = "r000055"
	R000056 ReadID = "r000056"
	R000057 ReadID = "r000057"
	R000058 ReadID = "r000058"
	R000059 ReadID = "r000059"
	R000060 ReadID = "r000060"
	R000061 ReadID = "r000061"
	R000062 ReadID = "r000062"
	R000063 ReadID = "r000063"
	R000064 ReadID = "r000064"
	R000065 ReadID = "r000065"
	R000066 ReadID = "r000066"
	R000067 ReadID = "r000067"
	R000068 ReadID = "r000068"
	R000069 ReadID = "r000069"
	R000070 ReadID = "r000070"
	R000071 ReadID = "r000071"
	R000072 ReadID = "r000072"
	R000073 ReadID = "r000073"
	R000074 ReadID = "r000074"
	R000075 ReadID = "r000075"
	R000076 ReadID = "r000076"
	R000077 ReadID = "r000077"
	R000078 ReadID = "r000078"
	R000079 ReadID = "r000079"
	R000080 ReadID = "r000080"
	R000081 ReadID = "r000081"
	R000082 ReadID = "r000082"
	R000083 ReadID = "r000083"
	R000084 ReadID = "r000084"
	R000085 ReadID = "r000085"
	R000086 ReadID = "r000086"
	R000087 ReadID = "r000087"
	R000088 ReadID = "r000088"
	R000089 ReadID = "r000089"
	R000090 ReadID = "r000090"
	R000091 ReadID = "r000091"
	R000092 ReadID = "r000092"
	R000093 ReadID = "r000093"
	R000094 ReadID = "r000094"
	R000095 ReadID = "r000095"
	R000096 ReadID = "r000096"
	R000097 ReadID = "r000097"
	R000098 ReadID = "r000098"
	R000099 ReadID = "r000099"
	R000100 ReadID = "r000100"
	R000101 ReadID = "r000101"
	R000102 ReadID = "r000102"
	R000103 ReadID = "r000103"
	R000104 ReadID = "r000104"
	R000105 ReadID = "r000105"
	R000106 ReadID = "r000106"
	R000107 ReadID = "r000107"
	R000108 ReadID = "r000108"
	R000109 ReadID = "r000109"
	R000110 ReadID = "r000110"
)

type WriteID

type WriteID string
const (
	// Constants to identify different write operations. Every constant must be used only once.
	W000001 WriteID = "w000001"
	W000002 WriteID = "w000002"
	W000003 WriteID = "w000003"
	W000004 WriteID = "w000004"
	W000005 WriteID = "w000005"
	W000006 WriteID = "w000006"
	W000007 WriteID = "w000007"
	W000008 WriteID = "w000008"
	W000009 WriteID = "w000009"
	W000010 WriteID = "w000010"
	W000011 WriteID = "w000011"
	W000012 WriteID = "w000012"
	W000013 WriteID = "w000013"
	W000014 WriteID = "w000014"
	W000015 WriteID = "w000015"
	W000016 WriteID = "w000016"
	W000017 WriteID = "w000017"
	W000018 WriteID = "w000018"
	W000019 WriteID = "w000019"
	W000020 WriteID = "w000020"
	W000021 WriteID = "w000021"
	W000022 WriteID = "w000022"
	W000023 WriteID = "w000023"
	W000024 WriteID = "w000024"
	W000025 WriteID = "w000025"
	W000026 WriteID = "w000026"
	W000027 WriteID = "w000027"
	W000028 WriteID = "w000028"
	W000029 WriteID = "w000029"
	W000030 WriteID = "w000030"
	W000031 WriteID = "w000031"
	W000032 WriteID = "w000032"
	W000033 WriteID = "w000033"
	W000034 WriteID = "w000034"
	W000035 WriteID = "w000035"
	W000036 WriteID = "w000036"
	W000037 WriteID = "w000037"
	W000038 WriteID = "w000038"
	W000039 WriteID = "w000039"
	W000040 WriteID = "w000040"
	W000041 WriteID = "w000041"
	W000042 WriteID = "w000042"
	W000043 WriteID = "w000043"
	W000044 WriteID = "w000044"
	W000045 WriteID = "w000045"
	W000046 WriteID = "w000046"
	W000047 WriteID = "w000047"
	W000048 WriteID = "w000048"
	W000049 WriteID = "w000049"
	W000050 WriteID = "w000050"
	W000051 WriteID = "w000051"
	W000052 WriteID = "w000052"
	W000053 WriteID = "w000053"
	W000054 WriteID = "w000054"
	W000055 WriteID = "w000055"
	W000056 WriteID = "w000056"
	W000057 WriteID = "w000057"
	W000058 WriteID = "w000058"
	W000059 WriteID = "w000059"
	W000060 WriteID = "w000060"
	W000061 WriteID = "w000061"
	W000062 WriteID = "w000062"
	W000063 WriteID = "w000063"
	W000064 WriteID = "w000064"
	W000065 WriteID = "w000065"
	W000066 WriteID = "w000066"
	W000067 WriteID = "w000067"
	W000068 WriteID = "w000068"
	W000069 WriteID = "w000069"
	W000070 WriteID = "w000070"
	W000071 WriteID = "w000071"
	W000072 WriteID = "w000072"
	W000073 WriteID = "w000073"
	W000074 WriteID = "w000074"
	W000075 WriteID = "w000075"
	W000076 WriteID = "w000076"
	W000077 WriteID = "w000077"
	W000078 WriteID = "w000078"
	W000079 WriteID = "w000079"
	W000080 WriteID = "w000080"
	W000081 WriteID = "w000081"
	W000082 WriteID = "w000082"
	W000083 WriteID = "w000083"
	W000084 WriteID = "w000084"
	W000085 WriteID = "w000085"
	W000086 WriteID = "w000086"
	W000087 WriteID = "w000087"
	W000088 WriteID = "w000088"
	W000089 WriteID = "w000089"
	W000090 WriteID = "w000090"
	W000091 WriteID = "w000091"
	W000092 WriteID = "w000092"
	W000093 WriteID = "w000093"
	W000094 WriteID = "w000094"
	W000095 WriteID = "w000095"
	W000096 WriteID = "w000096"
	W000097 WriteID = "w000097"
	W000098 WriteID = "w000098"
	W000099 WriteID = "w000099"
	W000100 WriteID = "w000100"
	W000101 WriteID = "w000101"
	W000102 WriteID = "w000102"
	W000103 WriteID = "w000103"
	W000104 WriteID = "w000104"
	W000105 WriteID = "w000105"
	W000106 WriteID = "w000106"
	W000107 WriteID = "w000107"
	W000108 WriteID = "w000108"
	W000109 WriteID = "w000109"
	W000110 WriteID = "w000110"
	W000111 WriteID = "w000111"
	W000112 WriteID = "w000112"
	W000113 WriteID = "w000113"
	W000114 WriteID = "w000114"
	W000115 WriteID = "w000115"
	W000116 WriteID = "w000116"
	W000117 WriteID = "w000117"
	W000118 WriteID = "w000118"
	W000119 WriteID = "w000119"
	W000120 WriteID = "w000120"
	W000121 WriteID = "w000121"
	W000122 WriteID = "w000122"
	W000123 WriteID = "w000123"
	W000124 WriteID = "w000124"
	W000125 WriteID = "w000125"
	W000126 WriteID = "w000126"
	W000127 WriteID = "w000127"
	W000128 WriteID = "w000128"
	W000129 WriteID = "w000129"
	W000130 WriteID = "w000130"
	W000131 WriteID = "w000131"
	W000132 WriteID = "w000132"
	W000133 WriteID = "w000133"
	W000134 WriteID = "w000134"
	W000135 WriteID = "w000135"
	W000136 WriteID = "w000136"
	W000137 WriteID = "w000137"
	W000138 WriteID = "w000138"
	W000139 WriteID = "w000139"
	W000140 WriteID = "w000140"
	W000141 WriteID = "w000141"
	W000142 WriteID = "w000142"
	W000143 WriteID = "w000143"
	W000144 WriteID = "w000144"
	W000145 WriteID = "w000145"
	W000146 WriteID = "w000146"
	W000147 WriteID = "w000147"
	W000148 WriteID = "w000148"
	W000149 WriteID = "w000149"
)

type Writer

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

func NewWriter

func NewWriter(c client.Client) *Writer

func (*Writer) CreateOrPatchCoreContext

func (w *Writer) CreateOrPatchCoreContext(ctx context.Context, writeID WriteID, lsContext *lsv1alpha1.Context,
	f controllerutil.MutateFn) (controllerutil.OperationResult, error)

func (*Writer) CreateOrUpdateCoreDataObject

func (w *Writer) CreateOrUpdateCoreDataObject(ctx context.Context, writeID WriteID, do *lsv1alpha1.DataObject,
	f controllerutil.MutateFn) (controllerutil.OperationResult, error)

func (*Writer) CreateOrUpdateCoreInstallation

func (w *Writer) CreateOrUpdateCoreInstallation(ctx context.Context, writeID WriteID, installation *lsv1alpha1.Installation,
	f controllerutil.MutateFn) (controllerutil.OperationResult, error)

func (*Writer) CreateOrUpdateCoreTarget

func (w *Writer) CreateOrUpdateCoreTarget(ctx context.Context, writeID WriteID, target *lsv1alpha1.Target,
	f controllerutil.MutateFn) (controllerutil.OperationResult, error)

func (*Writer) CreateOrUpdateDataObject

func (w *Writer) CreateOrUpdateDataObject(ctx context.Context, writeID WriteID, do *lsv1alpha1.DataObject,
	f controllerutil.MutateFn) (controllerutil.OperationResult, error)

func (*Writer) CreateOrUpdateDeployItem

func (w *Writer) CreateOrUpdateDeployItem(ctx context.Context, writeID WriteID, deployItem *lsv1alpha1.DeployItem,
	f controllerutil.MutateFn) (controllerutil.OperationResult, error)

func (*Writer) CreateOrUpdateExecution

func (w *Writer) CreateOrUpdateExecution(ctx context.Context, writeID WriteID, execution *lsv1alpha1.Execution,
	f controllerutil.MutateFn) (controllerutil.OperationResult, error)

func (*Writer) CreateOrUpdateInstallation

func (w *Writer) CreateOrUpdateInstallation(ctx context.Context, writeID WriteID, installation *lsv1alpha1.Installation,
	f controllerutil.MutateFn) (controllerutil.OperationResult, error)

func (*Writer) CreateSyncObject

func (w *Writer) CreateSyncObject(ctx context.Context, writeID WriteID, syncObject *lsv1alpha1.SyncObject) error

func (*Writer) DeleteDataObject

func (w *Writer) DeleteDataObject(ctx context.Context, writeID WriteID, do *lsv1alpha1.DataObject) error

func (*Writer) DeleteDeployItem

func (w *Writer) DeleteDeployItem(ctx context.Context, writeID WriteID, deployItem *lsv1alpha1.DeployItem) error

func (*Writer) DeleteExecution

func (w *Writer) DeleteExecution(ctx context.Context, writeID WriteID, execution *lsv1alpha1.Execution) error

func (*Writer) DeleteInstallation

func (w *Writer) DeleteInstallation(ctx context.Context, writeID WriteID, installation *lsv1alpha1.Installation) error

func (*Writer) DeleteSyncObject

func (w *Writer) DeleteSyncObject(ctx context.Context, writeID WriteID, syncObject *lsv1alpha1.SyncObject) error

func (*Writer) DeleteTarget

func (w *Writer) DeleteTarget(ctx context.Context, writeID WriteID, target *lsv1alpha1.Target) error

func (*Writer) UpdateDeployItem

func (w *Writer) UpdateDeployItem(ctx context.Context, writeID WriteID, deployItem *lsv1alpha1.DeployItem) error

func (*Writer) UpdateDeployItemStatus

func (w *Writer) UpdateDeployItemStatus(ctx context.Context, writeID WriteID, deployItem *lsv1alpha1.DeployItem) error

func (*Writer) UpdateExecution

func (w *Writer) UpdateExecution(ctx context.Context, writeID WriteID, execution *lsv1alpha1.Execution) error

func (*Writer) UpdateExecutionStatus

func (w *Writer) UpdateExecutionStatus(ctx context.Context, writeID WriteID, execution *lsv1alpha1.Execution) error

func (*Writer) UpdateInstallation

func (w *Writer) UpdateInstallation(ctx context.Context, writeID WriteID, installation *lsv1alpha1.Installation) error

func (*Writer) UpdateInstallationStatus

func (w *Writer) UpdateInstallationStatus(ctx context.Context, writeID WriteID, installation *lsv1alpha1.Installation) error

func (*Writer) UpdateSyncObject

func (w *Writer) UpdateSyncObject(ctx context.Context, writeID WriteID, syncObject *lsv1alpha1.SyncObject) error

Jump to

Keyboard shortcuts

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