繁体   English   中英

弹性NEST Automap()

[英]Elastic NEST Automap()

我试图在Elastic Cloud中创建新索引,并试图使用AutoMap功能为我的产品生成映射,我想知道这样做的人能否告诉我这通常需要多长时间?运行了90分钟以上,消耗了我的所有RAM,并且索引尚未出现在Elastic上。

谁能提供任何建议?

var node = new SingleNodeConnectionPool(new Uri("https://elasticcloud:9243"));
var config = new ConnectionSettings(
                    node,
                    new HttpConnection());
var client = new ElasticClient(config);     
client.CreateIndex("sbproducts", i => i
                .Settings(s => s
                .NumberOfShards(2)
                .NumberOfReplicas(0)
                )
                .Mappings(ms => ms
                .Map<Data.Product>(m => m.AutoMap())
                )
                );
.Map<Data.Product>(m => m.AutoMap())

默认情况下,它不能防止循环引用,存在一个将 maxRecursion作为整数的重载。

更新

默认递归为0 ,这意味着它将不会递归为已经看到的类型。 您可以根据您的类型为我们提供的任何其他信息,@ rs82uk将不胜感激

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM