Skip to content

Commit

Permalink
Deprecate it, and add an explanation
Browse files Browse the repository at this point in the history
  • Loading branch information
joegallo committed Jan 20, 2022
1 parent deaccd5 commit c1d7a35
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,15 @@
import java.io.IOException;
import java.util.Map;

/**
* The actual moving_avg aggregation was removed as a breaking change in 8.0. This class exists to provide a friendlier error message
* if somebody attempts to use the moving_avg aggregation via the compatible-with=7 mechanism.
*
* We can remove this class entirely when v7 rest api compatibility is dropped.
*
* @deprecated Only for 7.x rest compat
*/
@Deprecated
public class MovAvgPipelineAggregationBuilder extends AbstractPipelineAggregationBuilder<MovAvgPipelineAggregationBuilder> {
private static final DeprecationLogger deprecationLogger = DeprecationLogger.getLogger(CommonTermsQueryBuilder.class);
public static final String MOVING_AVG_AGG_DEPRECATION_MSG = "Moving Average aggregation usage is not supported. "
Expand Down

0 comments on commit c1d7a35

Please sign in to comment.