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

Exception after Upgrading to 4.0.2/4.0.3 -> Malformed \uxxxx encoding #913

Closed
c-koell opened this issue Jan 17, 2024 · 7 comments
Closed
Labels
bug Something isn't working

Comments

@c-koell
Copy link

c-koell commented Jan 17, 2024

Describe the bug
After Upgrading to 4.0.2 or 4.0.3 from 4.0.0 we see follewing Stracktace in a Maven Project Job

ERROR: Processing failed due to a bug in the code. Please report this to the issue tracker (https://jenkins.io/redirect/report-an-issue).
java.lang.IllegalArgumentException: Malformed \uxxxx encoding.
	at java.base/java.util.Properties.loadConvert(Unknown Source)
	at java.base/java.util.Properties.load0(Unknown Source)
	at java.base/java.util.Properties.load(Unknown Source)
	at org.jfrog.build.extractor.BuildInfoExtractorUtils.searchAdditionalPropertiesFile(BuildInfoExtractorUtils.java:113)
	at org.jfrog.build.extractor.BuildInfoExtractorUtils.mergePropertiesWithSystemAndPropertyFile(BuildInfoExtractorUtils.java:70)
	at org.jfrog.build.extractor.maven.resolver.ResolutionHelper.init(ResolutionHelper.java:31)
	at org.jfrog.build.extractor.maven.resolver.ArtifactoryEclipseResolversHelper.initResolutionHelper(ArtifactoryEclipseResolversHelper.java:67)
	at org.jfrog.build.extractor.maven.resolver.ArtifactoryEclipseResolversHelper.getResolutionRepositories(ArtifactoryEclipseResolversHelper.java:45)
	at org.jfrog.build.extractor.maven.resolver.ArtifactoryEclipseArtifactResolver.enforceResolutionRepositories(ArtifactoryEclipseArtifactResolver.java:36)
	at org.jfrog.build.extractor.maven.resolver.ArtifactoryEclipseArtifactResolver.resolveArtifacts(ArtifactoryEclipseArtifactResolver.java:53)
	at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolveArtifact(DefaultArtifactResolver.java:212)
	at org.eclipse.aether.internal.impl.DefaultRepositorySystem.resolveArtifact(DefaultRepositorySystem.java:272)
	at org.apache.maven.project.ProjectModelResolver.resolveModel(ProjectModelResolver.java:192)
	at org.apache.maven.project.ProjectModelResolver.resolveModel(ProjectModelResolver.java:242)
	at org.apache.maven.model.building.DefaultModelBuilder.readParentExternally(DefaultModelBuilder.java:1077)
	at org.apache.maven.model.building.DefaultModelBuilder.readParent(DefaultModelBuilder.java:853)
	at org.apache.maven.model.building.DefaultModelBuilder.build(DefaultModelBuilder.java:344)
	at org.apache.maven.model.building.DefaultModelBuilder.build(DefaultModelBuilder.java:252)
	at org.apache.maven.project.DefaultProjectBuilder.build(DefaultProjectBuilder.java:448)
	at org.apache.maven.project.DefaultProjectBuilder.build(DefaultProjectBuilder.java:414)
	at org.apache.maven.project.DefaultProjectBuilder.build(DefaultProjectBuilder.java:377)
	at org.jfrog.build.extractor.maven.ArtifactoryProjectBuilder.build(ArtifactoryProjectBuilder.java:47)
	at hudson.maven.MavenEmbedder.buildProjects(MavenEmbedder.java:370)
	at hudson.maven.MavenEmbedder.readProjects(MavenEmbedder.java:340)
	at hudson.maven.MavenModuleSetBuild$PomParser.invoke(MavenModuleSetBuild.java:1330)
	at hudson.maven.MavenModuleSetBuild$PomParser.invoke(MavenModuleSetBuild.java:1124)
	at hudson.FilePath.act(FilePath.java:1198)
	at hudson.FilePath.act(FilePath.java:1181)
	at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.parsePoms(MavenModuleSetBuild.java:985)
	at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.doRun(MavenModuleSetBuild.java:689)
	at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:526)
	at hudson.model.Run.execute(Run.java:1895)
	at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:543)
	at hudson.model.ResourceController.execute(ResourceController.java:101)
	at hudson.model.Executor.run(Executor.java:442)

To Reproduce
Update to latest Plugin Version

Versions

  • Jenkins Artifactory plugin version: 4.0.3
  • Jenkins operating system: Windows Server 2019
  • Artifactory Version: 7.71.9
@c-koell c-koell added the bug Something isn't working label Jan 17, 2024
@Or-Geva
Copy link

Or-Geva commented Jan 18, 2024

@c-koell, thank you for your report. I wasn't able to replicate this issue. Could you please clear the cache for all agents? Additionally, providing more information about your Maven project script would be helpful in gaining a better understanding of the issue.

@c-koell
Copy link
Author

c-koell commented Jan 19, 2024

HI @Or-Geva can you tell me how i clear the cache please ?

What information do you need ?
The Job is a normal Maven Project Job where we have configured two things regarding artifactory

  1. Artifactory Release Management (Enable Artifactory release management)
  2. A Post Build Action (Deploy artifacts to Artifactory) to deploy the artifacts to our artifactory

@Or-Geva
Copy link

Or-Geva commented Jan 19, 2024

@c-koell, navigate to the workspace directory inside the Jenkins home directory. You will find the cache for all your agents there. Remove the directory related to the Maven Project agent and then restart the job.
Is both the master and the agent operating on a Windows environment?

Moreover, we strongly recommend switching over from the old Jenkins Artifactory Plugin to the new next-gen Jenkins JFrog Plugin to avoid such issues.

@c-koell
Copy link
Author

c-koell commented Jan 19, 2024

The master and one agent are both on Windows .. yes

Okay but i think it is not so easy to switch to the new plugin :-) we have a lot of jobs ...

@c-koell
Copy link
Author

c-koell commented Jan 19, 2024

I have cleared all the folders under d:\Jenkins\cache\artifactory-plugin and now it works :-)

@eyalbe4 eyalbe4 closed this as completed Jan 19, 2024
@Or-Geva
Copy link

Or-Geva commented Jan 19, 2024

Great, thank you for your time.

@rzo1
Copy link

rzo1 commented Jun 27, 2024

It also happens for us from time to time (even if we clear the build caches). Moving to the "new" plugin isn't an option because we are not using pipeline jobs (yet) and it doesn't seem to work with "normal" Maven jobs on Jenkins.

I am wondering if we can add a workaround in https://github.com/jfrog/build-info/blame/b82ee0627bd002fc987e85898d3ba48f950a6366/build-info-extractor/src/main/java/org/jfrog/build/extractor/BuildInfoExtractorUtils.java#L116C15-L116C15 to (silently?) ignore that exception instead of throwing a runtime exception?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants