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

Add arm64 support for binaries and docker images #2176

Merged
merged 2 commits into from
May 29, 2020
Merged

Add arm64 support for binaries and docker images #2176

merged 2 commits into from
May 29, 2020

Conversation

MrXinWang
Copy link
Contributor

@MrXinWang MrXinWang commented Apr 10, 2020

Which problem is this PR solving?

  • Platform support for arm64.

Resolves #1656

Short description of the changes

  • This commit adds building support for binaries and a Dockerfile for all-in-one container image.

Signed-off-by: Henry Wang Henry.Wang@arm.com

@MrXinWang MrXinWang requested a review from a team as a code owner April 10, 2020 03:57
@codecov
Copy link

codecov bot commented Apr 10, 2020

Codecov Report

Merging #2176 into master will increase coverage by 0.03%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2176      +/-   ##
==========================================
+ Coverage   96.11%   96.15%   +0.03%     
==========================================
  Files         219      219              
  Lines       10658    10658              
==========================================
+ Hits        10244    10248       +4     
+ Misses        356      353       -3     
+ Partials       58       57       -1     
Impacted Files Coverage Δ
...lugin/sampling/strategystore/adaptive/processor.go 100.00% <0.00%> (+0.79%) ⬆️
cmd/query/app/static_handler.go 85.83% <0.00%> (+1.66%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 06c8f7c...90b5c3f. Read the comment docs.

@MrXinWang MrXinWang changed the title Add arm64 support for binaries and allinone image Add arm64 support for binaries and docker images Apr 17, 2020
@MrXinWang MrXinWang requested a review from yurishkuro April 17, 2020 08:46
@MrXinWang
Copy link
Contributor Author

MrXinWang commented Apr 17, 2020

Resolved.
Hi @yurishkuro sorry to bother but I think the CI machine currently has come issues with the GPG key?
As it gives me output in https://travis-ci.org/github/jaegertracing/jaeger/jobs/676105369

gpg: key 86E50310: public key "Yarn Packaging <yarn@dan.cx>" imported
gpg: Total number processed: 1
gpg:               imported: 1  (RSA: 1)
gpg: Signature made Mon 09 Mar 2020 03:52:13 PM UTC using RSA key ID 69475BAA
gpg: BAD signature from "Yarn Packaging <yarn@dan.cx>"
> GPG signature for this Yarn release is invalid! This is BAD and may mean the release has been tampered with. It is strongly recommended that you report this to the Yarn developers.

@MrXinWang
Copy link
Contributor Author

MrXinWang commented May 21, 2020

Hi @yurishkuro, this PR has been a while after my "workaround" of this binary naming issue. Anything new about the "renaming the binaries consistently" or we leave it as it is? Could you please review again? Thanks!

@yurishkuro
Copy link
Member

I put it on the agenda for the next project meeting, but let me ping ppl directly to see if we can resolve faster: @pavolloffay @objectiser

@objectiser
Copy link
Contributor

@yurishkuro I'm fine with the rename, to avoid duplication.

@yurishkuro
Copy link
Member

@MrXinWang do you want to (a) rebase and (b) change Makefile to have a single name format for every binary?

@MrXinWang
Copy link
Contributor Author

Hi @yurishkuro.

All done :)) Please review again, thanks!

cmd/agent/Dockerfile Outdated Show resolved Hide resolved
Copy link
Member

@yurishkuro yurishkuro left a comment

Choose a reason for hiding this comment

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

Could you explain a bit how you tested this? Unfortunately, not all deployment steps are running on PR CI.

@MrXinWang
Copy link
Contributor Author

Hi @yurishkuro ! I tested on both my x86_64 and arm64 machine with following methods:

  1. Build all binaries and docker images by:
git clone https://github.com/jaegertracing/jaeger.git && cd jaeger
git submodule update --init --recursive
make install-tools
make docker
  1. Use file command to check if the binary has the right architecture. Use docker run command to test if all docker images can be successfully started.

@yurishkuro
Copy link
Member

Could you also try these steps?

  • ./scripts/travis/build-docker-images.sh
  • make build-all-platforms && ./scripts/travis/package-deploy.sh

Also, please add a change to the CHANGELOG describing the breaking changes to binary names in the tarball distributions.

We probably also need to change some docs, e.g.

@MrXinWang
Copy link
Contributor Author

@yurishkuro Tested these two commands, both worked well.

I have also added the related change to CHANGELOG.md

@yurishkuro
Copy link
Member

minor suggestion: in the future, try to avoid force-pushing a single commit, it makes it impossible to see incremental changes, e.g. in the last one the whole Makefile is shown as changed again. We squash commits before merge anyway.

Makefile Show resolved Hide resolved
Makefile Show resolved Hide resolved
@MrXinWang
Copy link
Contributor Author

MrXinWang commented May 27, 2020

minor suggestion: in the future, try to avoid force-pushing a single commit

Thanks for the suggestion, yes that makes sense. I did some rebase work and to make the commit tree clean (the CI magically failed if I commit in 2 commits, however if I squashed them it passes...), I used squash and force push again....sorry about that...I will try to avoid this from now on.

Copy link
Member

@yurishkuro yurishkuro left a comment

Choose a reason for hiding this comment

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

LGTM

@pavolloffay could you take another look in case I missed something?

CHANGELOG.md Outdated
@@ -7,6 +7,7 @@ Changes by Version
### Backend Changes

#### Breaking Changes
* Add arm64 support for binaries and docker images. Rename the released binary name format to <Name>-<OS>-<ARCH>, tarball name format to jaeger-<Version>-<OS>-<ARCH> ([#2176](https://github.com/jaegertracing/jaeger/pull/2176), [@MrXinWang](https://github.com/MrXinWang))
Copy link
Member

Choose a reason for hiding this comment

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

The released binary names or tarball names were not changed. Or am I missing something?

The build names via make build- is an internal detail, hence we don't have to list this as a breaking change.

Copy link
Member

Choose a reason for hiding this comment

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

Add arm64 support for binaries and make architecture configurable in docker images.

Copy link
Member

Choose a reason for hiding this comment

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

The tarball names have not changed, but binary names inside them have changed to include arch.

Copy link
Member

Choose a reason for hiding this comment

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

The binary names seem the same as before:

Packaging into jaeger-1.18.0-linux-amd64.tar.gz:
jaeger-1.18.0-linux-amd64/
jaeger-1.18.0-linux-amd64/jaeger-agent
jaeger-1.18.0-linux-amd64/jaeger-all-in-one
jaeger-1.18.0-linux-amd64/example-hotrod
jaeger-1.18.0-linux-amd64/jaeger-query
jaeger-1.18.0-linux-amd64/jaeger-ingester
jaeger-1.18.0-linux-amd64/jaeger-collector

Packaging into jaeger-1.18.0-darwin-amd64.tar.gz:
jaeger-1.18.0-darwin-amd64/
jaeger-1.18.0-darwin-amd64/jaeger-agent
jaeger-1.18.0-darwin-amd64/jaeger-all-in-one
jaeger-1.18.0-darwin-amd64/example-hotrod
jaeger-1.18.0-darwin-amd64/jaeger-query
jaeger-1.18.0-darwin-amd64/jaeger-ingester
jaeger-1.18.0-darwin-amd64/jaeger-collector

Packaging into jaeger-1.18.0-windows-amd64.tar.gz:
jaeger-1.18.0-windows-amd64/
jaeger-1.18.0-windows-amd64/jaeger-agent.exe
jaeger-1.18.0-windows-amd64/jaeger-ingester.exe
jaeger-1.18.0-windows-amd64/jaeger-all-in-one.exe
jaeger-1.18.0-windows-amd64/jaeger-query.exe
jaeger-1.18.0-windows-amd64/example-hotrod.exe
jaeger-1.18.0-windows-amd64/jaeger-collector.exe

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hi @pavolloffay ! I think now the x86_64 binaries are added an amd64 after linux, before they are just -linux. Arm64 and s390x ones are the same. This can be derived from the Makefile changes, for example: here.

Copy link
Member

Choose a reason for hiding this comment

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

maybe we strip all suffixes before creating tarballs?

Copy link
Contributor Author

@MrXinWang MrXinWang May 29, 2020

Choose a reason for hiding this comment

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

@yurishkuro I checked the scripts/travis/package-deploy.sh and it turns out that @pavolloffay is right, there is a staging step where we rename suffixes of all binaries (the make build outputs are indeed internal details)...So I think I can remove the breaking change in CHANGELOG.md and remove that part to minor changes.

Makefile Show resolved Hide resolved
@pavolloffay
Copy link
Member

@MrXinWang just a couple of nits. Overall it looks good.

MrXinWang added 2 commits May 29, 2020 09:29
This commit adds building support for binaries and
container images.

This commit also changes binary name format in Makefile
to make sure every binary has a single name format:
<BinaryName>-<OS>-<ARCH>

Signed-off-by: Henry Wang <Henry.Wang@arm.com>
Signed-off-by: Henry Wang <Henry.Wang@arm.com>
@MrXinWang
Copy link
Contributor Author

Thanks @pavolloffay. Rebased and added 90b5c3f to fix your request. Please take a look.

@pavolloffay
Copy link
Member

thanks @MrXinWang

@pavolloffay pavolloffay merged commit 2fdd1cd into jaegertracing:master May 29, 2020
@yonidavidson
Copy link

Hi, can anyone direct me to the Arm based Agent Docker image? we would like to run on AWS Graviton.

@jpkrohling jpkrohling added this to the Release 1.23.0 milestone Jun 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Jaeger agent arm support
6 participants