if (trace) {
traceLookingForResource(mem, neededAssociations, greedy);
}
if (db.isInfeasibleRequest(mem)) {
throw new ImpossibleAmountOfMemoryException(mem + "MB memory request is too " +
"large to ever be fulfilled");
}
//availableEntries is never empty
final List<ResourcepoolEntry> availableEntries =