{$group: {_id: {aid: "$account_id", etl: "$etl_type"},max_mem: { $max: "$final_metrics.memory.max" }}},Here is where I'm stuck:
group(<what goes here?>,max("max_mem","$final_metrics.memory.max"))
Single fields work fine, I can't figure out what to put to make multiple fields work.group(new Document("aid", "$accound_id").append("etl", "$etl_type"),max("max_mem","$final_metrics.memory.max"));