Meng Zhu created MESOS-9197:
-------------------------------
Summary: Optimize `Resources::contains()`.
Key: MESOS-9197
URL: https://issues.apache.org/jira/browse/MESOS-9197
Project: Mesos
Issue Type: Improvement
Reporter: Meng Zhu
Assignee: Meng Zhu
Currently, there are two issues:
1. Surprisingly, `contains` always make a copy of the superset resources. This
could be avoided.
https://github.com/apache/mesos/blob/f7e3872b0359c6095f8eeaefe408cb7dcef5bb83/src/common/resources.cpp#L1415
2. In `Resources::contains(const Resource& that)`, we always do validation
which is expensive. We should provide a validation free version of `contains()`
for `Resources` that we know are valid.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)