|
- package param
-
- import "gitlink.org.cn/JointCloud/pcm-coordinator/api/internal/scheduler/entity"
-
- type ReplicationParams struct {
- Replicas int32
- *Params
- }
-
- func (r *ReplicationParams) GetReplicas() int32 {
- return r.Replicas
- }
-
- func (r *ReplicationParams) GetParticipants() []*entity.Participant {
- var participants []*entity.Participant
- for _, resource := range r.Resources {
- participants = append(participants, &entity.Participant{
- Participant_id: resource.ParticipantId,
- Name: resource.Name,
- })
- }
- return participants
- }
|