From 15b8ed0618f62aded6043237f1d2ce2814fa05fe Mon Sep 17 00:00:00 2001 From: wenhaocs <19355821+wenhaocs@users.noreply.github.com> Date: Sun, 24 Oct 2021 13:28:08 +0000 Subject: [PATCH 1/5] master --- nebula_bench/scenarios/go.py | 8 ++++++++ templates/nebula-import-vid-int.yaml.j2 | 2 +- templates/nebula-import-vid-string.yaml.j2 | 2 +- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/nebula_bench/scenarios/go.py b/nebula_bench/scenarios/go.py index d0da279..fb554e1 100644 --- a/nebula_bench/scenarios/go.py +++ b/nebula_bench/scenarios/go.py @@ -22,3 +22,11 @@ class Go2Step(BaseGoScenario): class Go3Step(BaseGoScenario): abstract = False nGQL = "GO 3 STEP FROM {} OVER KNOWS" + +class Go5Step(BaseGoScenario): + abstract = False + nGQL = "GO 5 STEP FROM {} OVER KNOWS" + +class Go10Step(BaseGoScenario): + abstract = False + nGQL = "GO 10 STEP FROM {} OVER KNOWS" diff --git a/templates/nebula-import-vid-int.yaml.j2 b/templates/nebula-import-vid-int.yaml.j2 index 651a8ad..b34fcd3 100644 --- a/templates/nebula-import-vid-int.yaml.j2 +++ b/templates/nebula-import-vid-int.yaml.j2 @@ -12,7 +12,7 @@ clientSettings: address: {{ address }} postStart: commands: | - CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 3, vid_type = int64); + CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 1, vid_type = int64); USE {{ space }}; {% for vertex in vertex_set -%} CREATE TAG IF NOT EXISTS `{{ vertex.name }}`( diff --git a/templates/nebula-import-vid-string.yaml.j2 b/templates/nebula-import-vid-string.yaml.j2 index 02a8aea..befc8fd 100644 --- a/templates/nebula-import-vid-string.yaml.j2 +++ b/templates/nebula-import-vid-string.yaml.j2 @@ -12,7 +12,7 @@ clientSettings: address: {{ address }} postStart: commands: | - CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 3, vid_type = fixed_string(20)); + CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 1, vid_type = fixed_string(20)); USE {{ space }}; {% for vertex in vertex_set -%} CREATE TAG IF NOT EXISTS `{{ vertex.name }}`( From 7c03cd3ed2e5e9f51a68c18de33dbdfc8b7a9ad7 Mon Sep 17 00:00:00 2001 From: Hao Wen <19355821+wenhaocs@users.noreply.github.com> Date: Tue, 19 Apr 2022 10:20:13 +0800 Subject: [PATCH 2/5] yield something find path statment --- nebula_bench/scenarios/find_path.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nebula_bench/scenarios/find_path.py b/nebula_bench/scenarios/find_path.py index 61ff675..dd1c9f8 100644 --- a/nebula_bench/scenarios/find_path.py +++ b/nebula_bench/scenarios/find_path.py @@ -4,6 +4,6 @@ class FindShortestPath(BaseScenario): abstract = False - nGQL = "FIND SHORTEST PATH FROM {} TO {} OVER *" + nGQL = "FIND SHORTEST PATH FROM {} TO {} OVER * YIELD path as p" csv_path = "social_network/dynamic/person_knows_person.csv" csv_index = [0, 1] From 8219390b03ffeacc7dec4d1866aada2e8a54dacf Mon Sep 17 00:00:00 2001 From: Hao Wen <19355821+wenhaocs@users.noreply.github.com> Date: Tue, 19 Apr 2022 10:22:27 +0800 Subject: [PATCH 3/5] fix --- templates/nebula-import-vid-int.yaml.j2 | 2 +- templates/nebula-import-vid-string.yaml.j2 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/nebula-import-vid-int.yaml.j2 b/templates/nebula-import-vid-int.yaml.j2 index 1439823..db7fc46 100644 --- a/templates/nebula-import-vid-int.yaml.j2 +++ b/templates/nebula-import-vid-int.yaml.j2 @@ -12,7 +12,7 @@ clientSettings: address: {{ address }} postStart: commands: | - CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 1, vid_type = int64); + CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 3, vid_type = int64); USE {{ space }}; {% for vertex in vertex_set -%} CREATE TAG IF NOT EXISTS `{{ vertex.name }}`( diff --git a/templates/nebula-import-vid-string.yaml.j2 b/templates/nebula-import-vid-string.yaml.j2 index 617d8f9..6eb685b 100644 --- a/templates/nebula-import-vid-string.yaml.j2 +++ b/templates/nebula-import-vid-string.yaml.j2 @@ -12,7 +12,7 @@ clientSettings: address: {{ address }} postStart: commands: | - CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 1, vid_type = fixed_string(32)); + CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 3, vid_type = fixed_string(32)); USE {{ space }}; {% for vertex in vertex_set -%} CREATE TAG IF NOT EXISTS `{{ vertex.name }}`( From 29d90f9ab066b6d20261cc036b83c0dd9cae2efe Mon Sep 17 00:00:00 2001 From: Hao Wen <19355821+wenhaocs@users.noreply.github.com> Date: Tue, 19 Apr 2022 10:24:18 +0800 Subject: [PATCH 4/5] lint --- scripts/generate-data.sh | 1 - templates/nebula-import-vid-int.yaml.j2 | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/generate-data.sh b/scripts/generate-data.sh index 2fa42ee..d2aabe4 100755 --- a/scripts/generate-data.sh +++ b/scripts/generate-data.sh @@ -64,4 +64,3 @@ rm -rf ${DATA_DIR}/test_data && \ mv test_data ${DATA_DIR}/. echo "Finish" - diff --git a/templates/nebula-import-vid-int.yaml.j2 b/templates/nebula-import-vid-int.yaml.j2 index db7fc46..a38d9de 100644 --- a/templates/nebula-import-vid-int.yaml.j2 +++ b/templates/nebula-import-vid-int.yaml.j2 @@ -12,7 +12,7 @@ clientSettings: address: {{ address }} postStart: commands: | - CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 3, vid_type = int64); + CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 3, vid_type = int64); USE {{ space }}; {% for vertex in vertex_set -%} CREATE TAG IF NOT EXISTS `{{ vertex.name }}`( From 39a36fe7bb471c4138d18b54fda047c940a9e698 Mon Sep 17 00:00:00 2001 From: Hao Wen <19355821+wenhaocs@users.noreply.github.com> Date: Tue, 19 Apr 2022 10:47:11 +0800 Subject: [PATCH 5/5] lint --- templates/nebula-import-vid-int.yaml.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/nebula-import-vid-int.yaml.j2 b/templates/nebula-import-vid-int.yaml.j2 index a38d9de..b5be328 100644 --- a/templates/nebula-import-vid-int.yaml.j2 +++ b/templates/nebula-import-vid-int.yaml.j2 @@ -12,7 +12,7 @@ clientSettings: address: {{ address }} postStart: commands: | - CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 3, vid_type = int64); + CREATE SPACE IF NOT EXISTS {{ space }}(PARTITION_NUM = 24, REPLICA_FACTOR = 3, vid_type = int64); USE {{ space }}; {% for vertex in vertex_set -%} CREATE TAG IF NOT EXISTS `{{ vertex.name }}`(