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

Build failure on aarch64 #5633

Open
Dentrax opened this issue Dec 1, 2024 · 7 comments
Open

Build failure on aarch64 #5633

Dentrax opened this issue Dec 1, 2024 · 7 comments

Comments

@Dentrax
Copy link

Dentrax commented Dec 1, 2024

Description

Registry
Version
: 3.0.4
Persistence type: -

apicurio-registry-go-sdk build fails because there is hardcoded amd64 arch on the script, I guess.

But I don't know why there is a build failure for apicurio-registry-java-sdk and apicurio-registry-v2-java-sdk, after ~1 min.

If I pass -pl '!apicurio-registry-go-sdk', Maven logs says [ERROR] Could not find the selected project in the reactor: apicurio-registry-go-sdk. Maybe its because of missing module in the pom.xml? -DskipNonJavaGen=true worked a bit, but still fails for java projects.

Environment

aarch64

Steps to Reproduce

./mvnw clean install \
        -Pprod \
        -DskipTests \
        --no-snapshot-updates \
        --no-transfer-progress \
        --fail-fast -e -X
  1. Expect a success build on amd64
  2. Expect a build failure on aarch64
  3. Pass -DskipNonJavaGen=true and see apicurio-registry-go-sdk will SUCCESS but apicurio-registry-java-sdk and apicurio-registry-v2-java-sdk still fails
  4. Pass -DskipKiota=true and expect same error (as per recommendation by GPT)

If the error cannot be easily reproduced, make sure to fill in the Environment and Logs sections.
You can also try to reproduce the bug with a fresh Apicurio Registry instance.
-->

Expected vs Actual Behaviour

It should build for aarch64?

Logs

Log for apicurio-registry-go-sdk
Reactor Summary for apicurio-registry 3.0.4:

apicurio-registry .................................. SUCCESS [ 31.022 s]
apicurio-registry-config-definitions ............... SUCCESS [03:23 min]
apicurio-registry-common ........................... SKIPPED
apicurio-registry-config-index ..................... SKIPPED
apicurio-registry-config-index-deployment .......... SKIPPED
apicurio-registry-utils-kafka ...................... SUCCESS [03:23 min]
apicurio-registry-schema-util-common ............... SKIPPED
apicurio-registry-schema-util-json ................. SKIPPED
apicurio-registry-protobuf-schema-utilities ........ SUCCESS [01:26 min]
apicurio-registry-schema-util-protobuf ............. SKIPPED
apicurio-registry-schema-util-openapi .............. SKIPPED
apicurio-registry-schema-util-asyncapi ............. SKIPPED
apicurio-registry-schema-util-avro ................. SKIPPED
apicurio-registry-schema-util-graphql .............. SKIPPED
apicurio-registry-schema-util-kconnect ............. SKIPPED
apicurio-registry-schema-util-xml .................. SKIPPED
apicurio-registry-schema-util-wsdl ................. SKIPPED
apicurio-registry-schema-util-xsd .................. SKIPPED
apicurio-registry-java-sdk ......................... FAILURE [01:16 min]
apicurio-registry-v2-java-sdk ...................... FAILURE [01:07 min]
apicurio-registry-utils-tests ...................... SKIPPED
apicurio-registry-schema-util-provider ............. SKIPPED
apicurio-registry-utils-import-export .............. SKIPPED
apicurio-registry-schema-resolver .................. SKIPPED
apicurio-registry-serde-common ..................... SKIPPED
apicurio-registry-serde-kafka-common ............... SKIPPED
apicurio-registry-serde-avro-common ................ SKIPPED
apicurio-registry-avro-serde-kafka ................. SKIPPED
apicurio-registry-serde-common-protobuf ............ SKIPPED
apicurio-registry-protobuf-serde-kafka ............. SKIPPED
apicurio-registry-serde-common-jsonschema .......... SKIPPED
apicurio-registry-jsonschema-serde-kafka ........... SKIPPED
apicurio-registry-avro-serde-pulsar ................ SKIPPED
apicurio-registry-maven-plugin ..................... SKIPPED
apicurio-registry-app .............................. SKIPPED
apicurio-registry-utils-converter .................. SKIPPED
apicurio-registry-utils-tools ...................... SUCCESS [ 47.030 s]
apicurio-registry-utils-exportConfluent ............ SKIPPED
apicurio-registry-avro-serde-nats .................. SKIPPED
apicurio-registry-distro ........................... SUCCESS [  0.156 s]
apicurio-registry-distro-connect-converter ......... SKIPPED
apicurio-registry-distro-docker .................... SKIPPED
apicurio-registry-docs ............................. SKIPPED
apicurio-registry-docs-rest-api .................... SKIPPED
apicurio-registry-go-sdk ........................... FAILURE [  5.036 s]
Apicurio Registry Operator ......................... SUCCESS [  0.332 s]
Apicurio Registry Operator :: Model ................ SUCCESS [03:30 min]
Apicurio Registry Operator :: Controller ........... SKIPPED

BUILD FAILURE
Total time:  04:15 min (Wall Clock)
Finished at: 2024-12-01T11:18:04Z

Failed to execute goal org.codehaus.mojo:exec-maven-plugin:3.5.0:exec (default) on project apicurio-registry-go-sdk: Command execution failed. Process exited with an error: 2 (Exit value: 2)

org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:exec-maven-plugin:3.5.0:exec (default) on project apicurio-registry-go-sdk: Command execution failed.
  at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:333)
  at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)
  at org.apache.maven.lifecycle.internal.MojoExecutor.access$000 (MojoExecutor.java:75)
  at org.apache.maven.lifecycle.internal.MojoExecutor$1.run (MojoExecutor.java:162)
  at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute (DefaultMojosExecutionStrategy.java:39)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:159)
  at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:105)
  at org.apache.maven.lifecycle.internal.builder.multithreaded.MultiThreadedBuilder$1.call (MultiThreadedBuilder.java:193)
  at java.util.concurrent.FutureTask.run (FutureTask.java:264)
  at java.util.concurrent.Executors$RunnableAdapter.call (Executors.java:539)
  at java.util.concurrent.FutureTask.run (FutureTask.java:264)
  at java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1136)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:635)
  at java.lang.Thread.run (Thread.java:840)

Caused by: org.apache.commons.exec.ExecuteException: Process exited with an error: 2 (Exit value: 2)
  at org.apache.commons.exec.DefaultExecutor.executeInternal (DefaultExecutor.java:355)
  at org.apache.commons.exec.DefaultExecutor.execute (DefaultExecutor.java:253)
  at org.codehaus.mojo.exec.ExecMojo.executeCommandLine (ExecMojo.java:903)
  at org.codehaus.mojo.exec.ExecMojo.executeCommandLine (ExecMojo.java:863)
  at org.codehaus.mojo.exec.ExecMojo.execute (ExecMojo.java:454)
  at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:126)
  at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:328)
  at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)

Failed to execute goal io.kiota:kiota-maven-plugin:0.0.19:generate (v2) on project apicurio-registry-v2-java-sdk: Execution v2 of goal io.kiota:kiota-maven-plugin:0.0.19:generate failed. Error executing the Kiota command, exit code is 133.

org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal io.kiota:kiota-maven-plugin:0.0.19:generate (v2) on project apicurio-registry-v2-java-sdk: Execution v2 of goal io.kiota:kiota-maven-plugin:0.0.19:generate failed. Error executing the Kiota command, exit code is 133.
  at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:333)
  at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)
  at org.apache.maven.lifecycle.internal.MojoExecutor.access$000 (MojoExecutor.java:75)
  at org.apache.maven.lifecycle.internal.MojoExecutor$1.run (MojoExecutor.java:162)
  at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute (DefaultMojosExecutionStrategy.java:39)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:159)
  at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:105)
  at org.apache.maven.lifecycle.internal.builder.multithreaded.MultiThreadedBuilder$1.call (MultiThreadedBuilder.java:193)
  at java.util.concurrent.FutureTask.run (FutureTask.java:264)
  at java.util.concurrent.Executors$RunnableAdapter.call (Executors.java:539)
  at java.util.concurrent.FutureTask.run (FutureTask.java:264)
  at java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1136)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:635)
  at java.lang.Thread.run (Thread.java:840)

Caused by: java.lang.RuntimeException: Error executing the Kiota command, exit code is 133.
  at io.kiota.maven.plugin.KiotaMojo.runProcess (KiotaMojo.java:268)
  at io.kiota.maven.plugin.KiotaMojo.executeKiota (KiotaMojo.java:359)
  at io.kiota.maven.plugin.KiotaMojo.execute (KiotaMojo.java:228)
  at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:126
Logs for java-sdk
Reactor Summary for apicurio-registry 3.0.4:

apicurio-registry .................................. SUCCESS [ 33.210 s]
apicurio-registry-config-definitions ............... SUCCESS [03:19 min]
apicurio-registry-common ........................... SKIPPED
apicurio-registry-config-index ..................... SKIPPED
apicurio-registry-config-index-deployment .......... SKIPPED
apicurio-registry-utils-kafka ...................... SUCCESS [03:19 min]
apicurio-registry-schema-util-common ............... SKIPPED
apicurio-registry-schema-util-json ................. SKIPPED
apicurio-registry-protobuf-schema-utilities ........ SUCCESS [01:28 min]
apicurio-registry-schema-util-protobuf ............. SKIPPED
apicurio-registry-schema-util-openapi .............. SKIPPED
apicurio-registry-schema-util-asyncapi ............. SKIPPED
apicurio-registry-schema-util-avro ................. SKIPPED
apicurio-registry-schema-util-graphql .............. SKIPPED
apicurio-registry-schema-util-kconnect ............. SKIPPED
apicurio-registry-schema-util-xml .................. SKIPPED
apicurio-registry-schema-util-wsdl ................. SKIPPED
apicurio-registry-schema-util-xsd .................. SKIPPED
apicurio-registry-java-sdk ......................... FAILURE [01:14 min]
apicurio-registry-v2-java-sdk ...................... FAILURE [01:15 min]
apicurio-registry-utils-tests ...................... SKIPPED
apicurio-registry-schema-util-provider ............. SKIPPED
apicurio-registry-utils-import-export .............. SKIPPED
apicurio-registry-schema-resolver .................. SKIPPED
apicurio-registry-serde-common ..................... SKIPPED
apicurio-registry-serde-kafka-common ............... SKIPPED
apicurio-registry-serde-avro-common ................ SKIPPED
apicurio-registry-avro-serde-kafka ................. SKIPPED
apicurio-registry-serde-common-protobuf ............ SKIPPED
apicurio-registry-protobuf-serde-kafka ............. SKIPPED
apicurio-registry-serde-common-jsonschema .......... SKIPPED
apicurio-registry-jsonschema-serde-kafka ........... SKIPPED
apicurio-registry-avro-serde-pulsar ................ SKIPPED
apicurio-registry-maven-plugin ..................... SKIPPED
apicurio-registry-app .............................. SKIPPED
apicurio-registry-utils-converter .................. SKIPPED
apicurio-registry-utils-tools ...................... SUCCESS [ 47.363 s]
apicurio-registry-utils-exportConfluent ............ SKIPPED
apicurio-registry-avro-serde-nats .................. SKIPPED
apicurio-registry-distro ........................... SUCCESS [  0.141 s]
apicurio-registry-distro-connect-converter ......... SKIPPED
apicurio-registry-distro-docker .................... SKIPPED
apicurio-registry-docs ............................. SKIPPED
apicurio-registry-docs-rest-api .................... SKIPPED
apicurio-registry-go-sdk ........................... SUCCESS [  3.811 s]
Apicurio Registry Operator ......................... SUCCESS [  0.312 s]
Apicurio Registry Operator :: Model ................ SUCCESS [03:40 min]
Apicurio Registry Operator :: Controller ........... SKIPPED

BUILD FAILURE
Total time:  04:26 min (Wall Clock)
Finished at: 2024-12-01T11:46:07Z

Failed to execute goal io.kiota:kiota-maven-plugin:0.0.19:generate (default) on project apicurio-registry-java-sdk: Execution default of goal io.kiota:kiota-maven-plugin:0.0.19:generate failed: Error executing the Kiota command, exit code is 133.

org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal io.kiota:kiota-maven-plugin:0.0.19:generate (default) on project apicurio-registry-java-sdk: Execution default of goal io.kiota:kiota-maven-plugin:0.0.19:generate failed: Error executing the Kiota command, exit code is 133.
  at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:333)
  at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)
  at org.apache.maven.lifecycle.internal.MojoExecutor.access$000 (MojoExecutor.java:75)
  at org.apache.maven.lifecycle.internal.MojoExecutor$1.run (MojoExecutor.java:162)
  at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute (DefaultMojosExecutionStrategy.java:39)
  at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:159)
  at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:105)

Caused by: java.lang.RuntimeException: Error executing the Kiota command, exit code is 133.
  at io.kiota.maven.plugin.KiotaMojo.runProcess (KiotaMojo.java:268)
  at io.kiota.maven.plugin.KiotaMojo.executeKiota (KiotaMojo.java:359)
  at io.kiota.maven.plugin.KiotaMojo.execute (KiotaMojo.java:228)
@apicurio-bot
Copy link

apicurio-bot bot commented Dec 1, 2024

Thank you for reporting an issue!

Pinging @jsenko, @EricWittmann to respond or triage.

@carlesarnal
Copy link
Member

I build the project every day with a M1 mac with no issues. That said, my first recommendation would be to update your project, it seems you're using 3.0.4, and main is pointing to 3.0.5.

@Dentrax
Copy link
Author

Dentrax commented Dec 2, 2024

Nice, could you please point me to aarch64 build doc to see if i'm missing some dependencies?

@carlesarnal
Copy link
Member

Ah, I'm guessing in your case it's a Linux ARM. It works for me on Mac because we're changing the distribution in that case. There are no specific build instructions for it, since they're the same. It's simply a missing element in the script. @andreaTP do you have time to look into this?

@andreaTP
Copy link
Member

andreaTP commented Dec 5, 2024

Sorry for the delay 😓 swamped ...

@Dentrax can you confirm that your OS is Linux?

Kiota releases for arm64 support only for Mac: ref
And this issue seems to be relevant.

@EricWittmann
Copy link
Member

For clarity: the SDKs are all being created using code generation via a tool from Microsoft called Kiota. So if that tool does not run on linux arm64, then boom build failure.

@Dentrax
Copy link
Author

Dentrax commented Dec 5, 2024

Hey, yeah i was trying to build for aarch64 on Linux. (Not Apple M series)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Backlog
Development

No branches or pull requests

4 participants