ETL returns error "Cannot check the existance of a database in a remote server."

277 views
Skip to first unread message

Tailai Wen

unread,
May 12, 2015, 10:41:20 AM5/12/15
to orient-...@googlegroups.com
I'm trying to use ETL to upload data to the local server, but I ran into this error as follow
"OrientDB etl v.2.0.5 (build @BUILD@) www.orientechnologies.com
Exception in thread "main" com.orientechnologies.orient.core.exception.OConfigurationException: Error on creating ETL processor
        at com.orientechnologies.orient.etl.OETLProcessor.parse(OETLProcessor.java:278)
        at com.orientechnologies.orient.etl.OETLProcessor.parse(OETLProcessor.java:188)
        at com.orientechnologies.orient.etl.OETLProcessor.main(OETLProcessor.java:163)
Caused by: java.lang.UnsupportedOperationException: Cannot check the existance of a database in a remote server. Please use the console or the OServerAdmin class.
        at com.orientechnologies.orient.client.remote.OStorageRemote.exists(OStorageRemote.java:274)
        at com.orientechnologies.orient.client.remote.OStorageRemoteThread.exists(OStorageRemoteThread.java:177)
        at com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.exists(ODatabaseDocumentTx.java:1050)
        at com.tinkerpop.blueprints.impls.orient.OrientGraphFactory.exists(OrientGraphFactory.java:145)
        at com.orientechnologies.orient.etl.loader.OOrientDBLoader.configure(OOrientDBLoader.java:265)
        at com.orientechnologies.orient.etl.OETLProcessor.configureComponent(OETLProcessor.java:494)
        at com.orientechnologies.orient.etl.OETLProcessor.parse(OETLProcessor.java:251)
        ... 2 more"

My config json looks as follows
{
  "config": {
    "log": "debug"
  },
  "source" : {
    "file": { "path": "C:\orientdb-community-2.0.5\bin\database.json" }
  },
  "extractor" : {
    "json": {}
  },
  "transformers" : [
    { "merge": { "joinFieldName": "id", "lookup": "Account.id" } },
    { "vertex": { "class": "Account"} },
    { "edge": {
      "class": "Friend",
      "joinFieldName": "friends",
      "lookup": "Account.id",
      "unresolvedLinkAction": "CREATE"
    } },
    { "edge": {
      "class": "Enemy",
      "joinFieldName": "enemies",
      "lookup": "Account.id",
      "unresolvedLinkAction": "CREATE"
    } }
  ],
  "loader" : {
    "orientdb": {
      "dbURL": "remote:local/myExample",
      "dbUser": "admin",
      "dbPassword": "admin",
      "dbAutoDropIfExists": true,
      "dbAutoCreate": true,
      "standardElementConstraints": false,
      "tx": false,
      "wal": false,
      "batchCommit": 1000,
      "dbType": "graph",
      "classes": [{"name": "Account", "extends":"V"}, {"name": "Friend", "extends":"E"}, {"name": 'Enemy', "extends":"E"}],
      "indexes": [{"class":"Account", "fields":["id:integer"], "type":"UNIQUE_HASH_INDEX" }]
    }
  }
}

Does anyone know what I missed here?

Thanks a lot!


Luca Garulli

unread,
May 12, 2015, 10:45:31 AM5/12/15
to orient-...@googlegroups.com
Set dbAutoDropIfExists: false.

Best Regards,

Luca Garulli
CEO at Orient Technologies LTD
the Company behind OrientDB




--

---
You received this message because you are subscribed to the Google Groups "OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to orient-databa...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Tailai Wen

unread,
May 12, 2015, 10:59:50 AM5/12/15
to orient-...@googlegroups.com
It works! Thank you Luca.

I didn't find the explanation of dbAutoDropIfExists in the documentation. Can you please explain what it does there?

Thank you!

Luca Garulli

unread,
May 12, 2015, 11:37:36 AM5/12/15
to orient-...@googlegroups.com
Hi,
dbAutoDropIfExists means "db Auto Drop If Exists", so namely drop the database if exists.

Lvc@


Best Regards,

Luca Garulli
CEO at Orient Technologies LTD
the Company behind OrientDB


Reply all
Reply to author
Forward
0 new messages