Skip to content

Commit

Permalink
Remove the old log buffer (#13821)
Browse files Browse the repository at this point in the history
* Remove the old log buffer

* Add a changeset

* Update integration test

* Lint

* Clean up from config

* Update tests

* Integration test lint

* Clean up sync filters
  • Loading branch information
ferglor authored Jul 19, 2024
1 parent 2207a38 commit 5b668c1
Show file tree
Hide file tree
Showing 14 changed files with 395 additions and 1,896 deletions.
5 changes: 5 additions & 0 deletions .changeset/unlucky-lemons-learn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"chainlink": minor
---

Use the new log buffer in automation #changed
3 changes: 1 addition & 2 deletions core/services/job/helpers_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ maxServiceWorkers = 100
cacheEvictionInterval = "1s"
mercuryCredentialName = "%s"
contractVersion = "v2.1"
useBufferV1 = %v
`
voterTurnoutDataSourceTemplate = `
// data source 1
Expand Down Expand Up @@ -277,7 +276,7 @@ func makeOCR2Keeper21JobSpec(t testing.TB, ks keystore.Master, transmitter commo
_, registry := cltest.MustInsertRandomKey(t, ks.Eth())

ocr2Keeper21Job := fmt.Sprintf(ocr2Keeper21JobSpecTemplate, registry.String(), kb.ID(), transmitter,
fmt.Sprintf("%s127.0.0.1:%d", bootstrapPeerID, bootstrapNodePort), chainID, "mercury cred", false)
fmt.Sprintf("%s127.0.0.1:%d", bootstrapPeerID, bootstrapNodePort), chainID, "mercury cred")

jobSpec := makeOCR2JobSpecFromToml(t, ocr2Keeper21Job)

Expand Down
9 changes: 0 additions & 9 deletions core/services/ocr2/delegate.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ import (
"github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper"
"github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evmregistry/v21/autotelemetry21"
ocr2keeper21core "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evmregistry/v21/core"
"github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evmregistry/v21/logprovider"
"github.com/smartcontractkit/chainlink/v2/core/services/ocr2/validate"
"github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon"
"github.com/smartcontractkit/chainlink/v2/core/services/pipeline"
Expand Down Expand Up @@ -1123,14 +1122,6 @@ func (d *Delegate) newServicesOCR2Keepers21(
return nil, errors.New("could not coerce PluginProvider to AutomationProvider")
}

// TODO: (AUTO-9355) remove once we remove v0
if useBufferV1 := cfg.UseBufferV1 != nil && *cfg.UseBufferV1; useBufferV1 {
logProviderFeatures, ok := keeperProvider.LogEventProvider().(logprovider.LogEventProviderFeatures)
if ok {
logProviderFeatures.WithBufferVersion("v1")
}
}

services, err := ocr2keeper.EVMDependencies21(kb)
if err != nil {
return nil, errors.Wrap(err, "could not build dependencies for ocr2 keepers")
Expand Down
3 changes: 0 additions & 3 deletions core/services/ocr2/plugins/ocr2keeper/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,6 @@ type PluginConfig struct {
ContractVersion string `json:"contractVersion"`
// CaptureAutomationCustomTelemetry is a bool flag to toggle Custom Telemetry Service
CaptureAutomationCustomTelemetry *bool `json:"captureAutomationCustomTelemetry,omitempty"`
// UseBufferV1 is a bool flag to toggle the new log buffer implementation
// TODO: (AUTO-9355) remove once we have a single version
UseBufferV1 *bool `json:"useBufferV1,omitempty"`
}

func ValidatePluginConfig(cfg PluginConfig) error {
Expand Down
Loading

0 comments on commit 5b668c1

Please sign in to comment.