public FleetAttributes withMetricGroups(java.util.Collection<String> metricGroups) {
        setMetricGroups(metricGroups);
        return this;
    }
<p>
Name of a metric group that metrics for this fleet are added to. In Amazon CloudWatch, you can view aggregated
metrics for fleets that are in a metric group. A fleet can be included in only one metric group at a time. This
attribute is used with fleets where <code>ComputeType</code> is "EC2" or "Container".
</p>

@param metricGroups
       Name of a metric group that metrics for this fleet are added to. In Amazon CloudWatch, you can view
       aggregated metrics for fleets that are in a metric group. A fleet can be included in only one metric group
       at a time. This attribute is used with fleets where <code>ComputeType</code> is "EC2" or "Container".
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-gamelift/src/main/java/com/amazonaws/services/gamelift/model/FleetAttributes.java