- All Implemented Interfaces:
- org.apache.hadoop.yarn.server.api.ContainerLogAggregationPolicy
@InterfaceAudience.Private
public class SampleContainerLogAggregationPolicy
extends Object
implements org.apache.hadoop.yarn.server.api.ContainerLogAggregationPolicy
The sample policy samples logs of successful worker containers to aggregate.
It always aggregates AM container and failed/killed worker
containers' logs. To make sure small applications have enough logs, it only
applies sampling beyond minimal number of containers. The parameters can be
configured by SAMPLE_RATE and MIN_THRESHOLD. For example if SAMPLE_RATE is
0.2 and MIN_THRESHOLD is 20, for an application with 100 successful
worker containers, 20 + (100-20) * 0.2 = 36 containers's logs will be
aggregated.