Skip to content

chore: apply the 4mb max limit on drpc protocol message size #17771

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
May 13, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
revert back to 4mb
  • Loading branch information
Emyrk committed May 12, 2025
commit 915457f295bbf3e851e644f2bb9d20b0faa1290f
2 changes: 1 addition & 1 deletion codersdk/drpcsdk/transport.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
const (
// MaxMessageSize is the maximum payload size that can be
// transported without error.
MaxMessageSize = 10 << 20
MaxMessageSize = 4 << 20
)

func DefaultDRPCOptions(options *drpcmanager.Options) drpcmanager.Options {
Expand Down
4 changes: 2 additions & 2 deletions provisionerd/provisionerd_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ func TestProvisionerd(t *testing.T) {
require.NoError(t, closer.Close())
})

// LargePayloads sends a 6mb tar file to the provisioner. The provisioner also
// LargePayloads sends a 3mb tar file to the provisioner. The provisioner also
// returns large payload messages back. The limit should be 10mb, so all
// these messages should work.
t.Run("LargePayloads", func(t *testing.T) {
Expand All @@ -188,7 +188,7 @@ func TestProvisionerd(t *testing.T) {
close(done)
})
var (
largeSize = 6 * 1024 * 1024
largeSize = 3 * 1024 * 1024
completeChan = make(chan struct{})
completeOnce sync.Once
acq = newAcquireOne(t, &proto.AcquiredJob{
Expand Down
Loading