// Specification of EI schema (constrains)
// =======================================

mgmt = graph.openManagement()

// Vertexes
event   = mgmt.makeVertexLabel('event'  ).make()
dataset = mgmt.makeVertexLabel('dataset').make()

// Edges
contains = mgmt.makeEdgeLabel('contains').multiplicity(ONE2MANY).make()

// vertex properties
phoenixKey = mgmt.makePropertyKey('phoenixKey').dataType(String.class).cardinality(Cardinality.SINGLE).make()

// Vertex properties
mgmt.addProperties(event,
                   phoenixKey)
mgmt.addProperties(dataset,
                   phoenixKey)   
                                      
// Edge properties
//mgmt.addProperties(contains, lbl)

// Connections                   
mgmt.addConnection(contains, dataset, event)

mgmt.commit()

mgmt.printSchema()
