func (agent *ecsAgent) initializeResourceFields(credentialsManager credentials.Manager) {
	agent.resourceFields = &taskresource.ResourceFields{
		Control: cgroup.New(),
		ResourceFieldsCommon: &taskresource.ResourceFieldsCommon{
			IOUtil:             ioutilwrapper.NewIOUtil(),
			ASMClientCreator:   asmfactory.NewClientCreator(),
			SSMClientCreator:   ssmfactory.NewSSMClientCreator(),
			CredentialsManager: credentialsManager,
		},
		Ctx:              agent.ctx,
		DockerClient:     agent.dockerClient,
		NvidiaGPUManager: gpu.NewNvidiaGPUManager(),
	}
}
func (agent *ecsAgent) initializeResourceFields(credentialsManager credentials.Manager) {
	agent.resourceFields = &taskresource.ResourceFields{
		Control: cgroup.New(),
		ResourceFieldsCommon: &taskresource.ResourceFieldsCommon{
			IOUtil:             ioutilwrapper.NewIOUtil(),
			ASMClientCreator:   asmfactory.NewClientCreator(),
			SSMClientCreator:   ssmfactory.NewSSMClientCreator(),
			CredentialsManager: credentialsManager,
		},
		Ctx:              agent.ctx,
		DockerClient:     agent.dockerClient,
		NvidiaGPUManager: gpu.NewNvidiaGPUManager(),
	}
}
func ( agent * ecsAgent ) initializeResourceFields ( credentialsManager credentials . Manager ) { agent . resourceFields = & taskresource . ResourceFields { Control : cgroup . New ( ) , ResourceFieldsCommon : & taskresource . ResourceFieldsCommon { IOUtil : ioutilwrapper . NewIOUtil ( ) , ASMClientCreator : asmfactory . NewClientCreator ( ) , SSMClientCreator : ssmfactory . NewSSMClientCreator ( ) , CredentialsManager : credentialsManager , } , Ctx : agent . ctx , DockerClient : agent . dockerClient , NvidiaGPUManager : gpu . NewNvidiaGPUManager ( ) , } }
// initializeResourceFields exists mainly for testing doStart() to use mock Control
// object
initializeResourceFields exists mainly for testing doStart () to use mock Control object