It would be enough to write: `Collections.nCopies(numSlots, ResourceProfile.ANY);`
The returned `List` would also be immutable. At the moment there is no need to return a mutable list. I would even say it is not right that after calling `Collection<ResourceProfile> startNewWorker(ResourceProfile resourceProfile)`, one may potentially modify the state of the ResourceManager (by accidentally modifying the returned collection). [ Full content available at: https://github.com/apache/flink/pull/6734 ] This message was relayed via gitbox.apache.org for [email protected]
