Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/sqlite/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Gremlin Can';t从janusgraph方案中删除边标签_Gremlin_Gremlin Server_Janusgraph - Fatal编程技术网

Gremlin Can';t从janusgraph方案中删除边标签

Gremlin Can';t从janusgraph方案中删除边标签,gremlin,gremlin-server,janusgraph,Gremlin,Gremlin Server,Janusgraph,我有一个连接到gremlin服务器的gremlin控制台,后端有janusGraph。 我想用多重性重新创建edgeLabel,因此我使用removeEdgeLabel()命令将脚本发送到gremlin服务器,以删除标签“hasNext”: 然后我注释掉行mgmt.getEdgeLabel(“hasNext”).remove()并从makeEdgeLabel(…)行中删除注释符号,以创建具有多重性(ONE2ONE)的新标签: 我得到一个错误: 为键[~T$SchemaName]和值[rt]添加此

我有一个连接到gremlin服务器的gremlin控制台,后端有janusGraph。 我想用多重性重新创建edgeLabel,因此我使用
removeEdgeLabel()
命令将脚本发送到gremlin服务器,以删除标签“hasNext”:

然后我注释掉行
mgmt.getEdgeLabel(“hasNext”).remove()
并从
makeEdgeLabel(…)
行中删除注释符号,以创建具有
多重性(ONE2ONE)
的新标签:

我得到一个错误:

为键[~T$SchemaName]和值[rt]添加此属性▲hasNext]违反了唯一性约束[SystemIndex#~T$SchemaName]


因此,似乎没有从架构中删除标签,但为什么会发生这种情况?

最后,我通过命令删除所有架构/图形内容:

./bin/janusgraph.sh stop
./bin/janusgraph.sh clean
并明确定义用于在gremlin控制台中操作的JanusGraph:

:remote connect tinkerpop.server conf/remote.yaml
==>Configured localhost/10.11.221.123:8182
graph = JanusGraphFactory.open("conf/janusgraph-cassandra-es.properties")
g = graph.traversal()

不确定,你现在需要这个答案,但你能试试这个吗

mgmt.getEdgeLabel('Bad_Name').remove()
之后我不得不关闭图形连接

管理提交()

当我再次检查时,边缘标签不在那里。请让我知道它是否也适合你。我使用的是Janusgraph 0.3.0

:remote connect tinkerpop.server conf/remote.yaml
==>Configured localhost/10.11.221.123:8182
graph = JanusGraphFactory.open("conf/janusgraph-cassandra-es.properties")
g = graph.traversal()
mgmt.getEdgeLabel('Bad_Name').remove()