azureeventhub: remove deprecated processor v1 implementation#49772
azureeventhub: remove deprecated processor v1 implementation#49772zmoog wants to merge 24 commits intoelastic:mainfrom
Conversation
Design for removing the deprecated processor v1 from the azure-eventhub input in Filebeat, as tracked in elastic/ingest-dev#5424. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add docs/reference/filebeat/filebeat-input-azure-eventhub.md to the files affected list, covering removal of the v1 example section, updating section headings, intro paragraph, and storage_account_key description. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
11-task plan covering: file deletion, input.go routing update, config simplification, test updates, documentation, and dependency cleanup. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Prevent worktree contents from being tracked. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Remove v1_input.go, v1_input_test.go, file_persister_test.go, tracer.go, and azureeventhub_integration_test.go. These files implement the deprecated processor v1 using the azure-event-hubs-go/v3 SDK which Microsoft no longer supports.
…on warning - Remove go-autorest and devigned/tab imports - Remove environments map (only used by v1) - Remove tab.Register tracing call (v1-only) - Replace processor version switch with warning + always v2 - Add TODO for FIPS exclusion investigation Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Remove processor v1 validation paths from: - validateStorageAccountAuthForConnectionString - validateStorageAccountAuthForClientSecret - validateStorageAccountConfig - checkUnsupportedParams Update field comments to reflect v1 removal. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Convert v1 connection string tests to v2 config. Remove v1-specific client_secret and connection_string test cases. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Replace eventHubInputV1 and legacy eventhub.Event usage with messageDecoder.Decode() to test the same metrics behavior without depending on the deleted v1 types.
Remove TestGetAzureEnvironment, TestProcessEvents, commented-out TestNewInputDone, and defaultTestConfig. Clean up deprecated SDK imports. Add TestCreateWithProcessorV1FallsBackToV2 to verify the deprecation warning path. Keep fakeClient for use by metrics_test.go. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This constant was only used by the deleted v1 processor.
- Remove v1 example section from reference docs - Remove '(processor v2)' suffixes from section headings - Update intro paragraph to reference modern SDK - Remove tracing paragraph (tracer removed with v1) - Update storage_account_key description - Update README migration testing instructions Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Clean up Go module dependencies after removing processor v1 and its deprecated Azure SDK imports. Removed direct dependencies: - github.com/Azure/azure-event-hubs-go/v3 - github.com/Azure/azure-storage-blob-go - github.com/devigned/tab Note: go-autorest remains as a transitive dependency of other Beats packages.
|
This pull request doesn't have a |
🤖 GitHub commentsJust comment with:
|
|
This pull request does not have a backport label.
To fixup this pull request, you need to add the backport labels for the needed
|
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
TL;DRBuildkite failed in Remediation
Investigation detailsRoot Cause
This is a configuration/generated-artifact drift failure (not an infra outage): CI is enforcing that update-generated edits are committed. Evidence
Verification
Follow-upIf the file still flips after commit, pin and compare local/CI Go+mage versions used for Note 🔒 Integrity filtering filtered 2 itemsIntegrity filtering activated and filtered the following items during workflow execution.
What is this? | From workflow: PR Buildkite Detective Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not. |
📝 WalkthroughWalkthroughThis pull request removes the Azure Event Hub Processor v1 implementation and consolidates on v2. Changes include: deletion of v1-specific code files ( ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
x-pack/filebeat/input/azureeventhub/config.go (1)
387-423:⚠️ Potential issue | 🟠 MajorPreserve sovereign-cloud behavior for
resource_manager_endpointduring v1 fallback.Line 406 now derives the auto-generated storage connection string only from
authority_host. That means an existing v1 config that only sets deprecatedresource_manager_endpointfor Gov/China/Germany will validate, be upgraded to v2, and then get a public-cloud storage endpoint (core.windows.net). The downstream effect is broken checkpoint/container access after startup, which defeats the PR’s backward-compat path for those configs. Please either translateresource_manager_endpointinto the matching storage suffix here or reject that deprecated combination instead of silently accepting it.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@x-pack/filebeat/input/azureeventhub/config.go` around lines 387 - 423, The auto-generation in validateStorageAccountConfig currently always calls getStorageEndpointSuffix(conf.AuthorityHost) which causes v1 configs that only set the deprecated resource_manager_endpoint/OverrideEnvironment to get a public-cloud suffix; update validateStorageAccountConfig to detect the deprecated resource_manager_endpoint/OverrideEnvironment when conf.AuthorityHost is empty and either (a) translate that resource_manager_endpoint value into the corresponding storage endpoint suffix (and pass that into getStorageEndpointSuffix or a new translator) before building conf.SAConnectionString, or (b) if translation is not possible, reject the combination by returning an error that instructs the user to provide storage_account_connection_string or an explicit authority_host; reference validateStorageAccountConfig, getStorageEndpointSuffix, conf.AuthorityHost and the deprecated resource_manager_endpoint/OverrideEnvironment in the change.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Outside diff comments:
In `@x-pack/filebeat/input/azureeventhub/config.go`:
- Around line 387-423: The auto-generation in validateStorageAccountConfig
currently always calls getStorageEndpointSuffix(conf.AuthorityHost) which causes
v1 configs that only set the deprecated
resource_manager_endpoint/OverrideEnvironment to get a public-cloud suffix;
update validateStorageAccountConfig to detect the deprecated
resource_manager_endpoint/OverrideEnvironment when conf.AuthorityHost is empty
and either (a) translate that resource_manager_endpoint value into the
corresponding storage endpoint suffix (and pass that into
getStorageEndpointSuffix or a new translator) before building
conf.SAConnectionString, or (b) if translation is not possible, reject the
combination by returning an error that instructs the user to provide
storage_account_connection_string or an explicit authority_host; reference
validateStorageAccountConfig, getStorageEndpointSuffix, conf.AuthorityHost and
the deprecated resource_manager_endpoint/OverrideEnvironment in the change.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 12792d50-af3e-41ea-83d0-176d69aa1db0
⛔ Files ignored due to path filters (1)
go.sumis excluded by!**/*.sum
📒 Files selected for processing (19)
.github/dependabot.yml.gitignoreNOTICE.txtchangelog/fragments/1774907084-remove-azureeventhub-processor-v1.yamldocs/reference/filebeat/filebeat-input-azure-eventhub.mdgo.modx-pack/filebeat/include/list.gox-pack/filebeat/input/azureeventhub/README.mdx-pack/filebeat/input/azureeventhub/azureeventhub_integration_test.gox-pack/filebeat/input/azureeventhub/client_secret.gox-pack/filebeat/input/azureeventhub/config.gox-pack/filebeat/input/azureeventhub/config_test.gox-pack/filebeat/input/azureeventhub/file_persister_test.gox-pack/filebeat/input/azureeventhub/input.gox-pack/filebeat/input/azureeventhub/input_test.gox-pack/filebeat/input/azureeventhub/metrics_test.gox-pack/filebeat/input/azureeventhub/tracer.gox-pack/filebeat/input/azureeventhub/v1_input.gox-pack/filebeat/input/azureeventhub/v1_input_test.go
💤 Files with no reviewable changes (9)
- x-pack/filebeat/include/list.go
- .github/dependabot.yml
- x-pack/filebeat/input/azureeventhub/tracer.go
- x-pack/filebeat/input/azureeventhub/v1_input.go
- x-pack/filebeat/input/azureeventhub/input_test.go
- x-pack/filebeat/input/azureeventhub/azureeventhub_integration_test.go
- go.mod
- x-pack/filebeat/input/azureeventhub/v1_input_test.go
- x-pack/filebeat/input/azureeventhub/file_persister_test.go
Summary
processor_version: "v1"is configured, log a deprecation warning and fall back to v2 instead of erroringgo.mod,NOTICE.txt,dependabot.yml)TODO
"available versions: v1, v2"error messageTest plan
processor_version: "v2"(default) works unchangedprocessor_version: "v1"logs deprecation warning and falls back to v2processor_versionvalues are rejected🤖 Generated with Claude Code