diff --git a/apps/rdbms/insert_db_txn.py b/apps/rdbms/insert_db_txn.py index a352b26..2f173e0 100755 --- a/apps/rdbms/insert_db_txn.py +++ b/apps/rdbms/insert_db_txn.py @@ -455,79 +455,81 @@ def process_forum(line): total_timer = Timer() total_timer.start() -insert_vertices("01", "/organisation_0_0.csv", "organisation", process_organisation) +if True: + insert_vertices("01", "/organisation_0_0.csv", "organisation", process_organisation) -insert_vertices("02", "/place_0_0.csv", "place", process_place) + insert_vertices("02", "/place_0_0.csv", "place", process_place) -insert_vertices("03", "/tag_0_0.csv", "tag", process_tag) + insert_vertices("03", "/tag_0_0.csv", "tag", process_tag) -insert_vertices("04", "/tagclass_0_0.csv", "tagclass", process_tagclass) + insert_vertices("04", "/tagclass_0_0.csv", "tagclass", process_tagclass) -insert_vertices("05", "/person_0_0.csv", "person", process_person) + insert_vertices("05", "/person_0_0.csv", "person", process_person) -insert_vertices("06", "/comment_0_0.csv", "comment", process_comment) + insert_vertices("06", "/comment_0_0.csv", "comment", process_comment) -insert_vertices("07", "/post_0_0.csv", "post", process_post) + insert_vertices("07", "/post_0_0.csv", "post", process_post) -insert_vertices("08", "/forum_0_0.csv", "forum", process_forum) + insert_vertices("08", "/forum_0_0.csv", "forum", process_forum) -for process in vertex_process: - process.join() + for process in vertex_process: + process.join() -total_timer.end() -print("Load vertex time: {:.2f} {}".format(total_timer.total(), total_timer.unit())) + total_timer.end() + print("Load vertex time: {:.2f} {}".format(total_timer.total(), total_timer.unit())) -# insert edge tables without additional properties + # insert edge tables without additional properties -insert_simple_edges("09", "/organisation_isLocatedIn_place_0_0.csv", "org_islocationin") + insert_simple_edges("09", "/organisation_isLocatedIn_place_0_0.csv", "org_islocationin") -insert_simple_edges("10", "/place_isPartOf_place_0_0.csv", "ispartof") + insert_simple_edges("10", "/place_isPartOf_place_0_0.csv", "ispartof") -insert_simple_edges("11", "/tagclass_isSubclassOf_tagclass_0_0.csv", "issubclassof") + insert_simple_edges("11", "/tagclass_isSubclassOf_tagclass_0_0.csv", "issubclassof") -insert_simple_edges("12", "/tag_hasType_tagclass_0_0.csv", "hastype") + insert_simple_edges("12", "/tag_hasType_tagclass_0_0.csv", "hastype") -insert_simple_edges("13", "/comment_hasCreator_person_0_0.csv", "comment_hascreator") + insert_simple_edges("13", "/comment_hasCreator_person_0_0.csv", "comment_hascreator") -insert_simple_edges("14", "/comment_hasTag_tag_0_0.csv", "comment_hastag") + insert_simple_edges("14", "/comment_hasTag_tag_0_0.csv", "comment_hastag") -insert_simple_edges("15", "/comment_isLocatedIn_place_0_0.csv", "comment_islocationin") + insert_simple_edges("15", "/comment_isLocatedIn_place_0_0.csv", "comment_islocationin") -insert_simple_edges("16", "/comment_replyOf_comment_0_0.csv", "replyof_comment") + insert_simple_edges("16", "/comment_replyOf_comment_0_0.csv", "replyof_comment") -insert_simple_edges("17", "/comment_replyOf_post_0_0.csv", "replyof_post") + insert_simple_edges("17", "/comment_replyOf_post_0_0.csv", "replyof_post") -insert_simple_edges("18", "/post_hasCreator_person_0_0.csv", "post_hascreator") + insert_simple_edges("18", "/post_hasCreator_person_0_0.csv", "post_hascreator") -insert_simple_edges("19", "/post_hasTag_tag_0_0.csv", "post_hastag") + insert_simple_edges("19", "/post_hasTag_tag_0_0.csv", "post_hastag") -insert_simple_edges("20", "/post_isLocatedIn_place_0_0.csv", "post_islocationin") + insert_simple_edges("20", "/post_isLocatedIn_place_0_0.csv", "post_islocationin") -insert_simple_edges("21", "/forum_containerOf_post_0_0.csv", "forum_containerof") + insert_simple_edges("21", "/forum_containerOf_post_0_0.csv", "forum_containerof") -insert_simple_edges("22", "/forum_hasModerator_person_0_0.csv", "forum_hasmoderator") + insert_simple_edges("22", "/forum_hasModerator_person_0_0.csv", "forum_hasmoderator") -insert_simple_edges("23", "/forum_hasTag_tag_0_0.csv", "forum_hastag") + insert_simple_edges("23", "/forum_hasTag_tag_0_0.csv", "forum_hastag") -insert_simple_edges("24", "/person_hasInterest_tag_0_0.csv", "person_hasinterest") +if True: + insert_simple_edges("24", "/person_hasInterest_tag_0_0.csv", "person_hasinterest") -insert_simple_edges("25", "/person_isLocatedIn_place_0_0.csv", "person_islocationin") + insert_simple_edges("25", "/person_isLocatedIn_place_0_0.csv", "person_islocationin") -# insert edge tables with additional properties + # insert edge tables with additional properties -insert_prop_edges("26", "/forum_hasMember_person_0_0.csv", "forum_hasmember") + insert_prop_edges("26", "/forum_hasMember_person_0_0.csv", "forum_hasmember") -insert_prop_edges("27", "/person_knows_person_0_0.csv", "knows") + insert_prop_edges("27", "/person_knows_person_0_0.csv", "knows") -insert_prop_edges("28", "/person_likes_comment_0_0.csv", "likes_comment") + insert_prop_edges("28", "/person_likes_comment_0_0.csv", "likes_comment") -insert_prop_edges("29", "/person_likes_post_0_0.csv", "likes_post") + insert_prop_edges("29", "/person_likes_post_0_0.csv", "likes_post") -insert_prop_edges("30", "/person_studyAt_organisation_0_0.csv", "studyat") + insert_prop_edges("30", "/person_studyAt_organisation_0_0.csv", "studyat") -insert_prop_edges("31", "/person_workAt_organisation_0_0.csv", "workat") + insert_prop_edges("31", "/person_workAt_organisation_0_0.csv", "workat") for process in edge_process: process.join() diff --git a/coordinator/flex/server/controllers/deployment_controller.py b/coordinator/flex/server/controllers/deployment_controller.py index ead2939..f477cb4 100644 --- a/coordinator/flex/server/controllers/deployment_controller.py +++ b/coordinator/flex/server/controllers/deployment_controller.py @@ -26,7 +26,7 @@ def get_deployment_info(): # noqa: E501 result_dict["creation_time"] = f.read() result_dict["instance_name"] = "gart" result_dict["frontend"] = "Cypher/Gremlin" - result_dict["engine"] = "Gaia" + result_dict["engine"] = "gart" result_dict["storage"] = "MutableCSR" result_dict["version"] = "0.1.0" return (RunningDeploymentInfo.from_dict(result_dict), 200) diff --git a/coordinator/flex/server/controllers/graph_controller.py b/coordinator/flex/server/controllers/graph_controller.py index 66e416b..becd511 100644 --- a/coordinator/flex/server/controllers/graph_controller.py +++ b/coordinator/flex/server/controllers/graph_controller.py @@ -145,7 +145,7 @@ def get_graph_schema(): # FIXME: hard code to MANY_TO_MANY vertex_type_pair_relation["relation"] = "MANY_TO_MANY" edge_type_dict["vertex_type_pair_relations"] = [vertex_type_pair_relation] - edge_type_dict["directed"] = not edge_types[idx]["type_pair"].get( + edge_type_dict["directed"] = not edge_types[idx].get( "undirected", False ) properties_array = [] diff --git a/coordinator/flex/server/models/running_deployment_info.py b/coordinator/flex/server/models/running_deployment_info.py index aa8958a..e3e16e0 100644 --- a/coordinator/flex/server/models/running_deployment_info.py +++ b/coordinator/flex/server/models/running_deployment_info.py @@ -210,7 +210,7 @@ def engine(self, engine: str): :param engine: The engine of this RunningDeploymentInfo. :type engine: str """ - allowed_values = ["Hiactor", "Gaia"] # noqa: E501 + allowed_values = ["Hiactor", "Gaia", "gart"] # noqa: E501 if engine not in allowed_values: raise ValueError( "Invalid value for `engine` ({0}), must be one of {1}" diff --git a/coordinator/flex/server/openapi/openapi.yaml b/coordinator/flex/server/openapi/openapi.yaml index a4408f2..de42871 100644 --- a/coordinator/flex/server/openapi/openapi.yaml +++ b/coordinator/flex/server/openapi/openapi.yaml @@ -2299,6 +2299,7 @@ components: enum: - Hiactor - Gaia + - gart title: engine type: string storage: