Skip to content

Commit 7eb11f9

Browse files
committed
fix directed/undirected check in coordinator
Signed-off-by: Lei Wang <[email protected]>
1 parent a66aa55 commit 7eb11f9

File tree

5 files changed

+43
-40
lines changed

5 files changed

+43
-40
lines changed

apps/rdbms/insert_db_txn.py

Lines changed: 39 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -455,79 +455,81 @@ def process_forum(line):
455455
total_timer = Timer()
456456
total_timer.start()
457457

458-
insert_vertices("01", "/organisation_0_0.csv", "organisation", process_organisation)
458+
if True:
459+
insert_vertices("01", "/organisation_0_0.csv", "organisation", process_organisation)
459460

460-
insert_vertices("02", "/place_0_0.csv", "place", process_place)
461+
insert_vertices("02", "/place_0_0.csv", "place", process_place)
461462

462-
insert_vertices("03", "/tag_0_0.csv", "tag", process_tag)
463+
insert_vertices("03", "/tag_0_0.csv", "tag", process_tag)
463464

464-
insert_vertices("04", "/tagclass_0_0.csv", "tagclass", process_tagclass)
465+
insert_vertices("04", "/tagclass_0_0.csv", "tagclass", process_tagclass)
465466

466-
insert_vertices("05", "/person_0_0.csv", "person", process_person)
467+
insert_vertices("05", "/person_0_0.csv", "person", process_person)
467468

468-
insert_vertices("06", "/comment_0_0.csv", "comment", process_comment)
469+
insert_vertices("06", "/comment_0_0.csv", "comment", process_comment)
469470

470-
insert_vertices("07", "/post_0_0.csv", "post", process_post)
471+
insert_vertices("07", "/post_0_0.csv", "post", process_post)
471472

472-
insert_vertices("08", "/forum_0_0.csv", "forum", process_forum)
473+
insert_vertices("08", "/forum_0_0.csv", "forum", process_forum)
473474

474-
for process in vertex_process:
475-
process.join()
475+
for process in vertex_process:
476+
process.join()
476477

477-
total_timer.end()
478-
print("Load vertex time: {:.2f} {}".format(total_timer.total(), total_timer.unit()))
478+
total_timer.end()
479+
print("Load vertex time: {:.2f} {}".format(total_timer.total(), total_timer.unit()))
479480

480-
# insert edge tables without additional properties
481+
# insert edge tables without additional properties
481482

482483

483-
insert_simple_edges("09", "/organisation_isLocatedIn_place_0_0.csv", "org_islocationin")
484+
insert_simple_edges("09", "/organisation_isLocatedIn_place_0_0.csv", "org_islocationin")
484485

485-
insert_simple_edges("10", "/place_isPartOf_place_0_0.csv", "ispartof")
486+
insert_simple_edges("10", "/place_isPartOf_place_0_0.csv", "ispartof")
486487

487-
insert_simple_edges("11", "/tagclass_isSubclassOf_tagclass_0_0.csv", "issubclassof")
488+
insert_simple_edges("11", "/tagclass_isSubclassOf_tagclass_0_0.csv", "issubclassof")
488489

489-
insert_simple_edges("12", "/tag_hasType_tagclass_0_0.csv", "hastype")
490+
insert_simple_edges("12", "/tag_hasType_tagclass_0_0.csv", "hastype")
490491

491-
insert_simple_edges("13", "/comment_hasCreator_person_0_0.csv", "comment_hascreator")
492+
insert_simple_edges("13", "/comment_hasCreator_person_0_0.csv", "comment_hascreator")
492493

493-
insert_simple_edges("14", "/comment_hasTag_tag_0_0.csv", "comment_hastag")
494+
insert_simple_edges("14", "/comment_hasTag_tag_0_0.csv", "comment_hastag")
494495

495-
insert_simple_edges("15", "/comment_isLocatedIn_place_0_0.csv", "comment_islocationin")
496+
insert_simple_edges("15", "/comment_isLocatedIn_place_0_0.csv", "comment_islocationin")
496497

497-
insert_simple_edges("16", "/comment_replyOf_comment_0_0.csv", "replyof_comment")
498+
insert_simple_edges("16", "/comment_replyOf_comment_0_0.csv", "replyof_comment")
498499

499-
insert_simple_edges("17", "/comment_replyOf_post_0_0.csv", "replyof_post")
500+
insert_simple_edges("17", "/comment_replyOf_post_0_0.csv", "replyof_post")
500501

501-
insert_simple_edges("18", "/post_hasCreator_person_0_0.csv", "post_hascreator")
502+
insert_simple_edges("18", "/post_hasCreator_person_0_0.csv", "post_hascreator")
502503

503-
insert_simple_edges("19", "/post_hasTag_tag_0_0.csv", "post_hastag")
504+
insert_simple_edges("19", "/post_hasTag_tag_0_0.csv", "post_hastag")
504505

505-
insert_simple_edges("20", "/post_isLocatedIn_place_0_0.csv", "post_islocationin")
506+
insert_simple_edges("20", "/post_isLocatedIn_place_0_0.csv", "post_islocationin")
506507

507-
insert_simple_edges("21", "/forum_containerOf_post_0_0.csv", "forum_containerof")
508+
insert_simple_edges("21", "/forum_containerOf_post_0_0.csv", "forum_containerof")
508509

509-
insert_simple_edges("22", "/forum_hasModerator_person_0_0.csv", "forum_hasmoderator")
510+
insert_simple_edges("22", "/forum_hasModerator_person_0_0.csv", "forum_hasmoderator")
510511

511-
insert_simple_edges("23", "/forum_hasTag_tag_0_0.csv", "forum_hastag")
512+
insert_simple_edges("23", "/forum_hasTag_tag_0_0.csv", "forum_hastag")
512513

513-
insert_simple_edges("24", "/person_hasInterest_tag_0_0.csv", "person_hasinterest")
514+
if True:
515+
insert_simple_edges("24", "/person_hasInterest_tag_0_0.csv", "person_hasinterest")
514516

515-
insert_simple_edges("25", "/person_isLocatedIn_place_0_0.csv", "person_islocationin")
517+
insert_simple_edges("25", "/person_isLocatedIn_place_0_0.csv", "person_islocationin")
516518

517-
# insert edge tables with additional properties
519+
# insert edge tables with additional properties
518520

519521

520-
insert_prop_edges("26", "/forum_hasMember_person_0_0.csv", "forum_hasmember")
522+
insert_prop_edges("26", "/forum_hasMember_person_0_0.csv", "forum_hasmember")
521523

522-
insert_prop_edges("27", "/person_knows_person_0_0.csv", "knows")
524+
insert_prop_edges("27", "/person_knows_person_0_0.csv", "knows")
523525

524-
insert_prop_edges("28", "/person_likes_comment_0_0.csv", "likes_comment")
526+
insert_prop_edges("28", "/person_likes_comment_0_0.csv", "likes_comment")
525527

526-
insert_prop_edges("29", "/person_likes_post_0_0.csv", "likes_post")
528+
insert_prop_edges("29", "/person_likes_post_0_0.csv", "likes_post")
527529

528-
insert_prop_edges("30", "/person_studyAt_organisation_0_0.csv", "studyat")
530+
insert_prop_edges("30", "/person_studyAt_organisation_0_0.csv", "studyat")
529531

530-
insert_prop_edges("31", "/person_workAt_organisation_0_0.csv", "workat")
532+
insert_prop_edges("31", "/person_workAt_organisation_0_0.csv", "workat")
531533

532534
for process in edge_process:
533535
process.join()

coordinator/flex/server/controllers/deployment_controller.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def get_deployment_info(): # noqa: E501
2626
result_dict["creation_time"] = f.read()
2727
result_dict["instance_name"] = "gart"
2828
result_dict["frontend"] = "Cypher/Gremlin"
29-
result_dict["engine"] = "Gaia"
29+
result_dict["engine"] = "gart"
3030
result_dict["storage"] = "MutableCSR"
3131
result_dict["version"] = "0.1.0"
3232
return (RunningDeploymentInfo.from_dict(result_dict), 200)

coordinator/flex/server/controllers/graph_controller.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ def get_graph_schema():
145145
# FIXME: hard code to MANY_TO_MANY
146146
vertex_type_pair_relation["relation"] = "MANY_TO_MANY"
147147
edge_type_dict["vertex_type_pair_relations"] = [vertex_type_pair_relation]
148-
edge_type_dict["directed"] = not edge_types[idx]["type_pair"].get(
148+
edge_type_dict["directed"] = not edge_types[idx].get(
149149
"undirected", False
150150
)
151151
properties_array = []

coordinator/flex/server/models/running_deployment_info.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ def engine(self, engine: str):
210210
:param engine: The engine of this RunningDeploymentInfo.
211211
:type engine: str
212212
"""
213-
allowed_values = ["Hiactor", "Gaia"] # noqa: E501
213+
allowed_values = ["Hiactor", "Gaia", "gart"] # noqa: E501
214214
if engine not in allowed_values:
215215
raise ValueError(
216216
"Invalid value for `engine` ({0}), must be one of {1}"

coordinator/flex/server/openapi/openapi.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2299,6 +2299,7 @@ components:
22992299
enum:
23002300
- Hiactor
23012301
- Gaia
2302+
- gart
23022303
title: engine
23032304
type: string
23042305
storage:

0 commit comments

Comments
 (0)