Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Beats to the current Sarama fork #41655

Merged
merged 38 commits into from
Nov 29, 2024
Merged

Conversation

khushijain21
Copy link
Contributor

@khushijain21 khushijain21 commented Nov 18, 2024

This PR updates Beats to the current version of Elastic's Sarama fork. It upgrades sarama version to 1.43.3.

The import path has been changed from github.com/Shopify/sarama to github.com/elastic/sarama due to change in ownership.

@khushijain21 khushijain21 requested review from a team as code owners November 18, 2024 06:42
@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label Nov 18, 2024
@khushijain21 khushijain21 requested a review from faec November 18, 2024 06:43
Copy link
Contributor

mergify bot commented Nov 18, 2024

This pull request is now in conflicts. Could you fix it? 🙏
To fixup this pull request, you can check out it locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/

git fetch upstream
git checkout -b kafka upstream/kafka
git merge upstream/main
git push upstream kafka

Copy link
Contributor

mergify bot commented Nov 18, 2024

This pull request does not have a backport label.
If this is a bug or security fix, could you label this PR @khushijain21? 🙏.
For such, you'll need to label your PR with:

  • The upcoming major version of the Elastic Stack
  • The upcoming minor version of the Elastic Stack (if you're not pushing a breaking change)

To fixup this pull request, you need to add the backport labels for the needed
branches, such as:

  • backport-8./d is the label to automatically backport to the 8./d branch. /d is the digit

Copy link
Contributor

mergify bot commented Nov 18, 2024

backport-8.x has been added to help with the transition to the new branch 8.x.
If you don't need it please use backport-skip label and remove the backport-8.x label.

@mergify mergify bot added the backport-8.x Automated backport to the 8.x branch with mergify label Nov 18, 2024
@khushijain21 khushijain21 added Team:Elastic-Agent-Data-Plane Label for the Agent Data Plane team and removed backport-8.x Automated backport to the 8.x branch with mergify labels Nov 18, 2024
@elasticmachine
Copy link
Collaborator

Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane)

@botelastic botelastic bot removed the needs_team Indicates that the issue/PR needs a Team:* label label Nov 18, 2024
@mergify mergify bot added the backport-8.x Automated backport to the 8.x branch with mergify label Nov 18, 2024
@shmsr
Copy link
Member

shmsr commented Nov 18, 2024

qq: Why don't we directly point to the fork i.e., github.com/elastic/sarama@beats-fork? Asking this because we have faced some problem with this before.

See the PR description: #39840 (comment). As it was breaking for the apm team, upon investigation, I found the problem and that's why we moved to using the fork directly. If required, I can also send the related Slack conversation in Slack.

So basically what'd happen is anyone using beats as a dependency, the replace directive won't work for them.

@khushijain21
Copy link
Contributor Author

I think we can. @faec could you please confirm? Any particular reason we don't directly use the fork

@faec
Copy link
Contributor

faec commented Nov 18, 2024

could you please confirm? Any particular reason we don't directly use the fork

I don't see a reason we can't, but the reason we don't is probably that we would prefer to revert to upstream someday. Though there admittedly has not been much movement on that, so I don't think that's an overriding concern if it simplifies dependency handling overall.

go.mod Outdated Show resolved Hide resolved
@mauri870
Copy link
Member

As a side note, you can automate changes in import paths using gofmt:

gofmt -w -r '"github.com/Shopify/sarama" -> "github.com/IBM/sarama"' .

@khushijain21 khushijain21 requested a review from faec November 20, 2024 14:37
Copy link
Contributor

mergify bot commented Nov 26, 2024

This pull request is now in conflicts. Could you fix it? 🙏
To fixup this pull request, you can check out it locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/

git fetch upstream
git checkout -b kafka upstream/kafka
git merge upstream/main
git push upstream kafka

@@ -6,7 +6,8 @@ ENV TC apache-tomcat-${TOMCAT_VERSION}
ARG JOLOKIA_VERSION

RUN apk update && \
apk add curl openssl ca-certificates bash
apk upgrade --no-cache && \
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It uses an old version of curl which fails when you build locally. So this explicit upgrade was required

Copy link
Contributor

mergify bot commented Nov 28, 2024

This pull request is now in conflicts. Could you fix it? 🙏
To fixup this pull request, you can check out it locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/

git fetch upstream
git checkout -b kafka upstream/kafka
git merge upstream/main
git push upstream kafka

@khushijain21
Copy link
Contributor Author

I think we should also update the kafka application version in our integration tests. I plan to do this in a separate PR.

@khushijain21 khushijain21 requested a review from rdner November 28, 2024 13:52
Copy link
Member

@mauri870 mauri870 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@khushijain21 khushijain21 requested a review from cmacknz November 28, 2024 15:04
@khushijain21 khushijain21 enabled auto-merge (squash) November 29, 2024 04:09
@khushijain21 khushijain21 removed the backport-8.x Automated backport to the 8.x branch with mergify label Nov 29, 2024
@pierrehilbert pierrehilbert added the backport-skip Skip notification from the automated backport with mergify label Nov 29, 2024
Copy link
Contributor

mergify bot commented Nov 29, 2024

This pull request does not have a backport label.
If this is a bug or security fix, could you label this PR @khushijain21? 🙏.
For such, you'll need to label your PR with:

  • The upcoming major version of the Elastic Stack
  • The upcoming minor version of the Elastic Stack (if you're not pushing a breaking change)

To fixup this pull request, you need to add the backport labels for the needed
branches, such as:

  • backport-8./d is the label to automatically backport to the 8./d branch. /d is the digit

Copy link
Contributor

mergify bot commented Nov 29, 2024

backport-8.x has been added to help with the transition to the new branch 8.x.
If you don't need it please use backport-skip label and remove the backport-8.x label.

@mergify mergify bot added the backport-8.x Automated backport to the 8.x branch with mergify label Nov 29, 2024
@khushijain21 khushijain21 merged commit 4942592 into elastic:main Nov 29, 2024
142 checks passed
@pierrehilbert pierrehilbert removed the backport-8.x Automated backport to the 8.x branch with mergify label Nov 29, 2024
mergify bot pushed a commit that referenced this pull request Nov 29, 2024
- Update Beats to the current sarama fork

(cherry picked from commit 4942592)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-skip Skip notification from the automated backport with mergify Team:Elastic-Agent-Data-Plane Label for the Agent Data Plane team Team:Obs-InfraObs Label for the Observability Infrastructure Monitoring team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants