diff --git a/modules/percolator/src/main/java/org/elasticsearch/percolator/MultiPercolateResponse.java b/modules/percolator/src/main/java/org/elasticsearch/percolator/MultiPercolateResponse.java index afc5b7ab6c7..86ca3b0046d 100644 --- a/modules/percolator/src/main/java/org/elasticsearch/percolator/MultiPercolateResponse.java +++ b/modules/percolator/src/main/java/org/elasticsearch/percolator/MultiPercolateResponse.java @@ -24,7 +24,7 @@ import org.elasticsearch.common.Nullable; import org.elasticsearch.common.io.stream.StreamInput; import org.elasticsearch.common.io.stream.StreamOutput; import org.elasticsearch.common.io.stream.Streamable; -import org.elasticsearch.common.xcontent.ToXContent; +import org.elasticsearch.common.xcontent.ToXContentObject; import org.elasticsearch.common.xcontent.XContentBuilder; import java.io.IOException; @@ -40,7 +40,7 @@ import java.util.Iterator; * @deprecated Instead use multi search API with {@link PercolateQueryBuilder} */ @Deprecated -public class MultiPercolateResponse extends ActionResponse implements Iterable, ToXContent { +public class MultiPercolateResponse extends ActionResponse implements Iterable, ToXContentObject { private Item[] items; @@ -73,17 +73,19 @@ public class MultiPercolateResponse extends ActionResponse implements Iterable, ToXContent { +public class PercolateResponse extends BroadcastResponse implements Iterable, ToXContentObject { public static final Match[] EMPTY = new Match[0]; // PercolateQuery emits this score if no 'query' is defined in the percolate request @@ -113,6 +113,13 @@ public class PercolateResponse extends BroadcastResponse implements Iterable