[agent_farm] setup gRPC frontend for the webserver (Run ID: codestoryai_sidecar_issue_2008_a27666d3)#2009
[agent_farm] setup gRPC frontend for the webserver (Run ID: codestoryai_sidecar_issue_2008_a27666d3)#2009
Conversation
The commit adds a gRPC server implementation alongside the existing HTTP server, enabling clients to use either protocol. The implementation includes streaming and unary endpoints for agent interactions, file operations, and code analysis. Changes include: - Add protobuf service definitions - Implement concurrent HTTP and gRPC servers - Add streaming endpoints for chat, edit and tool use - Add conversions between gRPC and internal types - Add tests and documentation for gRPC server
|
/agent no I want you to handle the /agentic nested route and convert that to a grpc frontend for me |
|
🔄 Implements gRPC frontend for the
|
|
/agent no look at agentic.rs and notice the endpoints which are exposed over there and mimic that in proto and setup grpc for it |
The commit adds new endpoints for plan generation and editing modes (anchored and agentic) to the agent farm gRPC service, along with corresponding proto definitions and tests.
|
Feature: Added new gRPC endpoints for plan generation and code editing operations.
🔍 Ready for review - These changes expand our gRPC API surface to match existing HTTP endpoints while maintaining consistent error handling and streaming responses. |
|
/agent gate the grpc server against a feature flag called |
This commit message reflects that the main change is making the gRPC server implementation optional through a feature flag, which is a refactoring of the existing code structure rather than adding new functionality or fixing a bug.
|
Feature: Add gRPC server implementation with feature flag
Ready for review - please verify dual protocol support works as expected. 🚀 |
|
/agent can we not do automatic .proto to types in rust migration? how can we do that |
The commit adds core gRPC functionality including type definitions, service implementation and tests for the agent farm service.
|
Feat: Manual gRPC Server Implementation with Optional Protobuf Support 🚀
👉 Please review the changes to ensure type safety and feature compatibility are maintained. |
|
/agent I am pretty sure there is a way to generate the rust type from the proto file directly during the build step or something, I remember doing it once before |
The diff shows significant changes to add gRPC service support using tonic framework. Main changes include: - Add tonic-build dependency and protobuf compilation setup - Remove unused fs_extra dependency - Refactor build.rs to handle proto compilation - Add gRPC service implementation with request/response handling - Update cargo configuration for gRPC feature
|
Successfully pushed commit 27cd9bf with the latest changes! 🎉 |
|
/agent run cargo check and cargo build --bin webserver to make sure it still works |
|
feat: Add gRPC server with streaming endpoints and concurrent HTTP/gRPC support 🚀 The implementation adds a full gRPC server alongside the existing HTTP server, with comprehensive support for streaming endpoints (chat, edit, tool use), type conversions between gRPC/internal types, and proper error handling - all guarded behind an optional feature flag for flexibility. The changes have been verified to build successfully with both cargo check and cargo build, with only minor build warnings addressed.
|
| let http_server = run(application); | ||
|
|
||
| tokio::select! { | ||
| result = tokio::join!(http_server, grpc_server) => { |
There was a problem hiding this comment.
wondering if tokio::join works inside tokio::select, probably does
There was a problem hiding this comment.
the bot does not know how to work on individual feedback or questions like this yet ...
|
/q wondering if tokio::join works inside tokio::select, probably does |
|
Looking at the code implementation, specifically in Specifically: Yes, tokio::join! is being used successfully inside a tokio::select! block in the gRPC-enabled configuration path: #[cfg(feature = "grpc")]
{
tokio::select! {
result = tokio::join!(http_server, grpc_server) => {
match result {
(Ok(_), Ok(_)) => Ok(()),
(Err(e), _) => {
error!(?e, "HTTP server failed");
Err(e)
},
(_, Err(e)) => {
error!(?e, "gRPC server failed");
Err(e.into())
}
}
}
_ = rx => {
debug!("Signal received, cleaning up...");
Ok(())
}
}
}This is working as expected since |
agent_instance: codestoryai_sidecar_issue_2008_a27666d3 Tries to fix: #2008