From d4e8d9634b58fcd6338f0878ffdf95a63dbfcb7d Mon Sep 17 00:00:00 2001 From: Michael Street <5597260+MStreet3@users.noreply.github.com> Date: Tue, 24 Nov 2026 16:02:40 +0200 Subject: [PATCH] fix(ocr3_1): set consensus-queue defaults to plugin limits The consensus-queue defaults left every blob limit at zero. The reporting plugin broadcasts trigger events as blobs and needs blob quotas that hold a full observation, so DONs deployed with the defaults could not run it. Use the plugin's limits as the defaults: 512 KiB observations, 4 modified keys, 10 MiB of keys plus values, 5 MiB blobs, 100 unexpired blobs and 100 MiB of unexpired blob payload per oracle. Refs: CRE-6011 --- deployment/cre/ocr3/ocr3_1/config_test.go | 17 ++++++++++++++++- deployment/cre/ocr3/ocr3_1/oracle_config.go | 13 +++++++++---- 2 files changed, 25 insertions(+), 5 deletions(-) diff --git a/deployment/cre/ocr3/ocr3_1/config_test.go b/deployment/cre/ocr3/ocr3_1/config_test.go index 685760e825b..2454a7d00f8 100644 --- a/deployment/cre/ocr3/ocr3_1/config_test.go +++ b/deployment/cre/ocr3/ocr3_1/config_test.go @@ -488,11 +488,26 @@ func Test_GenerateOCR3_1Config_ConsensusQueueOffchainConfig(t *testing.T) { t.Errorf("encoded limits mismatch (-want +got):\n%s", diff) } + // Asserts the defaults decode on the node and keep the blob quotas the plugin needs. t.Run("defaults are valid", func(t *testing.T) { b, err := DefaultConsensusQueueOffchainConfig().Marshal() require.NoError(t, err) - _, err = queuepb.Decode(b) + decoded, err := queuepb.Decode(b) require.NoError(t, err) + got, err := decoded.OCRLimits() + require.NoError(t, err) + + want := ocr3_1types.ReportingPluginLimits{ + MaxObservationBytes: 512 * 1024, + MaxKeyValueModifiedKeys: 4, + MaxKeyValueModifiedKeysPlusValuesBytes: 10 * 1024 * 1024, + MaxBlobPayloadBytes: 5 * 1024 * 1024, + MaxPerOracleUnexpiredBlobCumulativePayloadBytes: 100 * 1024 * 1024, + MaxPerOracleUnexpiredBlobCount: 100, + } + if diff := cmp.Diff(want, got); diff != "" { + t.Errorf("default limits mismatch (-want +got):\n%s", diff) + } }) t.Run("invalid limits fail to marshal", func(t *testing.T) { diff --git a/deployment/cre/ocr3/ocr3_1/oracle_config.go b/deployment/cre/ocr3/ocr3_1/oracle_config.go index f540ad1c526..b082f0cb7ce 100644 --- a/deployment/cre/ocr3/ocr3_1/oracle_config.go +++ b/deployment/cre/ocr3/ocr3_1/oracle_config.go @@ -130,14 +130,19 @@ type ConsensusQueueLimits struct { } // DefaultConsensusQueueOffchainConfig returns starting limits for a consensus-queue DON. -// The plugin has no queries, reports or blobs yet, so those limits are zero. +// The plugin broadcasts trigger events as blobs, so the blob quotas hold every blob in a full observation, +// and it writes a fixed handful of KV keys per round. +// The plugin has no queries or reports, so those limits are zero. // The node never applies defaults itself. Different node versions would otherwise disagree under the same digest. func DefaultConsensusQueueOffchainConfig() *ConsensusQueueOffchainConfig { return &ConsensusQueueOffchainConfig{ Limits: ConsensusQueueLimits{ - MaxObservationBytes: 256 * 1024, - MaxKeyValueModifiedKeys: 1_000, - MaxKeyValueModifiedKeysPlusValuesBytes: 4 * 1024 * 1024, + MaxObservationBytes: 512 * 1024, + MaxKeyValueModifiedKeys: 4, + MaxKeyValueModifiedKeysPlusValuesBytes: 10 * 1024 * 1024, + MaxBlobPayloadBytes: 5 * 1024 * 1024, + MaxPerOracleUnexpiredBlobCumulativePayloadBytes: 100 * 1024 * 1024, + MaxPerOracleUnexpiredBlobCount: 100, }, } }