/** * Sets the parent id of this document. Will simply set the routing to this value, as it is only * used for routing with delete requests. */ public TermVectorsRequestBuilder setParent(String parent) { request.parent(parent); return this; }
public TermVectorsRequest(MultiGetRequest.Item item) { super(item.index()); this.id = item.id(); this.type = item.type(); this.selectedFields(item.storedFields()); this.routing(item.routing()); this.parent(item.parent()); }
/** * Sets the parent id of this document. Will simply set the routing to this value, as it is only * used for routing with delete requests. */ public TermVectorsRequestBuilder setParent(String parent) { request.parent(parent); return this; }
/** * Constructs a new term vector request for a document that will be fetch * from the provided index. Use {@link #type(String)} and * {@link #id(String)} to specify the document to load. */ public TermVectorsRequest(TermVectorsRequest other) { super(other.index()); this.id = other.id(); this.type = other.type(); if (other.doc != null) { this.doc = new BytesArray(other.doc().toBytesRef(), true); this.xContentType = other.xContentType; } this.flagsEnum = other.getFlags().clone(); this.preference = other.preference(); this.routing = other.routing(); this.parent = other.parent(); if (other.selectedFields != null) { this.selectedFields = new HashSet<>(other.selectedFields); } if (other.perFieldAnalyzer != null) { this.perFieldAnalyzer = new HashMap<>(other.perFieldAnalyzer); } this.realtime = other.realtime(); this.version = other.version(); this.versionType = VersionType.fromValue(other.versionType().getValue()); this.filterSettings = other.filterSettings(); }
/** * Sets the parent id of this document. Will simply set the routing to this value, as it is only * used for routing with delete requests. */ public TermVectorsRequestBuilder setParent(String parent) { request.parent(parent); return this; }
/** * Sets the parent id of this document. Will simply set the routing to this value, as it is only * used for routing with delete requests. */ public TermVectorsRequestBuilder setParent(String parent) { request.parent(parent); return this; }
/** * Sets the parent id of this document. Will simply set the routing to this value, as it is only * used for routing with delete requests. */ public TermVectorsRequestBuilder setParent(String parent) { request.parent(parent); return this; }
TermVectorsRequest termVectorsRequest = request.requests.get(i); termVectorsRequest.routing(clusterState.metaData() .resolveIndexRouting(termVectorsRequest.parent(), termVectorsRequest.routing(), termVectorsRequest.index())); if (!clusterState.metaData().hasConcreteIndex(termVectorsRequest.index())) { responses.set(i, new MultiTermVectorsItemResponse(null,
@Override protected void resolveRequest(ClusterState state, InternalRequest request) { // update the routing (request#index here is possibly an alias or a parent) request.request().routing(state.metaData() .resolveIndexRouting(request.request().parent(), request.request().routing(), request.request().index())); // Fail fast on the node that received the request. if (request.request().routing() == null && state.getMetaData().routingRequired(request.concreteIndex(), request.request().type())) { throw new RoutingMissingException(request.concreteIndex(), request.request().type(), request.request().id()); } }
public static void readURIParameters(TermVectorsRequest termVectorsRequest, RestRequest request) { String fields = request.param("fields"); addFieldStringsFromParameter(termVectorsRequest, fields); termVectorsRequest.offsets(request.paramAsBoolean("offsets", termVectorsRequest.offsets())); termVectorsRequest.positions(request.paramAsBoolean("positions", termVectorsRequest.positions())); termVectorsRequest.payloads(request.paramAsBoolean("payloads", termVectorsRequest.payloads())); termVectorsRequest.routing(request.param("routing")); termVectorsRequest.realtime(request.paramAsBoolean("realtime", termVectorsRequest.realtime())); termVectorsRequest.version(RestActions.parseVersion(request, termVectorsRequest.version())); termVectorsRequest.versionType(VersionType.fromString(request.param("version_type"), termVectorsRequest.versionType())); termVectorsRequest.parent(request.param("parent")); termVectorsRequest.preference(request.param("preference")); termVectorsRequest.termStatistics(request.paramAsBoolean("termStatistics", termVectorsRequest.termStatistics())); termVectorsRequest.termStatistics(request.paramAsBoolean("term_statistics", termVectorsRequest.termStatistics())); termVectorsRequest.fieldStatistics(request.paramAsBoolean("fieldStatistics", termVectorsRequest.fieldStatistics())); termVectorsRequest.fieldStatistics(request.paramAsBoolean("field_statistics", termVectorsRequest.fieldStatistics())); }
public TermVectorsRequest(MultiGetRequest.Item item) { super(item.index()); this.id = item.id(); this.type = item.type(); this.selectedFields(item.storedFields()); this.routing(item.routing()); this.parent(item.parent()); }
public TermVectorsRequest(MultiGetRequest.Item item) { super(item.index()); this.id = item.id(); this.type = item.type(); this.selectedFields(item.storedFields()); this.routing(item.routing()); this.parent(item.parent()); }
public TermVectorsRequest(MultiGetRequest.Item item) { super(item.index()); this.id = item.id(); this.type = item.type(); this.selectedFields(item.storedFields()); this.routing(item.routing()); this.parent(item.parent()); }
@Override protected void resolveRequest(ClusterState state, InternalRequest request) { // update the routing (request#index here is possibly an alias or a parent) request.request().routing(state.metaData().resolveIndexRouting(request.request().parent(), request.request().routing(), request.request().index())); // Fail fast on the node that received the request. if (request.request().routing() == null && state.getMetaData().routingRequired(request.concreteIndex(), request.request().type())) { throw new RoutingMissingException(request.concreteIndex(), request.request().type(), request.request().id()); } }
@Override protected void resolveRequest(ClusterState state, InternalRequest request) { // update the routing (request#index here is possibly an alias or a parent) request.request().routing(state.metaData().resolveIndexRouting(request.request().parent(), request.request().routing(), request.request().index())); // Fail fast on the node that received the request. if (request.request().routing() == null && state.getMetaData().routingRequired(request.concreteIndex(), request.request().type())) { throw new RoutingMissingException(request.concreteIndex(), request.request().type(), request.request().id()); } }
@Override protected void resolveRequest(ClusterState state, InternalRequest request) { // update the routing (request#index here is possibly an alias or a parent) request.request().routing(state.metaData().resolveIndexRouting(request.request().parent(), request.request().routing(), request.request().index())); // Fail fast on the node that received the request. if (request.request().routing() == null && state.getMetaData().routingRequired(request.concreteIndex(), request.request().type())) { throw new RoutingMissingException(request.concreteIndex(), request.request().type(), request.request().id()); } }
public static void readURIParameters(TermVectorsRequest termVectorsRequest, RestRequest request) { String fields = request.param("fields"); addFieldStringsFromParameter(termVectorsRequest, fields); termVectorsRequest.offsets(request.paramAsBoolean("offsets", termVectorsRequest.offsets())); termVectorsRequest.positions(request.paramAsBoolean("positions", termVectorsRequest.positions())); termVectorsRequest.payloads(request.paramAsBoolean("payloads", termVectorsRequest.payloads())); termVectorsRequest.routing(request.param("routing")); termVectorsRequest.realtime(request.paramAsBoolean("realtime", termVectorsRequest.realtime())); termVectorsRequest.version(RestActions.parseVersion(request, termVectorsRequest.version())); termVectorsRequest.versionType(VersionType.fromString(request.param("version_type"), termVectorsRequest.versionType())); termVectorsRequest.parent(request.param("parent")); termVectorsRequest.preference(request.param("preference")); termVectorsRequest.termStatistics(request.paramAsBoolean("termStatistics", termVectorsRequest.termStatistics())); termVectorsRequest.termStatistics(request.paramAsBoolean("term_statistics", termVectorsRequest.termStatistics())); termVectorsRequest.fieldStatistics(request.paramAsBoolean("fieldStatistics", termVectorsRequest.fieldStatistics())); termVectorsRequest.fieldStatistics(request.paramAsBoolean("field_statistics", termVectorsRequest.fieldStatistics())); }
public static void readURIParameters(TermVectorsRequest termVectorsRequest, RestRequest request) { String fields = request.param("fields"); addFieldStringsFromParameter(termVectorsRequest, fields); termVectorsRequest.offsets(request.paramAsBoolean("offsets", termVectorsRequest.offsets())); termVectorsRequest.positions(request.paramAsBoolean("positions", termVectorsRequest.positions())); termVectorsRequest.payloads(request.paramAsBoolean("payloads", termVectorsRequest.payloads())); termVectorsRequest.routing(request.param("routing")); termVectorsRequest.realtime(request.paramAsBoolean("realtime", termVectorsRequest.realtime())); termVectorsRequest.version(RestActions.parseVersion(request, termVectorsRequest.version())); termVectorsRequest.versionType(VersionType.fromString(request.param("version_type"), termVectorsRequest.versionType())); termVectorsRequest.parent(request.param("parent")); termVectorsRequest.preference(request.param("preference")); termVectorsRequest.termStatistics(request.paramAsBoolean("termStatistics", termVectorsRequest.termStatistics())); termVectorsRequest.termStatistics(request.paramAsBoolean("term_statistics", termVectorsRequest.termStatistics())); termVectorsRequest.fieldStatistics(request.paramAsBoolean("fieldStatistics", termVectorsRequest.fieldStatistics())); termVectorsRequest.fieldStatistics(request.paramAsBoolean("field_statistics", termVectorsRequest.fieldStatistics())); }
public static void readURIParameters(TermVectorsRequest termVectorsRequest, RestRequest request) { String fields = request.param("fields"); addFieldStringsFromParameter(termVectorsRequest, fields); termVectorsRequest.offsets(request.paramAsBoolean("offsets", termVectorsRequest.offsets())); termVectorsRequest.positions(request.paramAsBoolean("positions", termVectorsRequest.positions())); termVectorsRequest.payloads(request.paramAsBoolean("payloads", termVectorsRequest.payloads())); termVectorsRequest.routing(request.param("routing")); termVectorsRequest.realtime(request.paramAsBoolean("realtime", termVectorsRequest.realtime())); termVectorsRequest.version(RestActions.parseVersion(request, termVectorsRequest.version())); termVectorsRequest.versionType(VersionType.fromString(request.param("version_type"), termVectorsRequest.versionType())); termVectorsRequest.parent(request.param("parent")); termVectorsRequest.preference(request.param("preference")); termVectorsRequest.termStatistics(request.paramAsBoolean("termStatistics", termVectorsRequest.termStatistics())); termVectorsRequest.termStatistics(request.paramAsBoolean("term_statistics", termVectorsRequest.termStatistics())); termVectorsRequest.fieldStatistics(request.paramAsBoolean("fieldStatistics", termVectorsRequest.fieldStatistics())); termVectorsRequest.fieldStatistics(request.paramAsBoolean("field_statistics", termVectorsRequest.fieldStatistics())); }
static public void readURIParameters(TermVectorsRequest termVectorsRequest, RestRequest request) { String fields = request.param("fields"); addFieldStringsFromParameter(termVectorsRequest, fields); termVectorsRequest.offsets(request.paramAsBoolean("offsets", termVectorsRequest.offsets())); termVectorsRequest.positions(request.paramAsBoolean("positions", termVectorsRequest.positions())); termVectorsRequest.payloads(request.paramAsBoolean("payloads", termVectorsRequest.payloads())); termVectorsRequest.routing(request.param("routing")); termVectorsRequest.realtime(request.paramAsBoolean("realtime", null)); termVectorsRequest.version(RestActions.parseVersion(request, termVectorsRequest.version())); termVectorsRequest.versionType(VersionType.fromString(request.param("version_type"), termVectorsRequest.versionType())); termVectorsRequest.parent(request.param("parent")); termVectorsRequest.preference(request.param("preference")); termVectorsRequest.termStatistics(request.paramAsBoolean("termStatistics", termVectorsRequest.termStatistics())); termVectorsRequest.termStatistics(request.paramAsBoolean("term_statistics", termVectorsRequest.termStatistics())); termVectorsRequest.fieldStatistics(request.paramAsBoolean("fieldStatistics", termVectorsRequest.fieldStatistics())); termVectorsRequest.fieldStatistics(request.paramAsBoolean("field_statistics", termVectorsRequest.fieldStatistics())); termVectorsRequest.dfs(request.paramAsBoolean("dfs", termVectorsRequest.dfs())); }