diff --git a/CMakeLists.txt b/CMakeLists.txt index cf67e6127fabfe998bedefda174fa38e2e358e39..f4e8c64c4ff73d0a417c35159901c2e67d0ca4ef 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -65,7 +65,7 @@ endif() if (NOT CLIENT_ONLY) include(external/jsoncpp) -include(external/rocksdb) +#include(external/rocksdb) endif() #include(external/gtest) diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt index 3c775a9acb2ac17a99557bfd28c4e8a3cf20a8c5..7226a69a87163cf625f49f54fe2a7df996a98efd 100644 --- a/core/CMakeLists.txt +++ b/core/CMakeLists.txt @@ -14,7 +14,7 @@ if(NOT CLIENT_ONLY) add_subdirectory(cube) -add_subdirectory(kvdb) +#add_subdirectory(kvdb) endif() add_subdirectory(configure) add_subdirectory(pdcodegen) diff --git a/core/general-server/CMakeLists.txt b/core/general-server/CMakeLists.txt index 87d1c284dba2b098ac065f5e86f7506a79c0141f..82ce53462cb0a5f775cb0ee85b827bba38f5c306 100644 --- a/core/general-server/CMakeLists.txt +++ b/core/general-server/CMakeLists.txt @@ -1,4 +1,3 @@ -include_directories(SYSTEM ${CMAKE_CURRENT_LIST_DIR}/../kvdb/include) include(op/CMakeLists.txt) include(proto/CMakeLists.txt) add_executable(serving ${serving_srcs}) @@ -24,8 +23,6 @@ target_link_libraries(serving pdserving) target_link_libraries(serving cube-api) target_link_libraries(serving utils) -target_link_libraries(serving kvdb rocksdb) - if(WITH_GPU) target_link_libraries(serving ${CUDA_LIBRARIES}) endif() diff --git a/core/predictor/CMakeLists.txt b/core/predictor/CMakeLists.txt index 335a7f905f781a26719021fdcf4ea2f1e3c0f983..38d977f1d2aeee556c46bb16da32bd2b20de3911 100644 --- a/core/predictor/CMakeLists.txt +++ b/core/predictor/CMakeLists.txt @@ -6,17 +6,16 @@ include(framework/CMakeLists.txt) #include(plugin/CMakeLists.txt) include(src/CMakeLists.txt) -include_directories(SYSTEM ${CMAKE_CURRENT_LIST_DIR}/../kvdb/include) add_library(pdserving ${pdserving_srcs}) set_source_files_properties( ${pdserving_srcs} PROPERTIES COMPILE_FLAGS "-Wno-strict-aliasing -Wno-unused-variable -Wno-non-virtual-dtor -Wno-error=non-virtual-dtor -Wno-error=delete-non-virtual-dtor") -add_dependencies(pdserving protobuf kvdb boost brpc leveldb pdcodegen configure) +add_dependencies(pdserving protobuf boost brpc leveldb pdcodegen configure) target_link_libraries(pdserving - brpc protobuf boost leveldb configure kvdb -lpthread -lcrypto -lm -lrt -lssl -ldl -lz) + brpc protobuf boost leveldb configure -lpthread -lcrypto -lm -lrt -lssl -ldl -lz) # install install(TARGETS pdserving diff --git a/core/predictor/framework/resource.cpp b/core/predictor/framework/resource.cpp index 943b1715109bf85108d338bce7e286d410ede494..f4f9091f689c36bc853730e0dd68cba089c7fb8b 100644 --- a/core/predictor/framework/resource.cpp +++ b/core/predictor/framework/resource.cpp @@ -39,8 +39,6 @@ DynamicResource::~DynamicResource() {} int DynamicResource::initialize() { return 0; } -std::shared_ptr Resource::getDB() { return db; } - std::shared_ptr Resource::get_general_model_config() { return _config; } @@ -143,10 +141,6 @@ int Resource::initialize(const std::string& path, const std::string& file) { LOG(ERROR) << "unable to create tls_bthread_key of thrd_data"; return -1; } - // init rocksDB instance - if (db.get() == nullptr) { - db = RocksDBWrapper::RocksDBWrapperFactory("kvdb"); - } THREAD_SETSPECIFIC(_tls_bspec_key, NULL); return 0; diff --git a/core/predictor/framework/resource.h b/core/predictor/framework/resource.h index eedd4fc19edcd0dd528445198a53c5c67d88dbc8..3cf494b97667474157dc744caea4bc77a6b8b443 100644 --- a/core/predictor/framework/resource.h +++ b/core/predictor/framework/resource.h @@ -18,7 +18,6 @@ #include #include #include "core/cube/cube-api/include/cube_api.h" -#include "core/kvdb/include/kvdb/paddle_rocksdb.h" #include "core/predictor/common/inner_common.h" #include "core/predictor/framework/infer.h" #include "core/predictor/framework/memory.h" @@ -101,8 +100,6 @@ class Resource { void print_general_model_config( const std::shared_ptr& config); - std::shared_ptr getDB(); - DynamicResource* get_dynamic_resource() { return reinterpret_cast( THREAD_GETSPECIFIC(_tls_bspec_key)); @@ -110,7 +107,6 @@ class Resource { private: int thread_finalize() { return 0; } - std::shared_ptr db; std::shared_ptr _config; THREAD_KEY_T _tls_bspec_key; diff --git a/paddle_inference/inferencer-fluid-cpu/CMakeLists.txt b/paddle_inference/inferencer-fluid-cpu/CMakeLists.txt index b3183eca1a0c2bb9524db7d7eb19f924079e0f0d..fe7cd91c534d900f3afb466e48599f60e64e4f9d 100644 --- a/paddle_inference/inferencer-fluid-cpu/CMakeLists.txt +++ b/paddle_inference/inferencer-fluid-cpu/CMakeLists.txt @@ -2,7 +2,7 @@ FILE(GLOB fluid_cpu_engine_srcs ${CMAKE_CURRENT_LIST_DIR}/src/*.cpp) add_library(fluid_cpu_engine ${fluid_cpu_engine_srcs}) target_include_directories(fluid_cpu_engine PUBLIC ${CMAKE_BINARY_DIR}/Paddle/fluid_install_dir/) -add_dependencies(fluid_cpu_engine pdserving extern_paddle configure kvdb) +add_dependencies(fluid_cpu_engine pdserving extern_paddle configure) target_link_libraries(fluid_cpu_engine pdserving paddle_fluid -lpthread -lcrypto -lm -lrt -lssl -ldl -lz) install(TARGETS fluid_cpu_engine diff --git a/paddle_inference/inferencer-fluid-gpu/CMakeLists.txt b/paddle_inference/inferencer-fluid-gpu/CMakeLists.txt index 6c980d6d94ef99585cf956072d8181d0d98cda42..725da85b45ca1070badf5343f340e49dce6b936f 100644 --- a/paddle_inference/inferencer-fluid-gpu/CMakeLists.txt +++ b/paddle_inference/inferencer-fluid-gpu/CMakeLists.txt @@ -2,7 +2,7 @@ FILE(GLOB fluid_gpu_engine_srcs ${CMAKE_CURRENT_LIST_DIR}/src/*.cpp) add_library(fluid_gpu_engine ${fluid_gpu_engine_srcs}) target_include_directories(fluid_gpu_engine PUBLIC ${CMAKE_BINARY_DIR}/Paddle/fluid_install_dir/) -add_dependencies(fluid_gpu_engine pdserving extern_paddle configure kvdb) +add_dependencies(fluid_gpu_engine pdserving extern_paddle configure) target_link_libraries(fluid_gpu_engine pdserving paddle_fluid iomp5 mklml_intel -lpthread -lcrypto -lm -lrt -lssl -ldl -lz) install(TARGETS fluid_gpu_engine