Skip to content

feature: migrate the control rpc to connect#205

Open
rustatian wants to merge 6 commits into
masterfrom
feature/connect-rpc
Open

feature: migrate the control rpc to connect#205
rustatian wants to merge 6 commits into
masterfrom
feature/connect-rpc

Conversation

@rustatian

Copy link
Copy Markdown
Member
  • replace the legacy RPC() any surface (dead code in v6 — the rpc plugin no longer collects it) with RPC() (string, http.Handler) returning the generated CentrifugoApi connect handler, so the PHP-facing publish/broadcast/... API is reachable again on the v6 RPC plane
  • all 33 methods proxy 1:1 to the connected Centrifugo server through a single generic forwarder (responses pass through whole instead of field-by-field copies); gRPC status errors map to connect codes, and the not-connected case returns CodeUnavailable
  • the Centrifugo-facing transports are untouched: the gRPC API client (client.go) and the CentrifugoProxy gRPC server (plugin.go) stay exactly as they were
  • depends on feature: add centrifugo api and temporal service connect packages api-go#21 (and feature: add temporal control-plane connect service api#75): api-go is pinned to a pseudo-version of that branch — bump to v6.0.0-beta.13 once tagged
  • update dependencies (root and tests modules)

Copilot AI review requested due to automatic review settings June 10, 2026 20:53
@coderabbitai

coderabbitai Bot commented Jun 10, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@rustatian, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 55 minutes and 35 seconds. Learn how PR review limits work.

Your organization has reached its usage spending cap. Adjust your spending cap in the billing tab.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: d920e42d-38ce-496d-9a90-621313049c2b

📥 Commits

Reviewing files that changed from the base of the PR and between 6fe6041 and 6a70273.

⛔ Files ignored due to path filters (3)
  • go.sum is excluded by !**/*.sum
  • go.work.sum is excluded by !**/*.sum
  • tests/go.sum is excluded by !**/*.sum
📒 Files selected for processing (6)
  • go.mod
  • plugin.go
  • rpc.go
  • rpc_forward_test.go
  • rpc_test.go
  • tests/go.mod
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/connect-rpc

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@codecov

codecov Bot commented Jun 10, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 98.70130% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 72.51%. Comparing base (6fe6041) to head (6a70273).

Files with missing lines Patch % Lines
rpc.go 98.64% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           master     #205       +/-   ##
===========================================
+ Coverage   39.26%   72.51%   +33.24%     
===========================================
  Files           9        9               
  Lines         848      564      -284     
===========================================
+ Hits          333      409       +76     
+ Misses        483      123      -360     
  Partials       32       32               

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR migrates the Centrifuge plugin’s control RPC surface from the legacy RPC() any shape to a Connect-RPC handler (RPC() (string, http.Handler)), restoring access to the PHP-facing publish/broadcast/etc API on the v6 RPC plane by proxying requests to the connected Centrifugo gRPC API client.

Changes:

  • Replaced the legacy RPC implementation with a Connect-RPC CentrifugoApi handler and a generic forwarder that proxies calls to the Centrifugo gRPC client and maps gRPC status codes to Connect codes.
  • Updated Plugin.RPC() to return the generated Connect handler for mounting on RoadRunner’s RPC server.
  • Bumped dependencies (including pinning api-go to a pseudo-version) and updated module sums; adjusted unit test for the new Connect-based RPC entrypoint.

Reviewed changes

Copilot reviewed 6 out of 8 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
rpc.go Reimplements Centrifugo control RPC as a Connect-RPC handler with a generic forwarding helper.
plugin.go Updates RPC() to return (string, http.Handler) using the generated Connect handler.
rpc_test.go Updates the not-ready test to call the Connect handler method and assert Connect error code.
go.mod Adds connectrpc.com/connect and bumps api-go to the required pseudo-version.
go.sum Adds sums for the new Connect dependency and updates sums for bumped modules.
go.work.sum Workspace sums updated, but currently inconsistent with go.mod/go.sum for some entries.
tests/go.mod Updates indirect dependencies for the tests module (incl. api-go pseudo-version).
tests/go.sum Updates sums to match bumped test-module dependencies.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread go.work.sum
Comment thread go.work.sum
@rustatian rustatian self-assigned this Jun 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants