Package org.elasticsearch.search.dfs

Examples of org.elasticsearch.search.dfs.AggregatedDfs


            searchService.sendExecuteDfs(node, request, listener);
        }

        @Override
        protected void moveToSecondPhase() {
            final AggregatedDfs dfs = searchPhaseController.aggregateDfs(firstResults);
            final AtomicInteger counter = new AtomicInteger(firstResults.asList().size());
            for (final AtomicArray.Entry<DfsSearchResult> entry : firstResults.asList()) {
                DfsSearchResult dfsResult = entry.value;
                DiscoveryNode node = nodes.get(dfsResult.shardTarget().nodeId());
                QuerySearchRequest querySearchRequest = new QuerySearchRequest(request, dfsResult.id(), dfs);
View Full Code Here


            } else {
                dfsResults.set(i, ((ShardDfsOnlyResponse) shardResponse).getDfsSearchResult());
                successfulShards++;
            }
        }
        AggregatedDfs dfs = searchPhaseController.aggregateDfs(dfsResults);
        return new DfsOnlyResponse(dfs, shardsResponses.length(), successfulShards, failedShards, shardFailures, buildTookInMillis(request));
    }
View Full Code Here

        final TermVectorResponse termVectorResponse = new TermVectorResponse(concreteIndex, request.type(), request.id());

        final Term uidTerm = new Term(UidFieldMapper.NAME, Uid.createUidAsBytes(request.type(), request.id()));
        Engine.GetResult get = indexShard.get(new Engine.Get(request.realtime(), uidTerm));
        boolean docFromTranslog = get.source() != null;
        AggregatedDfs dfs = null;

        /* fetched from translog is treated as an artificial document */
        if (docFromTranslog) {
            request.doc(get.source().source, false);
            termVectorResponse.setDocVersion(get.version());
View Full Code Here

                    }
                }
            }
            aggMaxDoc += lEntry.value.maxDoc();
        }
        return new AggregatedDfs(termStatistics, fieldStatistics, aggMaxDoc);
    }
View Full Code Here

TOP

Related Classes of org.elasticsearch.search.dfs.AggregatedDfs

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.