-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
Jenkins 2.401
android-signing-plugin 2.2.5
After upgrading JDK in docker agent to jdk17, the androd signing step fails with error:
[SignApksBuilder] signing APK SignApksBuilder-out/zipalign/app-release-unsigned-7554420109451956305.apk
FATAL: Remote call on JNLP4-connect connection from _gateway/172.17.0.1:41772 failed
java.lang.ExceptionInInitializerError: Exception java.lang.IllegalAccessError: class com.android.apksig.internal.apk.v1.V1SchemeSigner (in unnamed module @0xdd9a76c) cannot access class sun.security.x509.AlgorithmId (in module java.base) because module java.base does not export sun.security.x509 to unnamed module @0xdd9a76c [in thread "pool-1-thread-251 for JNLP4-connect connection to _gateway/172.17.0.1:50000 id=16696"]
at com.android.apksig.internal.apk.v1.V1SchemeSigner.getSupportedAlgorithmId(V1SchemeSigner.java:625)
at com.android.apksig.internal.apk.v1.V1SchemeSigner.<clinit>(V1SchemeSigner.java:541)
Also: hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from _gateway/172.17.0.1:41772
at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1784)
at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:356)
at hudson.remoting.Channel.call(Channel.java:1000)
at hudson.FilePath.act(FilePath.java:1192)
at hudson.FilePath.act(FilePath.java:1181)
at org.jenkinsci.plugins.androidsigning.SignApksBuilder.perform(SignApksBuilder.java:359)
at jenkins.tasks.SimpleBuildStep.perform(SimpleBuildStep.java:123)
at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:80)
at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:818)
at hudson.model.Build$BuildExecution.build(Build.java:199)
at hudson.model.Build$BuildExecution.doRun(Build.java:164)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:526)
at hudson.model.Run.execute(Run.java:1900)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
at hudson.model.ResourceController.execute(ResourceController.java:101)
at hudson.model.Executor.run(Executor.java:442)
Caused: java.lang.NoClassDefFoundError: Could not initialize class com.android.apksig.internal.apk.v1.V1SchemeSigner
at com.android.apksig.DefaultApkSignerEngine.<init>(DefaultApkSignerEngine.java:149)
at com.android.apksig.DefaultApkSignerEngine.<init>(DefaultApkSignerEngine.java:52)
at com.android.apksig.DefaultApkSignerEngine$Builder.build(DefaultApkSignerEngine.java:902)
at com.android.apksig.ApkSigner.sign(ApkSigner.java:260)
at com.android.apksig.ApkSigner.sign(ApkSigner.java:179)
at org.jenkinsci.plugins.androidsigning.SignApksBuilder$SignApkCallable.invoke(SignApksBuilder.java:510)
at org.jenkinsci.plugins.androidsigning.SignApksBuilder$SignApkCallable.invoke(SignApksBuilder.java:464)
at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3578)
at hudson.remoting.UserRequest.perform(UserRequest.java:211)
at hudson.remoting.UserRequest.perform(UserRequest.java:54)
at hudson.remoting.Request$2.run(Request.java:376)
at hudson.remoting.InterceptingExecutorService.lambda$wrap$0(InterceptingExecutorService.java:78)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at hudson.remoting.Engine$1.lambda$newThread$0(Engine.java:121)
at java.base/java.lang.Thread.run(Thread.java:833)
Caused: java.io.IOException: Remote call on JNLP4-connect connection from _gateway/172.17.0.1:41772 failed
at hudson.remoting.Channel.call(Channel.java:1004)
at hudson.FilePath.act(FilePath.java:1192)
at hudson.FilePath.act(FilePath.java:1181)
at org.jenkinsci.plugins.androidsigning.SignApksBuilder.perform(SignApksBuilder.java:359)
at jenkins.tasks.SimpleBuildStep.perform(SimpleBuildStep.java:123)
at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:80)
at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:818)
at hudson.model.Build$BuildExecution.build(Build.java:199)
at hudson.model.Build$BuildExecution.doRun(Build.java:164)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:526)
at hudson.model.Run.execute(Run.java:1900)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
at hudson.model.ResourceController.execute(ResourceController.java:101)
at hudson.model.Executor.run(Executor.java:442)
Then I tried to build the plugin's master branch with temurin jdk 17( on GitHub Actions actually: https://github.com/fcitx5-android/jenkins-android-signing-plugin/actions/runs/4771640436/jobs/8483688184 ), which yeilds following error:
Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:2.10.1:javadoc (default) on project android-signing: An error has occurred in JavaDocs report generation:
Exit code: 1 - Loading source files for package org.jenkinsci.plugins.androidsigning...
Constructing Javadoc information...
/home/runner/work/jenkins-android-signing-plugin/jenkins-android-signing-plugin/src/main/java/org/jenkinsci/plugins/androidsigning/SignedApkMappingStrategy.java:3: error: package com.sun.org.apache.xpath.internal.operations is not visible
import com.sun.org.apache.xpath.internal.operations.Bool;
^
(package com.sun.org.apache.xpath.internal.operations is declared in module java.xml, which does not export it)
Error: [ERROR] 1 errorCommand line was: /opt/hostedtoolcache/Java_Temurin-Hotspot_jdk/17.0.6-10/x64/bin/javadoc @options @packagesRefer to the generated Javadoc files in '/home/runner/work/jenkins-android-signing-plugin/jenkins-android-signing-plugin/target/site/apidocs' dir.
-> [Help 1]To see the full stack trace of the errors, re-run Maven with the -e switch.
Re-run Maven using the -X switch to enable full debug logging.For more information about the errors and possible solutions, please read the following articles:
[Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
Since the plugin's latest version 2.2.5 on its website ( https://plugins.jenkins.io/android-signing/ ) was released 6 years ago (2017-07-13), and there are some useful changes in the master branch, is it the time to have a new release?