Documentation
¶
Index ¶
- func CheckSpecImageCompatibility(csp string, spec cloudmodel.SpecInfo, image cloudmodel.ImageInfo) bool
- func FindAndSortVmOsImageInfoListBySimilarity(keywords string, kwDelimiters []string, vmImages []cloudmodel.ImageInfo, ...) []cloudmodel.ImageInfo
- func FindBestVmOsImage(keywords string, kwDelimiters []string, vmImages []cloudmodel.ImageInfo, ...) cloudmodel.ImageInfo
- func FindBestVmOsImageNameUsedInCsp(keywords string, kwDelimiters []string, vmImages []cloudmodel.ImageInfo, ...) string
- func FindCompatibleSpecAndImage(specs []cloudmodel.SpecInfo, images []cloudmodel.ImageInfo, csp string) (cloudmodel.SpecInfo, cloudmodel.ImageInfo, error)
- func GetDefaultImagesLimit() int
- func GetDefaultSpecsLimit() int
- func IsValidCspAndRegion(csp string, region string) (bool, error)
- func MBtoGiB(mb float64) uint32
- func RecommendK8sControlPlane(provider, region string, k8sInfoList KubernetesInfoList) (tbmodel.K8sClusterDynamicReq, error)
- func RecommendK8sNodeGroup(provider, region string, k8sInfoList KubernetesInfoList) (tbmodel.K8sNodeGroupReq, error)
- func RecommendSecurityGroup(csp string, region string, server onpremmodel.ServerProperty) (cloudmodel.SecurityGroupReq, error)
- func RecommendSecurityGroups(csp string, region string, servers []onpremmodel.ServerProperty) (cloudmodel.RecommendedSecurityGroupList, error)
- func RecommendVNet(csp string, region string, srcInfra onpremmodel.OnpremInfra) ([]cloudmodel.VNetReq, error)
- func RecommendVmInfra(desiredCsp string, desiredRegion string, srcInfra onpremmodel.OnpremInfra) (cloudmodel.RecommendedVmInfra, error)
- func RecommendVmInfraCandidates(desiredCsp string, desiredRegion string, srcInfra onpremmodel.OnpremInfra, ...) ([]cloudmodel.RecommendedVmInfra, error)
- func RecommendVmInfraWithDefaults(desiredCsp string, desiredRegion string, srcInfra onpremmodel.OnpremInfra) (cloudmodel.RecommendedVmInfraDynamicList, error)
- func RecommendVmOsImage(csp string, region string, server onpremmodel.ServerProperty) (cloudmodel.ImageInfo, error)
- func RecommendVmOsImageId(csp string, region string, server onpremmodel.ServerProperty) (string, error)
- func RecommendVmOsImages(csp string, region string, server onpremmodel.ServerProperty, limit int) ([]cloudmodel.ImageInfo, error)
- func RecommendVmOsImagesForSpec(csp string, region string, server onpremmodel.ServerProperty, limit int, ...) ([]cloudmodel.ImageInfo, error)
- func RecommendVmSpecs(csp string, region string, server onpremmodel.ServerProperty, limit int) (vmSpecList []cloudmodel.SpecInfo, length int, err error)
- func RecommendVmSpecsForImage(csp string, region string, server onpremmodel.ServerProperty, limit int, ...) (vmSpecList []cloudmodel.SpecInfo, length int, err error)
- func SetKeywordsAndDelimeters(server onpremmodel.ServerProperty) (string, []string, []string)
- type CompatibleSpecImagePair
- type Helm
- type InfraMatchRateSummary
- type Kubernetes
- type KubernetesInfoList
- type MatchRateVector
- type Node
- type NodeCount
- type NodeGroupInfo
- type NodeSpec
- type NodeType
- type RecommendationStatus
- type RecommendedInfraInfo
- type Release
- type Repo
- type VmOsImageInfoWithScore
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckSpecImageCompatibility ¶ added in v0.3.11
func CheckSpecImageCompatibility(csp string, spec cloudmodel.SpecInfo, image cloudmodel.ImageInfo) bool
CheckSpecImageCompatibility validates compatibility between a single VM spec and VM image
func FindAndSortVmOsImageInfoListBySimilarity ¶ added in v0.3.1
func FindAndSortVmOsImageInfoListBySimilarity(keywords string, kwDelimiters []string, vmImages []cloudmodel.ImageInfo, imgDelimiters []string) []cloudmodel.ImageInfo
FindAndSortVmOsImageInfoListBySimilarity finds VM OS images that match the keywords and sorts them by similarity score
func FindBestVmOsImage ¶ added in v0.1.1
func FindBestVmOsImage(keywords string, kwDelimiters []string, vmImages []cloudmodel.ImageInfo, imgDelimiters []string) cloudmodel.ImageInfo
FindBestVmOsImage finds the best matching image based on the similarity scores
func FindBestVmOsImageNameUsedInCsp ¶ added in v0.3.3
func FindBestVmOsImageNameUsedInCsp(keywords string, kwDelimiters []string, vmImages []cloudmodel.ImageInfo, imgDelimiters []string) string
FindBestVmOsImageNameUsedInCsp finds the best matching image based on the similarity scores
func FindCompatibleSpecAndImage ¶ added in v0.3.4
func FindCompatibleSpecAndImage(specs []cloudmodel.SpecInfo, images []cloudmodel.ImageInfo, csp string) (cloudmodel.SpecInfo, cloudmodel.ImageInfo, error)
FindCompatibleSpecAndImage finds a compatible VM spec and image pair by performing CSP-specific compatibility checks
func GetDefaultImagesLimit ¶ added in v0.3.6
func GetDefaultImagesLimit() int
GetDefaultImagesLimit returns the default VM images recommendation limit
func GetDefaultSpecsLimit ¶ added in v0.3.6
func GetDefaultSpecsLimit() int
GetDefaultSpecsLimit returns the default VM specs recommendation limit
func IsValidCspAndRegion ¶ added in v0.3.1
func RecommendK8sControlPlane ¶ added in v0.4.2
func RecommendK8sControlPlane(provider, region string, k8sInfoList KubernetesInfoList) (tbmodel.K8sClusterDynamicReq, error)
RecommendK8sControlPlane recommends K8s control plane configuration based on honeybee source cluster data
func RecommendK8sNodeGroup ¶ added in v0.4.2
func RecommendK8sNodeGroup(provider, region string, k8sInfoList KubernetesInfoList) (tbmodel.K8sNodeGroupReq, error)
RecommendK8sNodeGroup recommends K8s worker node group configuration based on honeybee source cluster data
func RecommendSecurityGroup ¶ added in v0.3.1
func RecommendSecurityGroup(csp string, region string, server onpremmodel.ServerProperty) (cloudmodel.SecurityGroupReq, error)
func RecommendSecurityGroups ¶ added in v0.3.1
func RecommendSecurityGroups(csp string, region string, servers []onpremmodel.ServerProperty) (cloudmodel.RecommendedSecurityGroupList, error)
func RecommendVNet ¶ added in v0.3.1
func RecommendVNet(csp string, region string, srcInfra onpremmodel.OnpremInfra) ([]cloudmodel.VNetReq, error)
RecommendVNet recommends virtual network configurations based on source infrastructure
func RecommendVmInfra ¶ added in v0.3.1
func RecommendVmInfra(desiredCsp string, desiredRegion string, srcInfra onpremmodel.OnpremInfra) (cloudmodel.RecommendedVmInfra, error)
RecommendVmInfra an appropriate multi-cloud infrastructure (MCI) for cloud migration
func RecommendVmInfraCandidates ¶ added in v0.4.6
func RecommendVmInfraCandidates(desiredCsp string, desiredRegion string, srcInfra onpremmodel.OnpremInfra, limit int, minMatchRate float64) ([]cloudmodel.RecommendedVmInfra, error)
RecommendVmInfraCandidates an appropriate multi-cloud infrastructure (MCI) for cloud migration
func RecommendVmInfraWithDefaults ¶ added in v0.3.1
func RecommendVmInfraWithDefaults(desiredCsp string, desiredRegion string, srcInfra onpremmodel.OnpremInfra) (cloudmodel.RecommendedVmInfraDynamicList, error)
RecommendVmInfraWithDefaults an appropriate multi-cloud infrastructure (MCI) for cloud migration
func RecommendVmOsImage ¶ added in v0.3.1
func RecommendVmOsImage(csp string, region string, server onpremmodel.ServerProperty) (cloudmodel.ImageInfo, error)
RecommendVmOsImage recommends an appropriate VM OS image (e.g., Ubuntu 22.04) for the given VM spec
func RecommendVmOsImageId ¶ added in v0.3.1
func RecommendVmOsImageId(csp string, region string, server onpremmodel.ServerProperty) (string, error)
RecommendVmOsImageId recommends an appropriate VM OS image (e.g., Ubuntu 22.04) for the given VM spec
func RecommendVmOsImages ¶ added in v0.3.1
func RecommendVmOsImages(csp string, region string, server onpremmodel.ServerProperty, limit int) ([]cloudmodel.ImageInfo, error)
RecommendVmOsImages recommends an appropriate VM OS image (e.g., Ubuntu 22.04) for the given VM spec
func RecommendVmOsImagesForSpec ¶ added in v0.3.10
func RecommendVmOsImagesForSpec(csp string, region string, server onpremmodel.ServerProperty, limit int, spec cloudmodel.SpecInfo) ([]cloudmodel.ImageInfo, error)
RecommendVmOsImagesForSpec recommends an appropriate VM OS images (e.g., Ubuntu 22.04) for the given VM spec
func RecommendVmSpecs ¶ added in v0.3.1
func RecommendVmSpecs(csp string, region string, server onpremmodel.ServerProperty, limit int) (vmSpecList []cloudmodel.SpecInfo, length int, err error)
RecommendVmSpecs recommends appropriate VM specs for the given server
func RecommendVmSpecsForImage ¶ added in v0.3.3
func RecommendVmSpecsForImage(csp string, region string, server onpremmodel.ServerProperty, limit int, image cloudmodel.ImageInfo) (vmSpecList []cloudmodel.SpecInfo, length int, err error)
RecommendVmSpecsForImage recommends appropriate VM specs for the server and image
func SetKeywordsAndDelimeters ¶ added in v0.4.6
func SetKeywordsAndDelimeters(server onpremmodel.ServerProperty) (string, []string, []string)
Types ¶
type CompatibleSpecImagePair ¶ added in v0.3.9
type CompatibleSpecImagePair struct {
Spec cloudmodel.SpecInfo `json:"spec"`
Image cloudmodel.ImageInfo `json:"image"`
}
func FindCompatibleVmSpecAndImagePairs ¶ added in v0.4.6
func FindCompatibleVmSpecAndImagePairs(specs []cloudmodel.SpecInfo, images []cloudmodel.ImageInfo, csp string) ([]CompatibleSpecImagePair, error)
FindCompatibleVmSpecAndImagePairs finds all compatible VM spec and image pairs by performing CSP-specific compatibility checks
type InfraMatchRateSummary ¶ added in v0.4.6
type InfraMatchRateSummary struct {
MinMatchRate float64 // Minimum match rate across all VMs (weakest link)
MaxMatchRate float64 // Maximum match rate across all VMs (best match)
AvgMatchRate float64 // Average match rate across all VMs
BestEffortRate float64 // Percentage of VMs meeting best-effort threshold
TotalVMs int // Total number of VMs evaluated
}
InfraMatchRateSummary represents overall infrastructure match rate metrics
type Kubernetes ¶ added in v0.4.2
type KubernetesInfoList ¶ added in v0.4.2
type KubernetesInfoList struct {
Servers []Kubernetes `json:"servers" validate:"required"`
}
Honeybee v0.4.0 Kubernetes models
type MatchRateVector ¶ added in v0.4.6
type MatchRateVector struct {
CPU float64 // CPU resource match rate (0-100%)
Memory float64 // Memory resource match rate (0-100%)
Image float64 // OS image similarity match rate (0-100%)
}
MatchRateVector represents multi-dimensional match rate scores for infrastructure recommendation Each dimension is independently evaluated (0-100%), making the system extensible without weight tuning
func (MatchRateVector) AverageMatchRate ¶ added in v0.4.6
func (q MatchRateVector) AverageMatchRate() float64
AverageMatchRate returns the average match rate across all dimensions
func (MatchRateVector) IsMatched ¶ added in v0.4.6
func (q MatchRateVector) IsMatched(threshold float64) bool
IsMatched checks if all dimensions meet the match rate threshold Rationale: "Best effort" requires ALL resources to be sufficiently matched
func (MatchRateVector) MaxMatchRate ¶ added in v0.4.6
func (q MatchRateVector) MaxMatchRate() float64
MaxMatchRate returns the maximum match rate score across all dimensions Rationale: Represents the strongest dimension match
func (MatchRateVector) MinMatchRate ¶ added in v0.4.6
func (q MatchRateVector) MinMatchRate() float64
MinMatchRate returns the minimum match rate score across all dimensions Rationale: Overall match rate is limited by the weakest dimension
type NodeGroupInfo ¶ added in v0.4.2
NodeGroupInfo holds aggregated information for a node group
type RecommendationStatus ¶ added in v0.2.1
type RecommendationStatus string
RecommendationStatus represents the status of a recommendation.
const ( NothingRecommended RecommendationStatus = "none" PartiallyRecommended RecommendationStatus = "partial" FullyRecommended RecommendationStatus = "ok" )
type RecommendedInfraInfo ¶ added in v0.2.1
type RecommendedInfraInfo struct {
Status string `json:"status"`
Description string `json:"description"`
TargetInfra tbmodel.MciDynamicReq `json:"targetInfra"`
}
* Models for Container Infrastructure (i.e., an infrastructure for Kubernetes)
type VmOsImageInfoWithScore ¶ added in v0.3.1
type VmOsImageInfoWithScore struct {
VmOsImageInfo cloudmodel.ImageInfo
SimilarityScore float64
}