dgraph
dgraph copied to clipboard
Server crash when gRPC call has schema update without tokenizer
The dGraph server crashes when I invoke a gRPC call with a mutation to add a few NQuads:
Schema.SchemaUpdate schemaUpdate = Schema.SchemaUpdate.newBuilder()
.setDirective(Schema.SchemaUpdate.Directive.INDEX)
.setPredicate("view")
.build();
Graphresponse.Mutation mutation = Graphresponse.Mutation.newBuilder()
.addSchema(schemaUpdate)
.addAllSet(quads)
.build();
Graphresponse.Request request = Graphresponse.Request.newBuilder()
.setMutation(mutation)
.build();
client.run(request);
The server's console output after running it:
2017/06/05 00:08:51 error.go:76: No default tokenizer set for type 0
I reckon this isn't normal behaviour, even if such a request is invalid, the server should be resillient my tomfoolery
A fix has been merged to master and release/v0.7.7.