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

[GR-53590] Inconsistent Null return of getImplementationTitle() #8725

Open
javier-godoy opened this issue Apr 5, 2024 · 4 comments
Open
Assignees

Comments

@javier-godoy
Copy link

javier-godoy commented Apr 5, 2024

Describe the issue

Every time that I compile the application as a native image, a different set of classes return null for getPackage().getImplementationTitle().

All the packages are from JARs with a corresponding manifest, and running the application as a JAR produces the correct output.

Example manifest:

Manifest-Version: 1.0
Implementation-Title: Module A
Implementation-Version: 2.1.4-SNAPSHOT
Vaadin-Package-Version: 1
Build-Jdk-Spec: 1.8
Created-By: Maven Archiver 3.4.0
Implementation-Vendor: Vendor Name

Steps to reproduce the issue

I've not been able to extract this issue to a MCVE, so please feel free to ask me any details that you think may be relevant.

  1. mvn -Pnative native:compile
  2. target\application.exe
  3. The application has a getClasses service that return a set of classes.
  4. Take note of the result of
getClasses().forEach(clazz->{
	logger.warn("Title "+route.getNavigationTarget().getPackage().getImplementationTitle());
});

e.g.

Module A
null
Module C
  1. Close the application. Repeat steps 2-4 (without recompiling). The application produces the same output as in the previous step.
  2. Close the application. Repeat from step 1 (compile and run). The application produces different output (a different set of classes has null title, while others are correctly set). The ouput remains the same until the application is compiled again.
    e.g.
Module A
Module B
null

(There are no code changes nor dependency changes between each compilation)

  1. Repeat, repeat, repeat. Eventually, all modules log their title. 🤷‍♂️

Describe GraalVM and your environment:

  • GraalVM 21.0.2+13.1,
  • JDK major version: 21
  • OS: Windows 10.0.19045.4170
  • Architecture: x64

Also:

  • GraalVM: GraalVM 22+36.1
  • JDK major version: 22
  • OS: debian:bookworm-20240311-slim
  • Architecture: x64
@oubidar-Abderrahim
Copy link
Member

Thank you for reporting this, we'll try to reproduce the issue on our side

@oubidar-Abderrahim
Copy link
Member

Hi, could you please share a reproducer of this issue?

@javier-godoy
Copy link
Author

I think I have it. I'll seek approval from management to publish it, as it contains some code that hasn't been made public yet.

@javier-godoy
Copy link
Author

Please take a look at https://github.com/FlowingCode/AddonsDemo-graal8725

@oubidar-Abderrahim oubidar-Abderrahim changed the title Inconsistent Null return of getImplementationTitle() [GR-53590] Inconsistent Null return of getImplementationTitle() Apr 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants