agent/engine/dockerstate/docker_task_engine_state.go
func (state *DockerTaskEngineState) ContainerMapByArn(arn string) (map[string]*apicontainer.DockerContainer, bool) {
	state.lock.RLock()
	defer state.lock.RUnlock()

	ret, ok := state.taskToID[arn]

	// Copy the map to avoid data race
	if ok {
		mc := make(map[string]*apicontainer.DockerContainer)
		for k, v := range ret {
			mc[k] = v
		}
		return mc, ok
	}

	return ret, ok
}
func (state *DockerTaskEngineState) ContainerMapByArn(arn string) (map[string]*apicontainer.DockerContainer, bool) {
	state.lock.RLock()
	defer state.lock.RUnlock()

	ret, ok := state.taskToID[arn]

	// Copy the map to avoid data race
	if ok {
		mc := make(map[string]*apicontainer.DockerContainer)
		for k, v := range ret {
			mc[k] = v
		}
		return mc, ok
	}

	return ret, ok
}
// ContainerMapByArn returns a map of containers belonging to a particular task ARN