From 992aa3d9ed561a0c890e7471b13038b2992536e5 Mon Sep 17 00:00:00 2001 From: Aditya Vyas Date: Wed, 1 Nov 2023 16:58:57 -0400 Subject: [PATCH] Remove enable-captive-core-ingestion support - 2 --- services/horizon/internal/ingest/main.go | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/services/horizon/internal/ingest/main.go b/services/horizon/internal/ingest/main.go index 6535a3e097..ee83c211b8 100644 --- a/services/horizon/internal/ingest/main.go +++ b/services/horizon/internal/ingest/main.go @@ -76,7 +76,6 @@ type Config struct { CoreSession db.SessionInterface StellarCoreURL string StellarCoreCursor string - EnableCaptiveCore bool CaptiveCoreBinaryPath string CaptiveCoreStoragePath string CaptiveCoreToml *ledgerbackend.CaptiveCoreToml @@ -108,16 +107,14 @@ type Config struct { // LocalCaptiveCoreEnabled returns true if configured to run // a local captive core instance for ingestion. func (c Config) LocalCaptiveCoreEnabled() bool { - // c.EnableCaptiveCore is true for both local and remote captive core - // and c.RemoteCaptiveCoreURL is always empty when running - // local captive core. - return c.EnableCaptiveCore && c.RemoteCaptiveCoreURL == "" + // c.RemoteCaptiveCoreURL is always empty when running local captive core. + return c.RemoteCaptiveCoreURL == "" } // RemoteCaptiveCoreEnabled returns true if configured to run // a remote captive core instance for ingestion. func (c Config) RemoteCaptiveCoreEnabled() bool { - return c.EnableCaptiveCore && c.RemoteCaptiveCoreURL != "" + return c.RemoteCaptiveCoreURL != "" } const ( @@ -741,7 +738,7 @@ func (s *system) resetStateVerificationErrors() { } func (s *system) updateCursor(ledgerSequence uint32) error { - if s.stellarCoreClient == nil || s.config.EnableCaptiveCore { + if s.stellarCoreClient == nil { return nil }