Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unify gae, python and groot proto into proto directory #3023

Merged
merged 8 commits into from
Jul 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions analytical_engine/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -278,10 +278,10 @@ if(Arrow_FOUND AND Arrow_VERSION VERSION_GREATER 9.0.1)
endif()

# Generate proto
execute_process(COMMAND python3 python/graphscope/proto/proto_generator.py "${PROJECT_SOURCE_DIR}" --cpp
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}/..)
execute_process(COMMAND python3 ../proto/proto_generator.py "${PROJECT_SOURCE_DIR}/proto" --cpp
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR})

file(GLOB PROTO_CPP_FILES "graphscope/proto/*.cc")
file(GLOB PROTO_CPP_FILES "proto/*.cc")
file(GLOB CORE_RPC_SRC_FILES "core/server/*.cc")

# Add targets
Expand Down Expand Up @@ -569,7 +569,7 @@ endif()
install_gsa_headers("${PROJECT_SOURCE_DIR}/apps")
install_gsa_headers("${PROJECT_SOURCE_DIR}/benchmarks")
install_gsa_headers("${PROJECT_SOURCE_DIR}/core")
install_gsa_headers("${PROJECT_SOURCE_DIR}/graphscope")
install_gsa_headers("${PROJECT_SOURCE_DIR}/proto")
install_gsa_app_frames("${PROJECT_SOURCE_DIR}/frame")

install_gsa_dependency_modules("${PROJECT_SOURCE_DIR}/cmake")
Expand Down
4 changes: 2 additions & 2 deletions analytical_engine/core/app/app_invoker.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
#endif
#include "core/config.h"
#include "core/error.h"
#include "graphscope/proto/data_types.pb.h"
#include "graphscope/proto/types.pb.h"
#include "proto/data_types.pb.h"
#include "proto/types.pb.h"

namespace bl = boost::leaf;

Expand Down
2 changes: 1 addition & 1 deletion analytical_engine/core/context/vertex_data_context.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
#include "core/server/rpc_utils.h"
#include "core/utils/mpi_utils.h"
#include "core/utils/transform_utils.h"
#include "graphscope/proto/types.pb.h"
#include "proto/types.pb.h"

#define CONTEXT_TYPE_VERTEX_DATA "vertex_data"
#define CONTEXT_TYPE_LABELED_VERTEX_DATA "labeled_vertex_data"
Expand Down
2 changes: 1 addition & 1 deletion analytical_engine/core/error.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

#include "vineyard/graph/utils/error.h" // IWYU pragma: export

#include "graphscope/proto/error_codes.pb.h" // IWYU pragma: export
#include "proto/error_codes.pb.h" // IWYU pragma: export

namespace gs {

Expand Down
2 changes: 1 addition & 1 deletion analytical_engine/core/fragment/arrow_projected_fragment.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
#include "core/config.h"
#include "core/fragment/arrow_projected_fragment_base.h" // IWYU pragma: export
#include "core/vertex_map/arrow_projected_vertex_map.h"
#include "graphscope/proto/types.pb.h"
#include "proto/types.pb.h"

namespace arrow {
class Array;
Expand Down
2 changes: 1 addition & 1 deletion analytical_engine/core/fragment/dynamic_fragment.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
#include "core/object/dynamic.h"
#include "core/utils/convert_utils.h"
#include "core/utils/partitioner.h"
#include "graphscope/proto/types.pb.h"
#include "proto/types.pb.h"

namespace gs {

Expand Down
2 changes: 1 addition & 1 deletion analytical_engine/core/fragment/fragment_reporter.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
#include "core/server/rpc_utils.h"
#include "core/utils/convert_utils.h"
#include "core/utils/msgpack_utils.h"
#include "graphscope/proto/types.pb.h"
#include "proto/types.pb.h"

namespace bl = boost::leaf;

Expand Down
6 changes: 3 additions & 3 deletions analytical_engine/core/grape_instance.cc
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,9 @@
#include "core/server/command_detail.h"
#include "core/server/rpc_utils.h"
#include "core/utils/mpi_utils.h"
#include "graphscope/proto/attr_value.pb.h"
#include "graphscope/proto/graph_def.pb.h"
#include "graphscope/proto/types.pb.h"
#include "proto/attr_value.pb.h"
#include "proto/graph_def.pb.h"
#include "proto/types.pb.h"

namespace bl = boost::leaf;

Expand Down
2 changes: 1 addition & 1 deletion analytical_engine/core/grape_instance.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
#include "core/object/object_manager.h"
#include "core/server/dispatcher.h"
#include "core/server/rpc_utils.h"
#include "graphscope/proto/types.pb.h"
#include "proto/types.pb.h"

namespace bl = boost::leaf;

Expand Down
4 changes: 2 additions & 2 deletions analytical_engine/core/io/property_parser.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@
#include "vineyard/common/util/status.h"

#include "core/server/rpc_utils.h"
#include "graphscope/proto/attr_value.pb.h"
#include "graphscope/proto/types.pb.h"
#include "proto/attr_value.pb.h"
#include "proto/types.pb.h"

namespace bl = boost::leaf;

Expand Down
2 changes: 1 addition & 1 deletion analytical_engine/core/object/dynamic.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
// IWYU pragma: end_exports

#include "grape/serialization/in_archive.h"
#include "graphscope/proto/graph_def.pb.h"
#include "proto/graph_def.pb.h"

namespace gs {

Expand Down
4 changes: 2 additions & 2 deletions analytical_engine/core/object/fragment_wrapper.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@
#include "core/object/i_fragment_wrapper.h"
#include "core/server/rpc_utils.h"
#include "core/utils/transform_utils.h"
#include "graphscope/proto/graph_def.pb.h"
#include "graphscope/proto/types.pb.h"
#include "proto/graph_def.pb.h"
#include "proto/types.pb.h"

namespace bl = boost::leaf;

Expand Down
4 changes: 2 additions & 2 deletions analytical_engine/core/server/command_detail.cc
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
#include "grape/serialization/in_archive.h"
#include "grape/serialization/out_archive.h"

#include "graphscope/proto/attr_value.pb.h"
#include "graphscope/proto/types.pb.h"
#include "proto/attr_value.pb.h"
#include "proto/types.pb.h"

namespace gs {

Expand Down
4 changes: 2 additions & 2 deletions analytical_engine/core/server/command_detail.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
#include <map>
#include <utility>

#include "graphscope/proto/attr_value.pb.h"
#include "graphscope/proto/types.pb.h"
#include "proto/attr_value.pb.h"
#include "proto/types.pb.h"

namespace grape {
class InArchive;
Expand Down
4 changes: 2 additions & 2 deletions analytical_engine/core/server/dispatcher.cc
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@
#include "core/error.h"
#include "core/io/property_parser.h"
#include "core/server/command_detail.h"
#include "graphscope/proto/attr_value.pb.h"
#include "graphscope/proto/graph_def.pb.h"
#include "proto/attr_value.pb.h"
#include "proto/graph_def.pb.h"

namespace bl = boost::leaf;

Expand Down
6 changes: 3 additions & 3 deletions analytical_engine/core/server/dispatcher.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
#include "grape/worker/comm_spec.h"
#include "vineyard/common/util/blocking_queue.h"

#include "graphscope/proto/error_codes.pb.h"
#include "graphscope/proto/graph_def.pb.h"
#include "graphscope/proto/types.pb.h"
#include "proto/error_codes.pb.h"
#include "proto/graph_def.pb.h"
#include "proto/types.pb.h"

namespace bl = boost::leaf;

Expand Down
10 changes: 5 additions & 5 deletions analytical_engine/core/server/graphscope_service.cc
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@
#include "grpcpp/support/sync_stream.h"

#include "core/server/rpc_utils.h"
#include "graphscope/proto/attr_value.pb.h"
#include "graphscope/proto/error_codes.pb.h"
#include "graphscope/proto/graph_def.pb.h"
#include "graphscope/proto/message.pb.h"
#include "graphscope/proto/op_def.pb.h"
#include "proto/attr_value.pb.h"
#include "proto/error_codes.pb.h"
#include "proto/graph_def.pb.h"
#include "proto/message.pb.h"
#include "proto/op_def.pb.h"

namespace gs {
struct CommandDetail;
Expand Down
6 changes: 3 additions & 3 deletions analytical_engine/core/server/graphscope_service.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@
#include "grpcpp/support/sync_stream.h"

#include "core/server/dispatcher.h"
#include "graphscope/proto/engine_service.grpc.pb.h"
#include "graphscope/proto/message.pb.h"
#include "graphscope/proto/op_def.pb.h"
#include "proto/engine_service.grpc.pb.h"
#include "proto/message.pb.h"
#include "proto/op_def.pb.h"

namespace gs {
namespace rpc {
Expand Down
8 changes: 4 additions & 4 deletions analytical_engine/core/server/rpc_utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@

#include "core/config.h"
#include "core/server/command_detail.h"
#include "graphscope/proto/attr_value.pb.h"
#include "graphscope/proto/graph_def.pb.h"
#include "graphscope/proto/op_def.pb.h"
#include "graphscope/proto/types.pb.h"
#include "proto/attr_value.pb.h"
#include "proto/graph_def.pb.h"
#include "proto/op_def.pb.h"
#include "proto/types.pb.h"

namespace bl = boost::leaf;

Expand Down
4 changes: 2 additions & 2 deletions analytical_engine/frame/cython_app_frame.cc
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@
#include "core/app/pregel/pregel_property_app_base.h"
#include "core/error.h"
#include "frame/ctx_wrapper_builder.h"
#include "graphscope/proto/data_types.pb.h"
#include "graphscope/proto/types.pb.h"
#include "proto/data_types.pb.h"
#include "proto/types.pb.h"

#include QUOTE(_APP_HEADER)

Expand Down
4 changes: 2 additions & 2 deletions analytical_engine/frame/cython_pie_app_frame.cc
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@
#include "core/app/app_invoker.h"
#include "core/error.h"
#include "frame/ctx_wrapper_builder.h"
#include "graphscope/proto/data_types.pb.h"
#include "graphscope/proto/types.pb.h"
#include "proto/data_types.pb.h"
#include "proto/types.pb.h"

#ifdef _APP_HEADER
#include QUOTE(_APP_HEADER)
Expand Down
2 changes: 1 addition & 1 deletion analytical_engine/frame/project_frame.cc
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
#include "core/object/fragment_wrapper.h"
#include "core/server/rpc_utils.h"
#include "core/utils/fragment_traits.h"
#include "graphscope/proto/attr_value.pb.h"
#include "proto/attr_value.pb.h"

#if !defined(_PROJECTED_GRAPH_TYPE)
#error "_PROJECTED_GRAPH_TYPE is undefined"
Expand Down
4 changes: 2 additions & 2 deletions analytical_engine/frame/property_graph_frame.cc
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@
#include "core/server/rpc_utils.h"
#include "core/utils/fragment_traits.h"
#include "core/vertex_map/arrow_projected_vertex_map.h"
#include "graphscope/proto/attr_value.pb.h"
#include "graphscope/proto/graph_def.pb.h"
#include "proto/attr_value.pb.h"
#include "proto/graph_def.pb.h"

#if !defined(_GRAPH_TYPE)
#error Missing _GRAPH_TYPE
Expand Down
2 changes: 1 addition & 1 deletion analytical_engine/test/run_java_app.cc
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@
#include "core/loader/arrow_fragment_loader.h"
#include "core/object/fragment_wrapper.h"
#include "core/utils/transform_utils.h"
#include "graphscope/proto/graph_def.pb.h"
#include "java_pie/java_pie_projected_parallel_app.h"
#include "java_pie/java_pie_property_parallel_app.h"
#include "proto/graph_def.pb.h"

namespace bl = boost::leaf;

Expand Down
2 changes: 1 addition & 1 deletion coordinator/gscoordinator/kubernetes_launcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -1148,7 +1148,7 @@ def _allocate_analytical_engine(self):

def _distribute_analytical_process(self, pod_name_list, pod_ip_list):
# generate and distribute hostfile
hosts = os.path.join(get_tempdir(), "kube_hosts")
hosts = os.path.join(get_tempdir(), "hosts_of_nodes")
with open(hosts, "w") as f:
for i, pod_ip in enumerate(pod_ip_list):
f.write(f"{pod_ip} {pod_name_list[i]}\n")
Expand Down
2 changes: 1 addition & 1 deletion coordinator/gscoordinator/op_executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ def _create_analytical_grpc_stub(self):
time.sleep(delay)
delay *= 2 # back off
raise RuntimeError(
"Failed to connect to engine in 60s, deployment may failed. Please check coordinator log for details"
"Failed to connect to engine in a reasonable time, deployment may failed. Please check coordinator log for details"
)

@property
Expand Down
2 changes: 1 addition & 1 deletion coordinator/gscoordinator/template/CMakeLists.template
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ endif()
if(GRAPHSCOPE_ANALYTICAL_HOME)
include_directories("${GRAPHSCOPE_ANALYTICAL_INCLUDE_DIRS}")
include_directories("${GRAPHSCOPE_ANALYTICAL_HOME}/include/graphscope/apps")
include_directories("${GRAPHSCOPE_ANALYTICAL_HOME}/include/graphscope/proto")
include_directories("${GRAPHSCOPE_ANALYTICAL_HOME}/include/graphscope")
# include vineyard----------------------------------------------------------
include_directories("${GRAPHSCOPE_ANALYTICAL_HOME}/include/vineyard")
else()
Expand Down
2 changes: 1 addition & 1 deletion interactive_engine/common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@
<execution>
<id>interactive</id>
<configuration>
<protoSourceRoot>../proto</protoSourceRoot>
<protoSourceRoot>../../proto/groot/</protoSourceRoot>
<excludes>
<exclude>sdk/*</exclude>
</excludes>
Expand Down
2 changes: 1 addition & 1 deletion interactive_engine/executor/store/groot/build.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
extern crate protoc_grpcio;

fn main() {
let proto_root = "../../../proto";
let proto_root = "../../../../proto/groot";
protoc_grpcio::compile_grpc_protos(
&[
proto_root.to_owned() + "/sdk/model.proto",
Expand Down
10 changes: 5 additions & 5 deletions interactive_engine/groot-client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@
<execution>
<id>sdk</id>
<configuration>
<protoSourceRoot>../proto</protoSourceRoot>
<protoSourceRoot>../../proto/groot</protoSourceRoot>
<includes>
<include>sdk/*</include>
</includes>
Expand All @@ -103,11 +103,11 @@
<execution>
<id>graphscope</id>
<configuration>
<protoSourceRoot>../../python</protoSourceRoot>
<protoSourceRoot>../../proto</protoSourceRoot>
<includes>
<include>graphscope/proto/graph_def.proto</include>
<include>graphscope/proto/ddl_service.proto</include>
<include>graphscope/proto/write_service.proto</include>
<include>graph_def.proto</include>
<include>ddl_service.proto</include>
<include>write_service.proto</include>
</includes>
</configuration>
<goals>
Expand Down
4 changes: 2 additions & 2 deletions interactive_engine/lgraph/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,15 @@ find_package(gRPC 1.26.0 REQUIRED)
find_package(CppKafka 0.3.1 REQUIRED)

# Proto file generating
set(PROTO_FILE_DIR ${Lgraph_SOURCE_DIR}/../proto)
set(PROTO_FILE_DIR ${Lgraph_SOURCE_DIR}/../../proto/groot)
set(GRPC_FILES
${PROTO_FILE_DIR}/sdk/client.proto
${PROTO_FILE_DIR}/sdk/client_backup_service.proto)
set(PROTO_FILES
${GRPC_FILES}
${PROTO_FILE_DIR}/sdk/model.proto
${PROTO_FILE_DIR}/sdk/common.proto)
set(PROTOBUF_IMPORT_DIRS ${Lgraph_SOURCE_DIR}/../proto)
set(PROTOBUF_IMPORT_DIRS ${Lgraph_SOURCE_DIR}/../../proto/groot)
set(PROTO_BUILD_DIR ${Lgraph_BINARY_DIR}/generated)
set(PROTO_SRCS_DEST_DIR ${Lgraph_SOURCE_DIR}/src/proto)
set(PROTO_HDRS_DEST_DIR ${Lgraph_SOURCE_DIR}/include/lgraph/proto)
Expand Down
31 changes: 0 additions & 31 deletions interactive_engine/proto/ingest_progress_service.proto

This file was deleted.

Loading