WildFly does not shutdown after "Ctrl+C" on Java 15 (Windows)

455 views
Skip to first unread message

Wolfgang

unread,
Mar 14, 2021, 8:07:37 AM3/14/21
to WildFly
Hi,

when running WildFly with Java 15 (using "standalone.bat" or "standalone.ps1"), it does not shutdown on latest Windows 10 when "Ctrl+C" is pressed in the console.
It works with Java 1.8.


The output is:
12:54:53,005 INFO  [org.jboss.as] (Controller Boot Thread) WFLYSRV0025: WildFly Full 23.0.0.Final (WildFly Core 15.0.0.Final) started in 3242ms - Started 319 of 558 services (344 services are lazy, passive or on-demand)
12:54:53,008 INFO  [org.jboss.as] (Controller Boot Thread) WFLYSRV0060: Http management interface listening on http://127.0.0.1:9990/management
12:54:53,010 INFO  [org.jboss.as] (Controller Boot Thread) WFLYSRV0051: Admin console listening on http://127.0.0.1:9990
....CTRL+C is pressed.....
12:55:09,733 INFO  [org.jboss.as.server] (Thread-1) WFLYSRV0272: Suspending server
^C12:55:09,739 INFO  [org.jboss.as.ejb3] (Thread-1) WFLYEJB0493: Jakarta Enterprise Beans subsystem suspension complete
Batchvorgang abbrechen (J/N)? 12:55:09,746 INFO  [org.jboss.as.server] (Thread-1) WFLYSRV0220: Server shutdown has been requested via an OS signal
12:55:09,760 INFO  [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-3) WFLYJCA0010: Unbound data source [java:jboss/datasources/ExampleDS]
12:55:09,771 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-4) WFLYUT0008: Undertow HTTP listener default suspending
12:55:09,770 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-7) WFLYUT0008: Undertow HTTPS listener https suspending
12:55:09,773 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-8) WFLYUT0019: Host default-host stopping
12:55:09,778 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-4) WFLYUT0007: Undertow HTTP listener default stopped, was bound to 127.0.0.1:8080
12:55:09,778 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-7) WFLYUT0007: Undertow HTTPS listener https stopped, was bound to 127.0.0.1:8443
12:55:09,785 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-6) WFLYUT0004: Undertow 2.2.5.Final stopping
12:55:09,788 INFO  [org.jboss.as.mail.extension] (MSC service thread 1-5) WFLYMAIL0002: Unbound mail session [java:jboss/mail/Default]
12:55:09,787 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-1) WFLYJCA0019: Stopped Driver service with driver-name = h2
12:55:09,815 INFO  [org.jboss.as] (MSC service thread 1-1) WFLYSRV0050: WildFly Full 23.0.0.Final (WildFly Core 15.0.0.Final) stopped in 17ms


After the last output line, the command prompt is NOT shown, and the message "Batchvorgang abbrechen (J/N)?" ("Terminate batch job") should be printed, but this does not happen. The message is shown after "CTRL+C" is pressed another time.
This happens with all older WildFly versions that I tested, at least back to WildFly 11.

As I cannot create a thread dump using CTRL+BREAK in this situation, it might also be a Java problem. But a small sample console app was canceled by CTRL+C.

Is this a known issue? Is it worth a JIRA ticket?

Best regards

Wolfgang

rop...@redhat.com

unread,
Mar 15, 2021, 4:09:32 AM3/15/21
to WildFly
Hello Wolfgang,

   WildFly is not supported on JDK15. The latest supported JDK for WildFly is JDK 13.

Rio

Wolfgang Mayer

unread,
Mar 15, 2021, 1:19:20 PM3/15/21
to WildFly
This issue does not occur in my environment
Shutdown.png

Wolfgang

unread,
Mar 16, 2021, 3:28:06 PM3/16/21
to WildFly
OK, I could make it work: the environment variable "JAVA_HOME" has to be set:
JAVA_HOME=C:\Program Files\Java\jdk-15.0.2\

If it is not set, "java --version" still prints the same output as in your screenshot, but the hang occurs.

The command "where java" prints this:
C:\Program Files\Common Files\Oracle\Java\javapath\java.exe
C:\Program Files (x86)\Common Files\Oracle\Java\javapath\java.exe
Those files are 646 KB exe files.

I don't understand why this happens, but it works now.

Best regards

Wolfgang
Reply all
Reply to author
Forward
0 new messages