Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateBasicInventory ¶
func CreateBasicInventory( vCenterID string, vms *[]vsphere.VM, infraData InfrastructureData, ) *api.Inventory
CreateBasicInventory creates a basic inventory object with the provided data This function consolidates the duplicated createBasicInventoryObj functions from vsphere.go and parser.go to ensure consistency and reduce duplication.
Types ¶
type InfrastructureData ¶
type InfrastructureData struct {
Datastores []api.Datastore
Networks []api.Network
HostPowerStates map[string]int
Hosts *[]api.Host
HostsPerCluster []int
ClustersPerDatacenter []int
TotalHosts int
TotalClusters int
TotalDatacenters int
VmsPerCluster []int
}
InfrastructureData contains all the infrastructure-related data needed to create an inventory
type InventoryData ¶
type InventoryUpdater ¶
type InventoryUpdater struct {
// contains filtered or unexported fields
}
func NewInventoryUpdater ¶
func NewInventoryUpdater(sourceID, agentID uuid.UUID, client client.Planner) *InventoryUpdater
func (*InventoryUpdater) UpdateServiceWithInventory ¶
func (u *InventoryUpdater) UpdateServiceWithInventory(ctx context.Context, inventory *api.Inventory)
type StatusUpdater ¶
func NewStatusUpdater ¶
func (*StatusUpdater) CalculateStatus ¶
func (s *StatusUpdater) CalculateStatus() (api.AgentStatus, string, *api.Inventory)
func (*StatusUpdater) UpdateStatus ¶
func (s *StatusUpdater) UpdateStatus(ctx context.Context, status api.AgentStatus, statusInfo string, credUrl string) error
Click to show internal directories.
Click to hide internal directories.