story: DGR-033 Build a standalone fake C++ gRPC Shard worker
This commit is contained in:
@@ -62,6 +62,21 @@ message(STATUS "Pinned gRPC ${gRPC_VERSION}: building ShardRuntime service stubs
|
||||
|
||||
enable_testing()
|
||||
|
||||
# The standalone fake Shard worker (DGR-033): a real gRPC server over the
|
||||
# ShardRuntime service, backed by the model-free FakeShardEngine. It links the
|
||||
# grpc service stubs only — no llama.cpp, no graph-execution entry point.
|
||||
add_executable(shard_worker
|
||||
worker/shard_worker_main.cpp
|
||||
worker/shard_service.cpp)
|
||||
target_include_directories(shard_worker PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/worker")
|
||||
target_link_libraries(shard_worker PRIVATE shard_runtime_grpc gRPC::grpc++)
|
||||
|
||||
# Pure-C++ CTest: the worker binds an ephemeral port, self-drives the full
|
||||
# lifecycle (capability, health, fragmented prefill, decode, release) over a
|
||||
# real loopback gRPC channel, and exits non-zero on any mismatch. This proves
|
||||
# the worker serves the contract without needing a Python environment.
|
||||
add_test(NAME shard_worker_selftest COMMAND shard_worker --selftest)
|
||||
|
||||
add_executable(shard_protocol_conformance tests/test_shard_protocol_conformance.cpp)
|
||||
target_link_libraries(shard_protocol_conformance PRIVATE shard_runtime_proto)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user