2012-08-06 54 views
0

我们通过.Net Nest客户端使用ES在源文档属性中提高查询效率

目录文件索引看起来像这样:

[ElasticType(
     Name = "tag", 
     DateDetection = true, 
     NumericDetection = true, 
     SearchAnalyzer = "standard", 
     IndexAnalyzer = "standard" 
    )] 
    public class TagIndexDto : AbstractIndexDto 
    { 

     [ElasticProperty(Index = FieldIndexOption.analyzed, OmitNorms = true)] 
     public string Name { get; set; } 
     [ElasticProperty(Index = FieldIndexOption.analyzed, OmitNorms = true)] 
     public string Description { get; set; } 
     [ElasticProperty(AddSortField = true)] 
     public int FollowerCount { get; set; } 
     [ElasticProperty(AddSortField = true)] 
     public int ProductCount { get; set; } 
     [ElasticProperty(AddSortField = true)] 
     public int CatalogCount { get; set; } 
    } 

我想要做的就是给于3个计数(最后3场)的值的特定提升。升压应该是可配置的,这意味着升压的确切值在索引时间是未知的。 这实际上是由lucene支持吗? ES?或者我正在寻找一个不存在的功能?

感谢 罗马

+0

你为什么不查询过程中提高这些领域做些什么呢? – naresh 2012-08-06 14:18:05

+0

Lucene支持不同级别的提升。请参阅http://lucene.apache.org/core/3_6_0/scoring.html#Score Boosting – naresh 2012-08-06 14:19:24

回答