MCPcopy Create free account
hub / github.com/apache/mesos / foreach

Function foreach

src/master/authorization.cpp:184–192  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

182 hashset<string> roles;
183
184 foreach (const Resource& resource, resources) {
185 const string role = getReservationRole(resource);
186
187 if (!roles.contains(role)) {
188 roles.insert(role);
189 result.push_back(fromResourceWithLegacyValue(
190 authorization::RESERVE_RESOURCES, resource, role));
191 }
192 }
193 };
194
195 // We support `Reserve` operations with either `source` set or unset. If

Callers

nothing calls this directly

Calls 5

getReservationRoleFunction · 0.85
insertMethod · 0.80
principalMethod · 0.80
containsMethod · 0.45
diskMethod · 0.45

Tested by

no test coverage detected