bazel-buildfarm icon indicating copy to clipboard operation
bazel-buildfarm copied to clipboard

How Do I Use the .jar Package to Migrate the Compiled Buildfarm to Different Types of CPUs?

Open RosyCheek opened this issue 1 year ago • 3 comments

In the /app-buildfarm/worker directory, I got these files: ''' buildfarm-shard-worker buildfarm-shard-worker-class.jar buildfarm-shard-worker-class.jar-0.params buildfarm-shard-worker-class.jar-1.params buildfarm-shard-worker.jar buildfarm-shard-worker.jar_manifest_proto buildfarm-shard-worker-native-header.jar buildfarm-shard-worker.repo_mapping buildfarm-shard-worker.runfiles buildfarm-shard-worker.runfiles_manifest ''' I've only used the executable "buildfarm-shard-worker" to start buildfarm-workers, and never used the .jar packages. Can these .jar packages properly used in place of "buildfarm-shard-worker"? How do I use them?

Could you please give me some guidance? It would be great to get a reply :)

RosyCheek avatar Oct 19 '24 18:10 RosyCheek

Those are simply the files required to launch the worker, embedded in a container root, and all, including the jar files, are used to run. Using "the .jar" file will not gain you anything specifically.

The title of your issue seems to imply a specific intent. Can you describe what problem you're trying to solve?

werkt avatar Oct 19 '24 20:10 werkt

Thank you for your reply!

I successfully deployed the buildfarm cluster on x86, but encountered some difficulties on ARM, as it seems that the ARM toolchain still needs to be adapted. Considering that they are all Java code, can we directly apply the. jar developed from x86 to ARM environment? How should I do it? 发自我的iPhone

------------------ Original ------------------ From: George Gensure @.> Date: Sun,Oct 20,2024 4:28 AM To: buildfarm/buildfarm @.> Cc: RosyCheek @.>, Author @.> Subject: Re: [buildfarm/buildfarm] How Do I Use the .jar Package to Migratethe Compiled Buildfarm to Different Types of CPUs? (Issue #1899)

Those are simply the files required to launch the worker, embedded in a container root, and all, including the jar files, are used to run. Using "the .jar" file will not gain you anything specifically.

The title of your issue seems to imply a specific intent. Can you describe what problem you're trying to solve?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

RosyCheek avatar Oct 19 '24 20:10 RosyCheek

You cannot build on x86_64 and run on arm64, as the host's toolchain is used for some JNI stuff (like blake3.c and friends).

jasonschroeder-sfdc avatar Oct 20 '24 19:10 jasonschroeder-sfdc

This is now supported in v2.12.0 released last Friday. The OCI images are multi-arch. You can build and push like this:

bazel run //container:public_push_buildfarm-server -- --tag latest --repository myregistry.com/path/buildfarm-server
bazel run //container:public_push_buildfarm-worker -- --tag latest --repository myregistry.com/path/buildfarm-worker

jasonschroeder-sfdc avatar Nov 04 '24 17:11 jasonschroeder-sfdc