gpt4 book ai didi

java - 将 hadoop 连接到 neo4j

转载 作者:可可西里 更新时间:2023-11-01 16:40:34 26 4
gpt4 key购买 nike

我想将一个 GML 文件(Graphml 文件)从 hadoop 导入到 neo4j,为此我需要在 hadoop 和 neo4j 之间建立连接,我检查了 neo4j 站点但没有找到任何东西:https://neo4j.com/developer/apache-hadoop/ 这就是他们所说的 hadoop 和 neo4j 之间的连接:

In the past there were some approaches that used Hadoop to quickly generate `Neo4j datastores directly. While this approach is performant, it is also tightly coupled to the store-format of a certain Neo4j version as it has to duplicate the functionality of writing to split-up store-files. With the parallel neo4j-import tool and APIs introduced in Neo4j 2.2, such a solution is no longer needed. The import facilities scale across a large number of CPUs to maximize import performance.

谁能解释一下这是什么意思?谢谢你

最佳答案

也许我不明白你到底想完成什么,但如果你有 GraphML 文件,你不需要连接到 hadoop,只需将文件复制到 Neo4j 实例或通过网络提供它。

通过使用 apoc.import.graphml procedure 可以在 Neo4j 中导入 GraphML .例如:

CALL apoc.import.graphml("graph.gml", {batchSize: 10000, readLabels: true, storeNodeIds: false, defaultRelationshipType:"RELATED"};

关于java - 将 hadoop 连接到 neo4j,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41618936/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com