Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/apache-kafka/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Azure cosmosdb 限制repeat()步骤在azure cosmosdb graph中使用gremlin仅使用32个循环。可能的解决方法_Azure Cosmosdb_Azure Cosmosdb Gremlinapi - Fatal编程技术网

Azure cosmosdb 限制repeat()步骤在azure cosmosdb graph中使用gremlin仅使用32个循环。可能的解决方法

Azure cosmosdb 限制repeat()步骤在azure cosmosdb graph中使用gremlin仅使用32个循环。可能的解决方法,azure-cosmosdb,azure-cosmosdb-gremlinapi,Azure Cosmosdb,Azure Cosmosdb Gremlinapi,我现在正在使用Azure Cosmos DB[Gremlin API]来存储层次信息。我正在使用“ParentOf”类型的边维护顶点之间的父子关系 要求:给定已知的父顶点,从该顶点获取所有子顶点[递归派生] 问题:我正在使用以下查询获取所需的边和顶点 获取vertexX层次结构下的所有顶点:g.V().hasLabel('company')。has('CompanyName','vertexX')。emit()。重复(out('ParentOf')。直到(uuu.outE().count())为

我现在正在使用Azure Cosmos DB[Gremlin API]来存储层次信息。我正在使用“ParentOf”类型的边维护顶点之间的父子关系

要求:给定已知的父顶点,从该顶点获取所有子顶点[递归派生]

问题:我正在使用以下查询获取所需的边和顶点

获取vertexX层次结构下的所有顶点:g.V().hasLabel('company')。has('CompanyName','vertexX')。emit()。重复(out('ParentOf')。直到(uuu.outE().count())为(0))

获取vertexX层次结构下的所有边。我们仅获取由关系“ParentOf”定义的边:g.V().hasLabel('company')。has('CompanyName','vertexX')。emit()。重复(out('ParentOf')。直到(uuuu.outE().count().is(0))。outE('ParentOf'))

问题:给定的层次结构中,grand child距离大于32,上述查询将失败,并出现以下错误:g.V().hasLabel('company')。has('CompanyName','SR101')。emit()。repeat(out('ParentOf')。直到(uuu.outE().count().is(0))。value('CompanyName')):脚本评估错误:ActivityId:b1f1fc11-f616-4ea4-8301-8e2eb32711d1异常类型:GraphRuntimeException异常消息:Gremlin查询执行错误:超过重复()步骤上的最大循环数。不能超过32个循环。建议使用times(n)step或loops()条件限制循环数。例如:…直到(hasId(targetId).or().loops().is(n))来源:Microsoft.Azure.Graphs GremlinRequestId:b1f1fc11-f616-4ea4-8301-8e2eb32711d1上下文:graphcompute作用域:graphcomp ExecuteQuery GraphEntropStatusCode:GraphRuntimeError HResult:0x80131500

我尝试过subgraph()步骤是否有用,但徒劳无功,因为cosmosdb限制了可以使用的小精灵步骤


看来这是一个限制。此场景是否有任何已知的最佳做法或解决方法。

我也有相同的问题,无法找到解决此限制的任何解决方案,因此我将此情况报告给Azure支持人员,并将此链接发送给他们。他们说CosmosDB团队成员应该在24-48小时内回复此帖子。希望他们能补充一些澄清。