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

ARM64 build for Test Server #1407

Open
dominik-pakosz opened this issue Sep 6, 2022 · 14 comments
Open

ARM64 build for Test Server #1407

dominik-pakosz opened this issue Sep 6, 2022 · 14 comments
Labels
enhancement User experience

Comments

@dominik-pakosz
Copy link

Expected Behavior

Test server running

Actual Behavior

Exception: qemu-x86_64: Could not open '/lib64/ld-linux-x86-64.so.2': No such file or directory thrown

Steps to Reproduce the Problem

  1. download latest release binary
  2. run ./temporal-test-server
  3. no profit - seeing error

Specifications

  • Version: latest - v1.16.0
  • Platform: MacOS ARM M1 Pro
@Spikhalskiy
Copy link
Contributor

Spikhalskiy commented Sep 6, 2022

We use Palantir Graal plugin for our native builds. Unfortunately, Palantir doesn't accept contributions or PRs to this project (they just get stale and closed) and doesn't actively develop it.
To fix this issue, this has to happen: palantir/gradle-graal#469

An official Graal plugin for Gradle doesn't have this problem, but it doesn't provision GraalVM and native-image and requires them to be installed and configured in the system. This makes the usage tricky in an open-source project until graalvm/native-build-tools#100 is resolved.
It looks like Gradle team is moving quite slow with an essential feature and dependency to make it happen: gradle/gradle#18028

Temporal has to fork Palantir Graal Plugin, merge required fixes and publish to the Sonatype repo at some moment if this becomes a burning issue.

@cv65kr
Copy link

cv65kr commented Sep 6, 2022

@Spikhalskiy thanks for explanation. I think is quite important topic, a lot companies started exchanging old intel macbooks with new one with arm. I am using Temporal and for me is a big problem because now I need to use CI which tooks ages and don't have a control.

Proper testing is basic of good application.

@bergundy
Copy link
Member

bergundy commented Sep 6, 2022

@cv65kr which download did you use?
Try this one: https://github.com/temporalio/sdk-java/releases/download/v1.16.0/temporal-test-server_1.16.0_macOS_amd64.tar.gz.
It's for Mac OS and should work with no additional steps, IIRC, with Rosetta.
Which SDK are you using? The TypeScript and Python SDKs both automatically install the right executable for you.

@cv65kr
Copy link

cv65kr commented Sep 6, 2022

The newest one for Temporal test server (In general I tried multiple versions).

PHP SDK - https://github.com/temporalio/sdk-php/blob/master/testing/src/Downloader.php#L29 looks like is not working out of box

@bergundy
Copy link
Member

bergundy commented Sep 6, 2022

Hmm.. the code you sent LGTM at first glance, can you check which file it downloads?

@Spikhalskiy
Copy link
Contributor

@cv65kr Could you download, unpack and try to run the specific artifact @bergundy pointed?
https://github.com/temporalio/sdk-java/releases/download/v1.16.0/temporal-test-server_1.16.0_macOS_amd64.tar.gz
This one is expected to work on M1. If it doesn't, let us know.

@dominik-pakosz
Copy link
Author

@Spikhalskiy I tried this artifact.
Result:

❯ docker-compose exec container-apache /bin/sh
# ./temporal-test-server
/bin/sh: 2: ./temporal-test-server: Exec format error
# exit
❯ docker-compose exec container-apache /bin/bash
root@a479b2380cc8:/src# ./temporal-test-server
bash: ./temporal-test-server: cannot execute binary file: Exec format error
root@a479b2380cc8:/src# exit
exit

Can you advise something more on that as it's not working as expected? 🤔

@Spikhalskiy
Copy link
Contributor

Spikhalskiy commented Sep 12, 2022

@bergundy Can you verify the same on your M1 Mac (https://github.com/temporalio/sdk-java/releases/download/v1.16.0/temporal-test-server_1.16.0_macOS_amd64.tar.gz)?
It works just fine for me on Intel Mac, so I would expect M1 to be fine too, but let's double-check.

@bergundy
Copy link
Member

@dominik-pakosz you’re running in a docker container not directly on mac. We don’t yet have test server arm builds for linux

@cv65kr
Copy link

cv65kr commented Sep 12, 2022

@bergundy is there any workaround for that? We are running tests inside arm dockers.
I can say that outside of docker working properly.

@bergundy
Copy link
Member

You can run your containers with --platform amd64 it slows things down but it works.
We want to support arm builds for both mac and linux, I hope we can get the done relatively soon.

@cv65kr
Copy link

cv65kr commented Sep 13, 2022

@bergundy is there any time frame when you expect releases?

@dominik-pakosz
Copy link
Author

Yea, I can't as I'm installing a lot of packages depending on arm64 or aarch64. From our SRE team point of view we should not go in this direction.
Is there any other solution?

@Spikhalskiy
Copy link
Contributor

Spikhalskiy commented Sep 13, 2022

This issue is blocked by palantir/gradle-graal#469 as an external dependency. Temporal doesn't typically provide time commitments for improvements.
We accept contributions and the Palantir Graal plugin we depend on to make it happen has an Apache license.

@Spikhalskiy Spikhalskiy changed the title Can not run test server on ARM M1 Pro MBP machine ARM64 build for Test Server Sep 13, 2022
@Spikhalskiy Spikhalskiy added the enhancement User experience label Sep 13, 2022
@mjameswh mjameswh removed their assignment Sep 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement User experience
Projects
None yet
Development

No branches or pull requests

5 participants