Documentation
¶
Index ¶
- Constants
- Variables
- func BuildResourceMeta(phy, logi map[string]string) *inv_v1.GetResourceResponse_ResourceMetadata
- func ConnectEntDB(writerDatabaseURL, readerDatabaseURL string) *ent.Client
- func EmptyEnumStateMap(fname string, _ int32) (ent.Value, error)
- func GetOrderByOptions[T OrderOption](orderBy string, columnValidator func(string) bool) (opts []T, err error)
- func HostEnumStateMap(fname string, eint int32) (ent.Value, error)
- func HostnicEnumStateMap(fname string, eint int32) (ent.Value, error)
- func IPAddressEnumsMap(fname string, eint int32) (ent.Value, error)
- func InstanceEnumStateMap(fname string, eint int32) (ent.Value, error)
- func MetadataToMetaMap(metadata []Metadata) (map[string]string, error)
- func NetlinkEnumStateMap(fname string, eint int32) (ent.Value, error)
- func OSUpdatePolicyEnumStateMap(fname string, eint int32) (ent.Value, error)
- func OSUpdateRunEnumStateMap(fname string, eint int32) (ent.Value, error)
- func OsEnumStateMap(fname string, eint int32) (ent.Value, error)
- func ParseMetadata(metadata string) (map[string]string, error)
- func ProviderEnumStateMap(fname string, eint int32) (ent.Value, error)
- func RepeatedScheduleEnumStatusMap(fname string, eint int32) (ent.Value, error)
- func SingleScheduleEnumStatusMap(fname string, eint int32) (ent.Value, error)
- func TelemetryGroupEnumStatusMap(fname string, eint int32) (ent.Value, error)
- func TelemetryProfileEnumStatusMap(fname string, eint int32) (ent.Value, error)
- func ValidateMetadata(metadata string) (string, error)
- func ValidateOSMetadata(metadata string) (string, error)
- func ValidateTreeHierarchyResponse(in *inventoryv1.GetTreeHierarchyResponse) error
- func WorkloadEnumStatusMap(fname string, eint int32) (ent.Value, error)
- func WorkloadMemberEnumStatusMap(fname string, eint int32) (ent.Value, error)
- type DeletionKind
- type DoubleResultReturningTxFn
- type InstanceCarrier
- type InvStore
- func (is *InvStore) CloseEntClient() error
- func (is *InvStore) CreateCustomConfig(ctx context.Context, in *computev1.CustomConfigResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateEndpoint(ctx context.Context, in *network_v1.EndpointResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateHost(ctx context.Context, in *computev1.HostResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateHostgpu(ctx context.Context, in *computev1.HostgpuResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateHostnic(ctx context.Context, in *computev1.HostnicResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateHoststorage(ctx context.Context, in *computev1.HoststorageResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateHostusb(ctx context.Context, in *computev1.HostusbResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateIPAddress(ctx context.Context, in *network_v1.IPAddressResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateInstance(ctx context.Context, in *computev1.InstanceResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateLocalAccount(ctx context.Context, in *localaccount_v1.LocalAccountResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateNetlink(ctx context.Context, in *network_v1.NetlinkResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateNetworkSegment(ctx context.Context, in *network_v1.NetworkSegment) (*inv_v1.Resource, error)
- func (is *InvStore) CreateOSUpdatePolicy(ctx context.Context, in *compute_v1.OSUpdatePolicyResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateOSUpdateRun(ctx context.Context, in *compute_v1.OSUpdateRunResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateOs(ctx context.Context, in *os_v1.OperatingSystemResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateOu(ctx context.Context, in *ou_v1.OuResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateProvider(ctx context.Context, in *provider_v1.ProviderResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateRegion(ctx context.Context, in *location_v1.RegionResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateRemoteAccessConfig(ctx context.Context, in *remoteaccessv1.RemoteAccessConfiguration) (*inv_v1.Resource, error)
- func (is *InvStore) CreateRepeatedSchedule(ctx context.Context, in *schedule_v1.RepeatedScheduleResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateSingleSchedule(ctx context.Context, in *schedule_v1.SingleScheduleResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateSite(ctx context.Context, in *location_v1.SiteResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateTelemetryGroup(ctx context.Context, in *telemetry_v1.TelemetryGroupResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateTelemetryProfile(ctx context.Context, in *telemetry_v1.TelemetryProfile) (*inv_v1.Resource, error)
- func (is *InvStore) CreateTenant(ctx context.Context, in *tenantv1.Tenant) (*inv_v1.Resource, error)
- func (is *InvStore) CreateWorkload(ctx context.Context, in *computev1.WorkloadResource) (*inv_v1.Resource, error)
- func (is *InvStore) CreateWorkloadMember(ctx context.Context, in *computev1.WorkloadMember) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteCustomConfig(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteCustomConfigs(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteEndpoint(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteEndpoints(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteHost(ctx context.Context, id, tenantID string) (*inv_v1.Resource, bool, error)
- func (is *InvStore) DeleteHostGPUs(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteHostNICs(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteHostStorages(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteHostUSBs(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteHostgpu(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteHostnic(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteHosts(ctx context.Context, tenantID string, enforce bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteHoststorage(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteHostusb(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteIPAddress(_ context.Context, _ string) (*inv_v1.Resource, bool, error)
- func (is *InvStore) DeleteIPAddresses(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteInstance(ctx context.Context, id string) (*inv_v1.Resource, bool, error)
- func (is *InvStore) DeleteInstances(ctx context.Context, tenantID string, enforce bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteLocalAccount(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteLocalAccounts(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteNetLinks(ctx context.Context, tenantID string, enforce bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteNetlink(ctx context.Context, id string) (*inv_v1.Resource, bool, error)
- func (is *InvStore) DeleteNetworkSegment(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteNetworkSegments(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteOSUpdatePolicies(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteOSUpdatePolicy(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteOSUpdateRun(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteOSUpdateRuns(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteOSes(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteOs(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteOu(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteOus(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteProvider(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteProviders(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteRegion(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteRegions(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteRepeatedSchedule(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteRepeatedSchedules(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteSingleSchedule(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteSingleSchedules(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteSite(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteSites(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteTelemetryGroup(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteTelemetryGroups(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteTelemetryProfile(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteTelemetryProfiles(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteWorkload(ctx context.Context, id string) (*inv_v1.Resource, bool, error)
- func (is *InvStore) DeleteWorkloadMember(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) DeleteWorkloadMembers(ctx context.Context, tenantID string, _ bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) DeleteWorkloads(ctx context.Context, tenantID string, enforce bool) ([]*util.Tuple[DeletionKind, *inv_v1.Resource], error)
- func (is *InvStore) FilterCustomConfigs(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterEndpoints(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterHostgpus(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterHostnics(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterHosts(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterHoststorage(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterHostusb(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterIPAddress(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterInstances(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterLocalAccounts(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterNetlinks(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterNetworkSegments(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterOSUpdatePolicies(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterOSUpdateRuns(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterOss(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterOus(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterProviders(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterRegions(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterRemoteAccessConfig(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterRepeatedSchedules(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterSingleSchedules(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterSites(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterTelemetryGroup(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterTelemetryProfile(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterTenants(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterWorkload(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FilterWorkloadMember(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) FindResources(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*client.ResourceTenantIDCarrier, int, error)
- func (is *InvStore) GetCustomConfig(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetEndpoint(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetHost(ctx context.Context, id, tenantID string) (*inv_v1.Resource, *inv_v1.GetResourceResponse_ResourceMetadata, error)
- func (is *InvStore) GetHostgpu(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetHostnic(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetHoststorage(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetHostusb(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetIPAddress(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetInstance(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetLocalAccount(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetNetlink(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetNetworkSegment(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetOSUpdatePolicy(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetOSUpdateRun(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetOs(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetOu(ctx context.Context, id, tenantID string) (*inv_v1.Resource, *inv_v1.GetResourceResponse_ResourceMetadata, error)
- func (is *InvStore) GetProvider(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetRegion(ctx context.Context, id, tenantID string) (*inv_v1.Resource, *inv_v1.GetResourceResponse_ResourceMetadata, error)
- func (is *InvStore) GetRemoteAccessConfig(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetRepeatedSchedule(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetSingleSchedule(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetSite(ctx context.Context, id string, tenantID string) (*inv_v1.Resource, *inv_v1.GetResourceResponse_ResourceMetadata, error)
- func (is *InvStore) GetSitesPerRegion(ctx context.Context, filter *inventoryv1.GetSitesPerRegionRequest) (*inventoryv1.GetSitesPerRegionResponse, error)
- func (is *InvStore) GetTelemetryGroup(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetTelemetryProfile(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetTenant(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetTreeHierarchy(ctx context.Context, filter *inventoryv1.GetTreeHierarchyRequest) (*inventoryv1.GetTreeHierarchyResponse, error)
- func (is *InvStore) GetWorkload(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) GetWorkloadMember(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) ListCustomConfigs(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListEndpoints(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListHostgpus(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListHostnics(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListHosts(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListHoststorage(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListHostusb(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListIPAddress(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListInheritedTelemetryProfile(ctx context.Context, in *inv_v1.ListInheritedTelemetryProfilesRequest) ([]*telemetry_v1.TelemetryProfile, int, error)
- func (is *InvStore) ListInstances(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListLocalAccounts(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListNetlinks(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListNetworkSegments(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListOSUpdatePolicies(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListOSUpdateRuns(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListOss(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListOus(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListProviders(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListRegions(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListRemoteAccessConfig(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListRepeatedSchedules(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListResources(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListSingleSchedules(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListSites(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListTelemetryGroup(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListTelemetryProfile(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListTenants(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListWorkload(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) ListWorkloadMember(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
- func (is *InvStore) SoftDeleteRemoteAccessConfig(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) SoftDeleteTenant(ctx context.Context, id string) (*inv_v1.Resource, error)
- func (is *InvStore) TestGetEntClient() *ent.Client
- func (is *InvStore) UpdateDefaultTenantIDInTables(ctx context.Context, tables []string, tenantID string) error
- func (is *InvStore) UpdateEndpoint(ctx context.Context, id string, in *network_v1.EndpointResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateHost(ctx context.Context, id string, in *computev1.HostResource, ...) (*inv_v1.Resource, bool, error)
- func (is *InvStore) UpdateHostgpu(ctx context.Context, id string, in *computev1.HostgpuResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateHostnic(ctx context.Context, id string, in *computev1.HostnicResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateHoststorage(ctx context.Context, id string, in *computev1.HoststorageResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateHostusb(ctx context.Context, id string, in *computev1.HostusbResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateIPAddress(ctx context.Context, id string, in *network_v1.IPAddressResource, ...) (*inv_v1.Resource, bool, error)
- func (is *InvStore) UpdateInstance(ctx context.Context, id string, in *computev1.InstanceResource, ...) (*inv_v1.Resource, bool, error)
- func (is *InvStore) UpdateNetlink(ctx context.Context, id string, in *network_v1.NetlinkResource, ...) (*inv_v1.Resource, bool, error)
- func (is *InvStore) UpdateNetworkSegment(ctx context.Context, id string, in *network_v1.NetworkSegment, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateOSUpdatePolicy(ctx context.Context, id string, in *compute_v1.OSUpdatePolicyResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateOSUpdateRun(ctx context.Context, id string, in *compute_v1.OSUpdateRunResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateOs(ctx context.Context, id string, in *os_v1.OperatingSystemResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateOu(ctx context.Context, id string, in *ou_v1.OuResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateProvider(ctx context.Context, id string, in *provider_v1.ProviderResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateRegion(ctx context.Context, id string, in *location_v1.RegionResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateRemoteAccessConfig(ctx context.Context, id string, in *remoteaccessv1.RemoteAccessConfiguration, ...) (*inv_v1.Resource, bool, error)
- func (is *InvStore) UpdateRepeatedSchedule(ctx context.Context, id string, in *schedule_v1.RepeatedScheduleResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateSingleSchedule(ctx context.Context, id string, in *schedule_v1.SingleScheduleResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateSite(ctx context.Context, id string, in *location_v1.SiteResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateTelemetryGroup(ctx context.Context, id string, in *telemetry_v1.TelemetryGroupResource, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateTelemetryProfile(ctx context.Context, id string, in *telemetry_v1.TelemetryProfile, ...) (*inv_v1.Resource, error)
- func (is *InvStore) UpdateTenant(ctx context.Context, id string, in *tenantv1.Tenant, fm *fieldmaskpb.FieldMask) (*inv_v1.Resource, bool, error)
- func (is *InvStore) UpdateWorkload(ctx context.Context, id string, in *computev1.WorkloadResource, ...) (*inv_v1.Resource, bool, error)
- func (is *InvStore) UpdateWorkloadMember(ctx context.Context, id string, in *computev1.WorkloadMember, ...) (*inv_v1.Resource, error)
- type Metadata
- type NoResultReturningTxFn
- type OrderOption
- type SingleResultReturningTxFn
- type TransactionManager
- type Transpiler
Constants ¶
const ( PatchString = "PATCH" PutString = "PUT" )
const (
FunctionHas = "has"
)
const (
ISO8601Format = "2006-01-02T15:04:05.999Z"
)
Variables ¶
var MetadataPatternKey = regexp.MustCompile(
"^$|^[a-z.]+/$|^[a-z.]+/[a-z0-9][a-z0-9-_.]*[a-z0-9]$|^[a-z.]+/[a-z0-9]$|^[a-z]$|^[a-z0-9][a-z0-9-_.]*[a-z0-9]$")
MetadataPatternKey representing the metadata pattern for key.
var MetadataPatternValue = regexp.MustCompile("^$|^[a-z0-9]$|^[a-z0-9][a-z0-9+._-]*[a-z0-9]$")
MetadataPatternValue representing the metadata pattern for value.
var TypeNull = &expr.Type{TypeKind: &expr.Type_Null{Null: structpb.NullValue_NULL_VALUE}}
Functions ¶
func BuildResourceMeta ¶
func BuildResourceMeta(phy, logi map[string]string) *inv_v1.GetResourceResponse_ResourceMetadata
BuildResourceMeta builds the ResourceMetadata from the given map of physical and logical metadata. errors are not returned to the caller as they are skipped as of today.
func ConnectEntDB ¶
ConnectEntDB creates a ent client with the given database URLs. writerDatabaseURL is the primary Database URL, that has write capabilities. readerDatabaseURL is the Database URL with write only access (reader replicas). If the reader URL is missing, the ent client will use only the writer/primary URL.
func EmptyEnumStateMap ¶
EmptyEnumStateMap enum state mapping.
func GetOrderByOptions ¶
func GetOrderByOptions[T OrderOption](orderBy string, columnValidator func(string) bool) (opts []T, err error)
GetOrderByOptions takes an AIP-132 compliant orderBy string and returns the corresponding ent OrderOption. columnValidator is used to ensure only valid fields are selected. If no order is chosen (empty string), this returns a selector sorting by resource ID in ascending order.
func HostEnumStateMap ¶
enum state mapping.
func HostnicEnumStateMap ¶
enum state mapping.
func IPAddressEnumsMap ¶
enums mapping.
func InstanceEnumStateMap ¶
InstanceEnumStateMap maps proto enum fields to their Ent equivalents.
func MetadataToMetaMap ¶
MetadataToMetaMap transforms the given slide of Metadata into a map of string {Metadata.key : Metadata.value}. Returns an error in case of duplicated keys exist in the metadata.
func NetlinkEnumStateMap ¶
enum state mapping.
func OSUpdatePolicyEnumStateMap ¶ added in v2.26.2
OSUpdatePolicyEnumStateMap maps proto enum fields to their Ent equivalents.
func OSUpdateRunEnumStateMap ¶ added in v2.27.0
OSUpdateRunEnumStateMap maps proto enum fields to their Ent equivalents.
func OsEnumStateMap ¶
OsEnumStateMap maps proto enum fields to their Ent equivalents.
func ParseMetadata ¶
ParseMetadata parses the given metadata, we expect a JSON encoded metadata that follows the Metadata struct definition.
func ProviderEnumStateMap ¶
enum state mapping.
func RepeatedScheduleEnumStatusMap ¶
enum status mapping.
func SingleScheduleEnumStatusMap ¶
enum status mapping.
func TelemetryGroupEnumStatusMap ¶
enum status mapping.
func ValidateMetadata ¶
ValidateMetadata verifies that the given JSON encoded metadata contains the required fields, otherwise returns an error.
func ValidateOSMetadata ¶ added in v2.26.2
ValidateOSMetadata verifies that the given JSON encoded metadata contains the required fields, otherwise returns an error.
func ValidateTreeHierarchyResponse ¶
func ValidateTreeHierarchyResponse(in *inventoryv1.GetTreeHierarchyResponse) error
ValidateTreeHierarchyResponse returns an error if the tree hierarchy contains resource with unexpected parents. For example, a site containing a host as a parent.
func WorkloadEnumStatusMap ¶
enum status mapping.
Types ¶
type DeletionKind ¶
type DeletionKind string
const ( SOFT DeletionKind = "soft" HARD DeletionKind = "hard" )
type DoubleResultReturningTxFn ¶
type DoubleResultReturningTxFn[R1, R2 any] func( ctx context.Context, transactional func(ctx context.Context, tx *ent.Tx) (*R1, *R2, error)) (*R1, *R2, error)
func ExecuteInRoTxAndReturnDouble ¶
func ExecuteInRoTxAndReturnDouble[R1, R2 any](tm TransactionManager) DoubleResultReturningTxFn[R1, R2]
func ExecuteInTxAndReturnDouble ¶
func ExecuteInTxAndReturnDouble[R1, R2 any](tm TransactionManager) DoubleResultReturningTxFn[R1, R2]
type InstanceCarrier ¶
type InstanceCarrier interface {
SetInstanceID(id int)
}
type InvStore ¶
type InvStore struct {
// contains filtered or unexported fields
}
func (*InvStore) CreateCustomConfig ¶ added in v2.27.0
func (*InvStore) CreateEndpoint ¶
func (is *InvStore) CreateEndpoint(ctx context.Context, in *network_v1.EndpointResource) (*inv_v1.Resource, error)
func (*InvStore) CreateHost ¶
func (*InvStore) CreateHostgpu ¶
func (*InvStore) CreateHostnic ¶
func (*InvStore) CreateHoststorage ¶
func (*InvStore) CreateHostusb ¶
func (*InvStore) CreateIPAddress ¶
func (is *InvStore) CreateIPAddress(ctx context.Context, in *network_v1.IPAddressResource) (*inv_v1.Resource, error)
func (*InvStore) CreateInstance ¶
func (*InvStore) CreateLocalAccount ¶
func (is *InvStore) CreateLocalAccount(ctx context.Context, in *localaccount_v1.LocalAccountResource) (*inv_v1.Resource, error)
func (*InvStore) CreateNetlink ¶
func (is *InvStore) CreateNetlink(ctx context.Context, in *network_v1.NetlinkResource) (*inv_v1.Resource, error)
func (*InvStore) CreateNetworkSegment ¶
func (is *InvStore) CreateNetworkSegment(ctx context.Context, in *network_v1.NetworkSegment) (*inv_v1.Resource, error)
func (*InvStore) CreateOSUpdatePolicy ¶ added in v2.26.2
func (is *InvStore) CreateOSUpdatePolicy(ctx context.Context, in *compute_v1.OSUpdatePolicyResource) (*inv_v1.Resource, error)
func (*InvStore) CreateOSUpdateRun ¶ added in v2.27.0
func (is *InvStore) CreateOSUpdateRun(ctx context.Context, in *compute_v1.OSUpdateRunResource) (*inv_v1.Resource, error)
func (*InvStore) CreateProvider ¶
func (is *InvStore) CreateProvider(ctx context.Context, in *provider_v1.ProviderResource) (*inv_v1.Resource, error)
func (*InvStore) CreateRegion ¶
func (is *InvStore) CreateRegion(ctx context.Context, in *location_v1.RegionResource) (*inv_v1.Resource, error)
func (*InvStore) CreateRemoteAccessConfig ¶
func (is *InvStore) CreateRemoteAccessConfig(ctx context.Context, in *remoteaccessv1.RemoteAccessConfiguration, ) (*inv_v1.Resource, error)
func (*InvStore) CreateRepeatedSchedule ¶
func (is *InvStore) CreateRepeatedSchedule( ctx context.Context, in *schedule_v1.RepeatedScheduleResource, ) (*inv_v1.Resource, error)
func (*InvStore) CreateSingleSchedule ¶
func (is *InvStore) CreateSingleSchedule(ctx context.Context, in *schedule_v1.SingleScheduleResource) (*inv_v1.Resource, error)
func (*InvStore) CreateSite ¶
func (is *InvStore) CreateSite(ctx context.Context, in *location_v1.SiteResource) (*inv_v1.Resource, error)
func (*InvStore) CreateTelemetryGroup ¶
func (is *InvStore) CreateTelemetryGroup( ctx context.Context, in *telemetry_v1.TelemetryGroupResource, ) (*inv_v1.Resource, error)
func (*InvStore) CreateTelemetryProfile ¶
func (is *InvStore) CreateTelemetryProfile( ctx context.Context, in *telemetry_v1.TelemetryProfile, ) (*inv_v1.Resource, error)
func (*InvStore) CreateTenant ¶
func (*InvStore) CreateWorkload ¶
func (*InvStore) CreateWorkloadMember ¶
func (*InvStore) DeleteCustomConfig ¶ added in v2.27.0
func (*InvStore) DeleteCustomConfigs ¶ added in v2.27.0
func (*InvStore) DeleteEndpoint ¶
func (*InvStore) DeleteEndpoints ¶
func (*InvStore) DeleteHost ¶
func (*InvStore) DeleteHostGPUs ¶
func (*InvStore) DeleteHostNICs ¶
func (*InvStore) DeleteHostStorages ¶
func (*InvStore) DeleteHostUSBs ¶
func (*InvStore) DeleteHostgpu ¶
func (*InvStore) DeleteHostnic ¶
func (*InvStore) DeleteHosts ¶
func (*InvStore) DeleteHoststorage ¶
func (*InvStore) DeleteHostusb ¶
func (*InvStore) DeleteIPAddress ¶
func (*InvStore) DeleteIPAddresses ¶
func (*InvStore) DeleteInstance ¶
func (*InvStore) DeleteInstances ¶
func (*InvStore) DeleteLocalAccount ¶
func (*InvStore) DeleteLocalAccounts ¶
func (*InvStore) DeleteNetLinks ¶
func (*InvStore) DeleteNetlink ¶
func (*InvStore) DeleteNetworkSegment ¶
func (*InvStore) DeleteNetworkSegments ¶
func (*InvStore) DeleteOSUpdatePolicies ¶ added in v2.26.2
func (*InvStore) DeleteOSUpdatePolicy ¶ added in v2.26.2
func (*InvStore) DeleteOSUpdateRun ¶ added in v2.27.0
func (*InvStore) DeleteOSUpdateRuns ¶ added in v2.27.0
func (*InvStore) DeleteOSes ¶
func (*InvStore) DeleteProvider ¶
func (*InvStore) DeleteProviders ¶
func (*InvStore) DeleteRegion ¶
func (*InvStore) DeleteRegions ¶
func (*InvStore) DeleteRepeatedSchedule ¶
func (*InvStore) DeleteRepeatedSchedules ¶
func (*InvStore) DeleteSingleSchedule ¶
func (*InvStore) DeleteSingleSchedules ¶
func (*InvStore) DeleteSite ¶
func (*InvStore) DeleteSites ¶
func (*InvStore) DeleteTelemetryGroup ¶
func (*InvStore) DeleteTelemetryGroups ¶
func (*InvStore) DeleteTelemetryProfile ¶
func (*InvStore) DeleteTelemetryProfiles ¶
func (*InvStore) DeleteWorkload ¶
func (*InvStore) DeleteWorkloadMember ¶
func (*InvStore) DeleteWorkloadMembers ¶
func (*InvStore) DeleteWorkloads ¶
func (*InvStore) FilterCustomConfigs ¶ added in v2.27.0
func (is *InvStore) FilterCustomConfigs(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterEndpoints ¶
func (is *InvStore) FilterEndpoints(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterHostgpus ¶
func (is *InvStore) FilterHostgpus(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterHostnics ¶
func (is *InvStore) FilterHostnics(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterHosts ¶
func (is *InvStore) FilterHosts(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
func (*InvStore) FilterHoststorage ¶
func (is *InvStore) FilterHoststorage(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterHostusb ¶
func (is *InvStore) FilterHostusb(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterIPAddress ¶
func (is *InvStore) FilterIPAddress(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterInstances ¶
func (is *InvStore) FilterInstances(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterLocalAccounts ¶
func (is *InvStore) FilterLocalAccounts(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterNetlinks ¶
func (is *InvStore) FilterNetlinks(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterNetworkSegments ¶
func (is *InvStore) FilterNetworkSegments(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterOSUpdatePolicies ¶ added in v2.26.2
func (is *InvStore) FilterOSUpdatePolicies(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterOSUpdateRuns ¶ added in v2.27.0
func (is *InvStore) FilterOSUpdateRuns(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterOss ¶
func (is *InvStore) FilterOss(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
func (*InvStore) FilterOus ¶
func (is *InvStore) FilterOus(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
func (*InvStore) FilterProviders ¶
func (is *InvStore) FilterProviders(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterRegions ¶
func (is *InvStore) FilterRegions(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterRemoteAccessConfig ¶
func (is *InvStore) FilterRemoteAccessConfig(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterRepeatedSchedules ¶
func (is *InvStore) FilterRepeatedSchedules(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterSingleSchedules ¶
func (is *InvStore) FilterSingleSchedules(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterSites ¶
func (is *InvStore) FilterSites(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*cl.ResourceTenantIDCarrier, int, error)
func (*InvStore) FilterTelemetryGroup ¶
func (is *InvStore) FilterTelemetryGroup(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterTelemetryProfile ¶
func (is *InvStore) FilterTelemetryProfile(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterTenants ¶
func (is *InvStore) FilterTenants(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterWorkload ¶
func (is *InvStore) FilterWorkload(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FilterWorkloadMember ¶
func (is *InvStore) FilterWorkloadMember(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*cl.ResourceTenantIDCarrier, int, error, )
func (*InvStore) FindResources ¶
func (is *InvStore) FindResources(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*client.ResourceTenantIDCarrier, int, error, )
func (*InvStore) GetCustomConfig ¶ added in v2.27.0
func (*InvStore) GetEndpoint ¶
func (*InvStore) GetHostgpu ¶
func (*InvStore) GetHostnic ¶
func (*InvStore) GetHoststorage ¶
func (*InvStore) GetHostusb ¶
func (*InvStore) GetIPAddress ¶
func (*InvStore) GetInstance ¶
func (*InvStore) GetLocalAccount ¶
func (*InvStore) GetNetlink ¶
func (*InvStore) GetNetworkSegment ¶
func (*InvStore) GetOSUpdatePolicy ¶ added in v2.26.2
func (*InvStore) GetOSUpdateRun ¶ added in v2.27.0
func (*InvStore) GetProvider ¶
func (*InvStore) GetRemoteAccessConfig ¶
func (*InvStore) GetRepeatedSchedule ¶
func (*InvStore) GetSingleSchedule ¶
func (*InvStore) GetSitesPerRegion ¶
func (is *InvStore) GetSitesPerRegion(ctx context.Context, filter *inventoryv1.GetSitesPerRegionRequest) ( *inventoryv1.GetSitesPerRegionResponse, error, )
func (*InvStore) GetTelemetryGroup ¶
func (*InvStore) GetTelemetryProfile ¶
func (*InvStore) GetTreeHierarchy ¶
func (is *InvStore) GetTreeHierarchy(ctx context.Context, filter *inventoryv1.GetTreeHierarchyRequest) ( *inventoryv1.GetTreeHierarchyResponse, error, )
func (*InvStore) GetWorkload ¶
func (*InvStore) GetWorkloadMember ¶
func (*InvStore) ListCustomConfigs ¶ added in v2.27.0
func (is *InvStore) ListCustomConfigs(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListEndpoints ¶
func (is *InvStore) ListEndpoints(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListHostgpus ¶
func (is *InvStore) ListHostgpus(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListHostnics ¶
func (is *InvStore) ListHostnics(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListHosts ¶
func (is *InvStore) ListHosts(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListHoststorage ¶
func (is *InvStore) ListHoststorage(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListHostusb ¶
func (is *InvStore) ListHostusb(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListIPAddress ¶
func (is *InvStore) ListIPAddress(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListInheritedTelemetryProfile ¶
func (is *InvStore) ListInheritedTelemetryProfile( ctx context.Context, in *inv_v1.ListInheritedTelemetryProfilesRequest, ) ([]*telemetry_v1.TelemetryProfile, int, error)
func (*InvStore) ListInstances ¶
func (is *InvStore) ListInstances(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListLocalAccounts ¶
func (is *InvStore) ListLocalAccounts(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListNetlinks ¶
func (is *InvStore) ListNetlinks(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListNetworkSegments ¶
func (is *InvStore) ListNetworkSegments( ctx context.Context, filter *inv_v1.ResourceFilter, ) ([]*inv_v1.GetResourceResponse, int, error)
func (*InvStore) ListOSUpdatePolicies ¶ added in v2.26.2
func (is *InvStore) ListOSUpdatePolicies(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListOSUpdateRuns ¶ added in v2.27.0
func (is *InvStore) ListOSUpdateRuns(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListOss ¶
func (is *InvStore) ListOss(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListOus ¶
func (is *InvStore) ListOus(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListProviders ¶
func (is *InvStore) ListProviders(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListRegions ¶
func (is *InvStore) ListRegions(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListRemoteAccessConfig ¶
func (is *InvStore) ListRemoteAccessConfig(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListRepeatedSchedules ¶
func (is *InvStore) ListRepeatedSchedules( ctx context.Context, filter *inv_v1.ResourceFilter, ) ([]*inv_v1.GetResourceResponse, int, error)
func (*InvStore) ListResources ¶
func (is *InvStore) ListResources(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListSingleSchedules ¶
func (is *InvStore) ListSingleSchedules( ctx context.Context, filter *inv_v1.ResourceFilter, ) ([]*inv_v1.GetResourceResponse, int, error)
func (*InvStore) ListSites ¶
func (is *InvStore) ListSites(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListTelemetryGroup ¶
func (is *InvStore) ListTelemetryGroup( ctx context.Context, filter *inv_v1.ResourceFilter, ) ([]*inv_v1.GetResourceResponse, int, error)
func (*InvStore) ListTelemetryProfile ¶
func (is *InvStore) ListTelemetryProfile( ctx context.Context, filter *inv_v1.ResourceFilter, ) ([]*inv_v1.GetResourceResponse, int, error)
func (*InvStore) ListTenants ¶
func (is *InvStore) ListTenants(ctx context.Context, filter *inv_v1.ResourceFilter) ([]*inv_v1.GetResourceResponse, int, error)
func (*InvStore) ListWorkload ¶
func (is *InvStore) ListWorkload(ctx context.Context, filter *inv_v1.ResourceFilter) ( []*inv_v1.GetResourceResponse, int, error, )
func (*InvStore) ListWorkloadMember ¶
func (is *InvStore) ListWorkloadMember( ctx context.Context, filter *inv_v1.ResourceFilter, ) ([]*inv_v1.GetResourceResponse, int, error)
func (*InvStore) SoftDeleteRemoteAccessConfig ¶
func (*InvStore) SoftDeleteTenant ¶
func (*InvStore) TestGetEntClient ¶
func (*InvStore) UpdateDefaultTenantIDInTables ¶
func (is *InvStore) UpdateDefaultTenantIDInTables(ctx context.Context, tables []string, tenantID string) error
UpdateDefaultTenantIDInTables updates the tenant_id in the specified tables where tenant_id equals '0'. It executes the update within a transaction to ensure atomicity, preventing partial updates in case of an error.
func (*InvStore) UpdateEndpoint ¶
func (is *InvStore) UpdateEndpoint( ctx context.Context, id string, in *network_v1.EndpointResource, fm *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateHost ¶
func (*InvStore) UpdateHostgpu ¶
func (*InvStore) UpdateHostnic ¶
func (*InvStore) UpdateHoststorage ¶
func (*InvStore) UpdateHostusb ¶
func (*InvStore) UpdateIPAddress ¶
func (is *InvStore) UpdateIPAddress( ctx context.Context, id string, in *network_v1.IPAddressResource, fieldmask *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, bool, error)
func (*InvStore) UpdateInstance ¶
func (*InvStore) UpdateNetlink ¶
func (is *InvStore) UpdateNetlink( ctx context.Context, id string, in *network_v1.NetlinkResource, fieldmask *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, bool, error)
func (*InvStore) UpdateNetworkSegment ¶
func (is *InvStore) UpdateNetworkSegment( ctx context.Context, id string, in *network_v1.NetworkSegment, fieldmask *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateOSUpdatePolicy ¶ added in v2.26.2
func (is *InvStore) UpdateOSUpdatePolicy( ctx context.Context, id string, in *compute_v1.OSUpdatePolicyResource, fieldmask *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateOSUpdateRun ¶ added in v2.27.0
func (is *InvStore) UpdateOSUpdateRun( ctx context.Context, id string, in *compute_v1.OSUpdateRunResource, fieldmask *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateProvider ¶
func (is *InvStore) UpdateProvider( ctx context.Context, id string, in *provider_v1.ProviderResource, fieldmask *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateRegion ¶
func (is *InvStore) UpdateRegion( ctx context.Context, id string, in *location_v1.RegionResource, fm *fieldmaskpb.FieldMask, tenantID string, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateRemoteAccessConfig ¶
func (is *InvStore) UpdateRemoteAccessConfig( ctx context.Context, id string, in *remoteaccessv1.RemoteAccessConfiguration, fm *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, bool, error)
func (*InvStore) UpdateRepeatedSchedule ¶
func (is *InvStore) UpdateRepeatedSchedule( ctx context.Context, id string, in *schedule_v1.RepeatedScheduleResource, fieldmask *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateSingleSchedule ¶
func (is *InvStore) UpdateSingleSchedule( ctx context.Context, id string, in *schedule_v1.SingleScheduleResource, fieldmask *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateSite ¶
func (is *InvStore) UpdateSite( ctx context.Context, id string, in *location_v1.SiteResource, fieldmask *fieldmaskpb.FieldMask, tenantID string, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateTelemetryGroup ¶
func (is *InvStore) UpdateTelemetryGroup( ctx context.Context, id string, in *telemetry_v1.TelemetryGroupResource, fieldmask *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateTelemetryProfile ¶
func (is *InvStore) UpdateTelemetryProfile( ctx context.Context, id string, in *telemetry_v1.TelemetryProfile, fieldmask *fieldmaskpb.FieldMask, ) (*inv_v1.Resource, error)
func (*InvStore) UpdateTenant ¶
func (*InvStore) UpdateWorkload ¶
func (*InvStore) UpdateWorkloadMember ¶
type NoResultReturningTxFn ¶
type NoResultReturningTxFn func( ctx context.Context, transactional func(ctx context.Context, tx *ent.Tx) error) error
func ExecuteInRoTx ¶
func ExecuteInRoTx(tm TransactionManager) NoResultReturningTxFn
func ExecuteInTx ¶
func ExecuteInTx(tm TransactionManager) NoResultReturningTxFn
type OrderOption ¶
type OrderOption interface { endpointresource.OrderOption | hostgpuresource.OrderOption | hostnicresource.OrderOption | hostresource.OrderOption | hoststorage.OrderOption | hostusb.OrderOption | instanceresource.OrderOption | ipaddressresource.OrderOption | netlinkresource.OrderOption | networksegment.OrderOption | oss.OrderOption | ouresource.OrderOption | providerresource.OrderOption | regionresource.OrderOption | repeatedscheduleresource.OrderOption | singlescheduleresource.OrderOption | siteresource.OrderOption | workloadresource.OrderOption | workloadmember.OrderOption | telemetryprofile.OrderOption | telemetrygroupresource.OrderOption | remoteaccessconfiguration.OrderOption | tenant.OrderOption | localaccountresource.OrderOption | osupdatepolicyresource.OrderOption | customconfigresource.OrderOption | osupdaterunresource.OrderOption }
type SingleResultReturningTxFn ¶
type SingleResultReturningTxFn[R1 any] func( ctx context.Context, transactional func(ctx context.Context, tx *ent.Tx) (*R1, error)) (*R1, error)
func ExecuteInRoTxAndReturnSingle ¶
func ExecuteInRoTxAndReturnSingle[R1 any](tm TransactionManager) SingleResultReturningTxFn[R1]
func ExecuteInTxAndReturnSingle ¶
func ExecuteInTxAndReturnSingle[R1 any](tm TransactionManager) SingleResultReturningTxFn[R1]
type TransactionManager ¶
type TransactionManager interface {
// contains filtered or unexported methods
}
type Transpiler ¶
type Transpiler struct {
// contains filtered or unexported fields
}
Source Files
¶
- connect_db.go
- conversions.go
- customconfig.go
- customconfig_transpiler.go
- endpoint.go
- endpoint_transpiler.go
- filter.go
- find.go
- hierarchy.go
- host.go
- host_transpiler.go
- hostgpu.go
- hostgpu_transpiler.go
- hostnic.go
- hostnic_transpiler.go
- hoststorage.go
- hoststorage_transpiler.go
- hostusb.go
- hostusb_transpiler.go
- instance.go
- instance_transpiler.go
- ip_address.go
- ipaddress_transpiler.go
- localaccount.go
- localaccount_transpiler.go
- migration.go
- mutate.go
- netlink.go
- netlink_transpiler.go
- networksegment.go
- networksegment_transpiler.go
- os.go
- os_transpiler.go
- osupdatepolicy.go
- osupdatepolicy_transpiler.go
- osupdaterun.go
- osupdaterun_transpiler.go
- ou.go
- ou_transpiler.go
- provider.go
- provider_transpiler.go
- region.go
- region_transpiler.go
- remoteaccess.go
- remoteaccess_validator.go
- repeatedschedule.go
- repeatedschedule_transpiler.go
- rmtaccessconf_transpiler.go
- singleschedule.go
- singleschedule_transpiler.go
- site.go
- site_transpiler.go
- store.go
- telemetrygroup.go
- telemetrygroup_transpiler.go
- telemetryprofile.go
- telemetryprofile_transpiler.go
- tenant.go
- tenant_transpiler.go
- transaction_wrapper.go
- util.go
- utils_metadata.go
- validation.go
- workload.go
- workload_member.go
- workload_transpiler.go
- workloadmember_transpiler.go