Skip to content

Commit

Permalink
Increase maxPerformDataSize in maxObservation, maxOutcome size calcul…
Browse files Browse the repository at this point in the history
…ation
  • Loading branch information
infiloop2 committed Nov 27, 2023
1 parent d4cab69 commit f62a94a
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions pkg/v3/observation.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ import (
// as different nodes would upgrade at different times and would need to
// adhere to each others' limits
const (
ObservationPerformablesLimit = 100
ObservationPerformablesLimit = 50
ObservationLogRecoveryProposalsLimit = 5
ObservationConditionalsProposalsLimit = 5
ObservationBlockHistoryLimit = 256

// MaxObservationLength applies a limit to the total length of bytes in an
// observation. NOTE: This is derived from a limit of 5000 on performData
// observation. NOTE: This is derived from a limit of 10000 on performData
// which is guaranteed onchain
MaxObservationLength = 1_000_000
)
Expand Down
2 changes: 1 addition & 1 deletion pkg/v3/observation_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -547,7 +547,7 @@ func TestLargeObservationSize(t *testing.T) {
Hash: [32]byte{1},
})
}
largePerformData := [5001]byte{}
largePerformData := [10001]byte{}
for i := 0; i < ObservationPerformablesLimit; i++ {
newResult := validLogResult
uid := types.UpkeepIdentifier{}
Expand Down
2 changes: 1 addition & 1 deletion pkg/v3/outcome.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
// as different nodes would upgrade at different times and would need to
// adhere to each others' limits
const (
OutcomeAgreedPerformablesLimit = 100
OutcomeAgreedPerformablesLimit = 80
OutcomeSurfacedProposalsLimit = 50
// NOTE: This should be enough number of rounds to encompass ObservationProcessLimit
// so that proposals have enough time to be processed before getting coordinated on
Expand Down
2 changes: 1 addition & 1 deletion pkg/v3/outcome_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ func TestLargeOutcomeSize(t *testing.T) {
AgreedPerformables: []types.CheckResult{},
SurfacedProposals: [][]types.CoordinatedBlockProposal{},
}
largePerformData := [5001]byte{}
largePerformData := [10001]byte{}
for i := 0; i < OutcomeAgreedPerformablesLimit; i++ {
newResult := validLogResult
uid := types.UpkeepIdentifier{}
Expand Down

0 comments on commit f62a94a

Please sign in to comment.