Not able to benchmark Dgraph with Neo4j


(sai ram) #1

I am following this(https://blog.dgraph.io/post/benchmark-neo4j/) blog to benchmark Dgraph with Neo4j.

As mentioned I am trying to load equivalent data to Neo4j as well as Dgraph.(From here: https://github.com/dgraph-io/benchmarks/tree/master/data/neo4j)

I was able to load CSV data to Neo4j but I have some issue with Dgraph data and schema.

I tried this command to load data to Dgraph.(As mentioned in the blog)

dgraph live -f ./output.rdf -s ./goldendata.schema -a localhost:9080

Output:

[Decoder]: Using assembly version of decoder
I1009 17:59:38.489198 15565 init.go:98]

Dgraph version : v1.1.0
Dgraph SHA-256 : 98db2956f6dd8b7b9b88e02962d2036845b057fe5fe953190eaafac0a83dfcce
Commit SHA-1 : ef7cdb28
Commit timestamp : 2019-09-04 00:12:51 -0700
Branch : HEAD
Go version : go1.12.7

Licensed variously under the Apache Public License 2.0 and Dgraph Community License.
Copyright 2015-2018 Dgraph Labs, Inc.

Running transaction with dgraph endpoint: localhost:9080

Processing schema file “./goldendata.schema”
Processed schema file “./goldendata.schema”

Found 1 data file(s) to process
Processing data file “./output.rdf”
[17:59:44+0530] Elapsed: 05s Txns: 338 N-Quads: 338000 N-Quads/s [last 5s]: 67600 Aborts: 0
Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2640710 attr:“type.object.name” value:“The Prophet Mimi” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2799806 attr:“type.object.name” value:“Rasheed Karapuzha” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2640202 attr:“type.object.name” value:“Alberto Ancilotto” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2652629 attr:“type.object.name” value:“Patrice Bauduinet” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2652832 attr:“type.object.name” value:“Caserta Palace Dream” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2852884 attr:“type.object.name” value:“Jin Woo” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2836332 attr:“type.object.name” value:“Lion Jagapathi Rao” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2723928 attr:“type.object.name” value:“David Sabal” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2871646 attr:“type.object.name” value:“Slide” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2767290 attr:“type.object.name” value:“Patrick Ryan Sims” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2728456 attr:“type.object.name” value:“Jail Breakers” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2957152 attr:“type.object.name” value:“Fasele” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2767920 attr:“type.object.name” value:“Oliver Lukacs” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2727581 attr:“type.object.name” value:“Michele Fleming” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2930006 attr:“type.object.name” value:“La Gran tentaci\303\263n” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2733942 attr:“type.object.name” value:“Katya Rinaldi” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2697304 attr:“type.object.name” value:“S. R. Raja” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2652629 attr:“type.object.name” value:“Patrice Bauduinet” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2861600 attr:“type.object.name” value:“Laurence Pears” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2755453 attr:“type.object.name” value:“Sadagara” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2727581 attr:“type.object.name” value:“Michele Fleming” lang:“en” ] s.Code Unknown

Error while mutating: Attr: [type.object.name] should have @lang directive in schema to mutate edge: [entity:2868074 attr:“type.object.name” value:“Kate Herron” lang:“en” ] s.Code Unknown

The process is still running for more than an hour and ultimately I had to quit it. Any solutions???


(Michel Conrado) #2

Hum, this is 3y old code. Hard to tell.

@pawan would you mind to check it?


(sai ram) #3

Any update on this topic??


(Pawan Rawal) #4

Hey @sairam

I am not sure where you got the output.rdf.gz from. Could you try loading the neo.rdf.gz instead?

Also please use the following schema for loading.

type.object.name: string @index(term) @lang .
film.film.initial_release_date: datetime @index(year) .

The query_test.go should also be modified a bit as things have changed with Dgraph and we don’t support querying directly by an xid anymore. We don’t have the bandwidth of working on this right now but can do this at a later point.