-
-
Notifications
You must be signed in to change notification settings - Fork 268
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
Slow startup with launch4j until FlatLaf v1.1 #319
Comments
Tried to reproduce this with launch4j 3.14 and FlatLaf Demos 1.0 and 1.1.2, but can't notice any difference. Could you share your launch4j configuration file? You could also try to build an exe from flatlaf-demo-1.1.2.jar and test whether startup is slow. |
I experience something similar, in most of my program launchs from Eclipse IDE, my program waits for FlatLaf to load a native DLL from temp directory. The weird thing is sometimes it does not wait. |
Here is my launch4j configuration file <?xml version="1.0" encoding="UTF-8"?>
<launch4jConfig>
<dontWrapJar>false</dontWrapJar>
<headerType>gui</headerType>
<jar>E:\Ph4ntom\Documents\Swappy\Swappy.jar</jar>
<outfile>E:\Ph4ntom\Documents\Swappy\Swappy.exe</outfile>
<errTitle></errTitle>
<cmdLine></cmdLine>
<chdir>.</chdir>
<priority>normal</priority>
<downloadUrl>http://java.com/download</downloadUrl>
<supportUrl></supportUrl>
<stayAlive>false</stayAlive>
<restartOnCrash>false</restartOnCrash>
<manifest></manifest>
<icon>E:\Ph4ntom\Documents\Swappy\img\icon128.ico</icon>
<singleInstance>
<mutexName>Swappy</mutexName>
<windowTitle>Swappy</windowTitle>
</singleInstance>
<jre>
<path>./jre</path>
<bundledJre64Bit>false</bundledJre64Bit>
<bundledJreAsFallback>false</bundledJreAsFallback>
<minVersion>11</minVersion>
<maxVersion></maxVersion>
<jdkPreference>jdkOnly</jdkPreference>
<runtimeBits>64/32</runtimeBits>
</jre>
</launch4jConfig> But I tried to reproduce this with FlatLaf Demo 1.1.2 and same thing, slow startup. I am using private JDK 11.0.11. |
@tanrikut that's interesting. Could you please start your program with the Eclipse debugger |
@Ph4ntom01 I can now reproduce the slow startup, but only with your private JDK 11.0.11, With other JDKs on my machine, it starts fast. Your private JDK seems to be incomplete. If I copy |
Seems that the initialization of the random number generator (
Resources:
To avoid slow startup, I'll replace |
Should be fixed in main branch. Please try the latest snapshot: |
Thanks for the information about |
From version 1.1 to 1.1.2, the execution of my newly exe program (converted with launch4j) is very slow.
Here is the code is use to set FlatLaf :
But everything is fine with version < 1.1
The thing is, I can't use embedded menu bar because I am obliged to use version 1.0
PS : this issue appears to only show when I convert my jar file to an exe file with launch4j.
The text was updated successfully, but these errors were encountered: