0

我正在从 AWS Marketplace AMI 运行 OrientDB 2.1.2。我已经使用 ETL 加载了两组顶点。现在我正在尝试使用 ETL 将 Edges 文件加载到 OrientDB 并得到:IllegalArgumentException:目标顶点为空。我查看了网上的文档和其他一些示例,我的 ETL 配置对我来说是正确的。我希望有人可能有一个想法。

我的两个 V 子类是:

作者(authorId、authGivenName、authSurname)和 authorId 上的索引

抽象 (abstractId) 与 abstractId 上的索引

我的 E 子类

已创作 - 没有在其上定义属性或索引

我的边缘文件

(authorId, abstractId) - \t 分隔字段,其中一个标题行带有这些名称

我的 ETL 配置:

{
  "config": { "log":"debug"},
  "source" : { "file": { "path":"/root/poc1_Datasets/authAbstractEdge1.tsv" }},
  "extractor":{ "row":{} },
  "transformers":[
       { "csv":{ "separator": "\t" } },
       { "merge": {
           "joinFieldName": "authorId",
           "lookup":"Author.authorId"
        } },
       { "vertex":{ "class":"Author" } },
       { "edge" : {
           "class": "Authored",
           "joinFieldName": "abstractId",
           "lookup": "Abstract.abstractId",
           "direction": "out"
        }}
  ],
  "loader":{
    "orientdb":{
        "dbURL":"remote:localhost/DataSpine1",
        "dbType":"graph",
        "wal":false,
        "tx":false
   } }
}

当我使用此配置和文件运行 ETL 时,我得到:

OrientDB etl v.2.1.2 (build @BUILD@) www.orientdb.com
BEGIN ETL PROCESSOR
[file] DEBUG Reading from file /root/poc1_Datasets/authAbstractEdge1.tsv
[0:csv] DEBUG Transformer input: authorId   abstractId
[0:csv] DEBUG parsing=authorId  abstractId
[0:csv] DEBUG Transformer output: null

2016-06-09 12:15:04:088 WARNI Transformer [csv] returned null, skip rest of pipeline execution [OETLPipeline][1:csv] DEBUG Transformer input: 9-s2.0-10039026700    2-s2.0-29144536313
[1:csv] DEBUG parsing=9-s2.0-10039026700    2-s2.0-29144536313
[1:csv] DEBUG document={authorId:9-s2.0-10039026700,abstractId:2-s2.0-29144536313}
[1:csv] DEBUG Transformer output: {authorId:9-s2.0-10039026700,abstractId:2-s2.0-29144536313}
[1:merge] DEBUG Transformer input: {authorId:9-s2.0-10039026700,abstractId:2-s2.0-29144536313}
[1:merge] DEBUG joinValue=9-s2.0-10039026700, lookupResult=Author#12:10046021{authorId:9-s2.0-10039026700,authGivenName:M. A.,authSurname:Turovskaya,abstractId:2-s2.0-29144536313} v2
[1:merge] DEBUG merged record Author#12:10046021{authorId:9-s2.0-10039026700,authGivenName:M. A.,authSurname:Turovskaya,abstractId:2-s2.0-29144536313} v2 with found record={authorId:9-s2.0-10039026700,abstractId:2-s2.0-29144536313}
[1:merge] DEBUG Transformer output: Author#12:10046021{authorId:9-s2.0-10039026700,authGivenName:M. A.,authSurname:Turovskaya,abstractId:2-s2.0-29144536313} v2
[1:vertex] DEBUG Transformer input: Author#12:10046021{authorId:9-s2.0-10039026700,authGivenName:M. A.,authSurname:Turovskaya,abstractId:2-s2.0-29144536313} v2
[1:vertex] DEBUG Transformer output: v(Author)[#12:10046021]
[1:edge] DEBUG Transformer input: v(Author)[#12:10046021]
[1:edge] DEBUG joinCurrentValue=2-s2.0-29144536313, lookupResult=Abstract#13:16626366{abstractId:2-s2.0-29144536313} v1
Error in Pipeline execution: java.lang.IllegalArgumentException: destination vertex is null
java.lang.IllegalArgumentException: destination vertex is null
    at com.tinkerpop.blueprints.impls.orient.OrientVertex.addEdge(OrientVertex.java:888)
    at com.tinkerpop.blueprints.impls.orient.OrientVertex.addEdge(OrientVertex.java:832)
    at com.orientechnologies.orient.etl.transformer.OEdgeTransformer.createEdge(OEdgeTransformer.java:188)
    at com.orientechnologies.orient.etl.transformer.OEdgeTransformer.executeTransform(OEdgeTransformer.java:117)
    at com.orientechnologies.orient.etl.transformer.OAbstractTransformer.transform(OAbstractTransformer.java:37)
    at com.orientechnologies.orient.etl.OETLPipeline.execute(OETLPipeline.java:114)
    at com.orientechnologies.orient.etl.OETLProcessor.executeSequentially(OETLProcessor.java:487)
    at com.orientechnologies.orient.etl.OETLProcessor.execute(OETLProcessor.java:291)
    at com.orientechnologies.orient.etl.OETLProcessor.main(OETLProcessor.java:161)
ETL process halted: com.orientechnologies.orient.etl.OETLProcessHaltedException: java.lang.IllegalArgumentException: destination vertex is null

当我查看调试时,似乎 MERGE 成功找到了 Author 顶点,而 EDGE 成功找到了 Abstract Vertex(基于看到输出中的 RID)。我很困惑为什么我会得到例外。在此先感谢您的任何指点。

4

2 回答 2

0

您是否已经尝试过使用新的 etl、teleporter 版本 2.2 是否可以解决这个问题?在这个链接上有关于新的 etl 产品的描述。

于 2016-06-13T08:31:37.643 回答
0

我实际上发现 OrientDB 2.2.2 版中的 ETL 加载器似乎已经解决了这个问题。(注意:2.2.0 版仍然有同样的问题)

于 2016-06-20T13:23:41.390 回答