mirror of
https://github.com/apple/foundationdb.git
synced 2025-05-14 09:58:50 +08:00
* initial structure for remote IKVS server * moved struct to .h file, added new files to CMakeList * happy path implementation, connection error when testing * saved minor local change * changed tracing to debug * fixed onClosed and getError being called before init is finished * fix spawn process bug, now use absolute path * added server knob to set ikvs process port number * added server knob for remote/local kv store * implement simulator remote process spawning * fixed bug for simulator timeout * commit all changes * removed print lines in trace * added FlowProcess implementation by Markus * initial debug of FlowProcess, stuck at parent sending OpenKVStoreRequest to child * temporary fix for process factory throwing segfault on create * specify public address in command * change remote kv store knob to false for jenkins build * made port 0 open random unused port * change remote store knob to true for benchmark * set listening port to randomly opened port * added print lines for jenkins run open kv store timeout debug * removed most tracing and print lines * removed tutorial changes * update handleIOErrors error handling to handle remote-ikvs cases * Push all debugging changes * A version where worker bug exists * A version where restarting tests fail * Use both the name and the port to determine the child process * Remove unnecessary update on local address * Disable remote-kvs for DiskFailureCycle test * A version where restarting stuck * A version where most restarting tests green * Reset connection with child process explicitly * Remove change on unnecessary files * Unify flags from _ to - * fix merging unexpected changes * fix trac.error to .errorUnsuppressed * Add license header * Remove unnecessary header in FlowProcess.actor.cpp * Fix Windows build * Fix Windows build, add missing ; * Fix a stupid bug caused by code dropped by code merging * Disable remote kvs by default * Pass the conn_file path to the flow process, though not needed, but the buildNetwork is difficult to tune * serialization change on readrange * Update traces * Refactor the RemoteIKVS interface * Format files * Update sim2 interface to not clog connections between parent and child processes in simulation * Update comments; remove debugging symbols; Add error handling for remote_kvs_cancelled * Add comments, format files * Change method name from isBuggifyDisabled to isStableConnection; Decrease(0.1x) latency for stable connections * Commit the IConnection interface change, forgot in previous commit * Fix the issue that onClosed request is cancelled by ActorCollection * Enable the remote kv store knob * Remove FlowProcess.actor.cpp and move functions to RemoteIKeyValueStore.actor.cpp; Add remote kv store delay to avoid race; Bind the child process to die with parent process * Fix the bug where one process starts storage server more than once * Add a please_reboot_remote_kv_store error to restart the storage server worker if remote kvs died abnormally * Remove unreachable code path and add comments * Clang format the code * Fix a simple wait error * Clang format after merging the main branch * Testing mixed mode in simulation if remote_kvs knob is enabled, setting the default to false * Disable remote kvs for PhysicalShardMove which is for RocksDB * Cleanup #include orders, remove debugging traces * Revert the reorder in fdbserver.actor.cpp, which fails the gcc build Co-authored-by: “Lincoln <“lincoln.xiao@snowflake.com”>
112 lines
3.0 KiB
CMake
112 lines
3.0 KiB
CMake
set(FDBRPC_SRCS
|
|
AsyncFileCached.actor.h
|
|
AsyncFileEIO.actor.h
|
|
AsyncFileEncrypted.h
|
|
AsyncFileKAIO.actor.h
|
|
AsyncFileNonDurable.actor.h
|
|
AsyncFileReadAhead.actor.h
|
|
AsyncFileWinASIO.actor.h
|
|
AsyncFileCached.actor.cpp
|
|
AsyncFileNonDurable.actor.cpp
|
|
AsyncFileWriteChecker.cpp
|
|
FailureMonitor.actor.cpp
|
|
FlowProcess.actor.h
|
|
FlowTransport.actor.cpp
|
|
genericactors.actor.h
|
|
genericactors.actor.cpp
|
|
HealthMonitor.actor.cpp
|
|
IAsyncFile.actor.cpp
|
|
LoadBalance.actor.cpp
|
|
LoadBalance.actor.h
|
|
Locality.cpp
|
|
Net2FileSystem.cpp
|
|
networksender.actor.h
|
|
PerfMetric.cpp
|
|
PerfMetric.h
|
|
QueueModel.cpp
|
|
ReplicationPolicy.cpp
|
|
ReplicationTypes.cpp
|
|
ReplicationUtils.cpp
|
|
SimExternalConnection.actor.cpp
|
|
SimExternalConnection.h
|
|
Stats.actor.cpp
|
|
Stats.h
|
|
sim2.actor.cpp
|
|
sim_validation.cpp
|
|
TimedRequest.h
|
|
TraceFileIO.cpp
|
|
TSSComparison.h)
|
|
|
|
if(WITH_TLS)
|
|
set(FDBRPC_SRCS
|
|
${FDBRPC_SRCS}
|
|
AsyncFileEncrypted.actor.cpp)
|
|
endif()
|
|
|
|
set(COMPILE_EIO OFF)
|
|
|
|
if(NOT WIN32)
|
|
if(CMAKE_SYSTEM_NAME STREQUAL "FreeBSD")
|
|
find_library(EIO eio)
|
|
if(NOT EIO)
|
|
set(COMPILE_EIO ON)
|
|
endif()
|
|
else()
|
|
set(COMPILE_EIO ON)
|
|
endif()
|
|
endif()
|
|
|
|
set(FDBRPC_SRCS_DISABLE_ACTOR_DIAGNOSTICS
|
|
ActorFuzz.actor.cpp
|
|
FlowTests.actor.cpp
|
|
dsltest.actor.cpp)
|
|
|
|
add_flow_target(STATIC_LIBRARY NAME fdbrpc
|
|
SRCS ${FDBRPC_SRCS}
|
|
DISABLE_ACTOR_DIAGNOSTICS ${FDBRPC_SRCS_DISABLE_ACTOR_DIAGNOSTICS})
|
|
target_include_directories(fdbrpc PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/libeio)
|
|
target_link_libraries(fdbrpc PUBLIC flow)
|
|
|
|
add_flow_target(STATIC_LIBRARY NAME fdbrpc_sampling
|
|
SRCS ${FDBRPC_SRCS}
|
|
DISABLE_ACTOR_DIAGNOSTICS ${FDBRPC_SRCS_DISABLE_ACTOR_DIAGNOSTICS})
|
|
target_include_directories(fdbrpc_sampling PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/libeio)
|
|
target_link_libraries(fdbrpc_sampling PUBLIC flow_sampling)
|
|
target_compile_definitions(fdbrpc_sampling PRIVATE -DENABLE_SAMPLING)
|
|
if(WIN32)
|
|
add_dependencies(fdbrpc_sampling_actors fdbrpc_actors)
|
|
endif()
|
|
|
|
if(COMPILE_EIO)
|
|
add_library(eio STATIC libeio/eio.c)
|
|
if(USE_VALGRIND)
|
|
target_link_libraries(eio PUBLIC Valgrind)
|
|
endif()
|
|
target_compile_definitions(eio PRIVATE USE_UCONTEXT)
|
|
target_compile_options(eio BEFORE PRIVATE -w) # disable warnings for eio
|
|
target_link_libraries(fdbrpc PRIVATE eio)
|
|
target_link_libraries(fdbrpc_sampling PRIVATE eio)
|
|
endif()
|
|
|
|
if(${COROUTINE_IMPL} STREQUAL libcoro)
|
|
set(CORO_SRCS libcoroutine/Common.c libcoroutine/Coro.c)
|
|
if(APPLE)
|
|
list(APPEND CORO_SRCS libcoroutine/asm.S)
|
|
endif()
|
|
if(NOT WIN32)
|
|
list(APPEND CORO_SRCS libcoroutine/context.c)
|
|
endif()
|
|
add_library(coro STATIC ${CORO_SRCS})
|
|
if(WIN32)
|
|
target_compile_definitions(coro PRIVATE USE_FIBERS)
|
|
else()
|
|
target_compile_definitions(coro PRIVATE USE_UCONTEXT)
|
|
target_compile_options(coro BEFORE PRIVATE -w) # disable warnings for third party
|
|
endif()
|
|
if(USE_VALGRIND)
|
|
target_link_libraries(coro PUBLIC Valgrind)
|
|
endif()
|
|
target_link_libraries(fdbrpc PRIVATE coro)
|
|
target_link_libraries(fdbrpc_sampling PRIVATE coro)
|
|
endif()
|