You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

strategy.go 1.2 kB

11 months ago
10 months ago
1234567891011121314151617181920212223242526272829303132333435363738394041
  1. package strategy
  2. const (
  3. REPLICATION = "replication"
  4. RESOURCES_PRICING = "resourcesPricing"
  5. STATIC_WEIGHT = "staticWeight"
  6. DYNAMIC_RESOURCES = "dynamicResources"
  7. RANDOM = "random"
  8. DATA_LOCALITY = "dataLocality" //感知数据位置,数据调度和计算调度协同,近数据调度
  9. ENERGY_CONSUMPTION = "energyConsumption" //根据各集群总体能耗水平调度作业,优先选择能耗低的集群调度作业
  10. LEASTLOADFIRST = "leastLoadFirst"
  11. )
  12. var (
  13. strategyNames = []string{REPLICATION, RESOURCES_PRICING, STATIC_WEIGHT, DYNAMIC_RESOURCES, RANDOM}
  14. )
  15. type Strategy interface {
  16. Schedule() ([]*AssignedCluster, error)
  17. }
  18. type AssignedCluster struct {
  19. ClusterId string
  20. ClusterName string
  21. Replicas int32
  22. Cmd string
  23. Envs []string
  24. Params []string
  25. ResourcesRequired []map[string]interface{}
  26. DatasetId string
  27. ImageId string
  28. CodeId string
  29. ModelId string
  30. Output string
  31. ModelName string
  32. ModelType string
  33. }
  34. func GetStrategyNames() []string {
  35. return strategyNames
  36. }

PCM is positioned as Software stack over Cloud, aiming to build the standards and ecology of heterogeneous cloud collaboration for JCC in a non intrusive and autonomous peer-to-peer manner.