-
Bug
-
Resolution: Cannot Reproduce
-
P4
-
None
-
fx2.1
I'm am unable to start JavaFX applications on MacOS. The Java process is started, but then hangs without showing anything on the screen.
This happens on Lion with JavaFX 2.1.0 with both the latest JDK7 (build 1.7.0_04-ea-b11) beta and JDK6 (1.6.0_29-b11-402-11D50b).
I have tried several example applications, including the sample application of Netbeans 7.1.
The issue looks similar to http://javafx-jira.kenai.com/browse/RT-15698, but I'm not embedding JavaFX.
This is example code generated by Netbeans 7.1 that fails to start:
{code}
public class Test extends Application {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage primaryStage) {
primaryStage.setTitle("Hello World!");
Button btn = new Button();
btn.setText("Say 'Hello World'");
btn.setOnAction(new EventHandler<ActionEvent>() {
@Override
public void handle(ActionEvent event) {
System.out.println("Hello World!");
}
});
StackPane root = new StackPane();
root.getChildren().add(btn);
primaryStage.setScene(new Scene(root, 300, 250));
primaryStage.show();
}
}
{code}
This is the thread dump of the process:
Full thread dump Java HotSpot(TM) 64-Bit Server VM (23.0-b14 mixed mode):
"Attach Listener" daemon prio=5 tid=0x00007f8176099800 nid=0x16efeb000 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Prism Font Disposer" daemon prio=5 tid=0x00007f817320c800 nid=0x183c3c000 in Object.wait() [0x0000000183c3b000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x000000014ec79f98> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:135)
- locked <0x000000014ec79f98> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:151)
at com.sun.t2k.Disposer.run(Disposer.java:71)
at java.lang.Thread.run(Thread.java:722)
"Thread-3" daemon prio=5 tid=0x00007f81750b5000 nid=0x181e3a000 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"JavaFX Application Thread" prio=5 tid=0x00007f8173869000 nid=0x7fff7b7b7960 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Disposer" daemon prio=5 tid=0x00007f81740eb800 nid=0x181735000 in Object.wait() [0x0000000181734000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x000000014e700a28> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:135)
- locked <0x000000014e700a28> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:151)
at com.sun.glass.utils.Disposer.run(Disposer.java:69)
at java.lang.Thread.run(Thread.java:722)
"QuantumRenderer-0" daemon prio=5 tid=0x00007f8173826800 nid=0x16f99c000 waiting on condition [0x000000016f99b000]
java.lang.Thread.State: WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x000000014e6fec40> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:186)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2043)
at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442)
at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1043)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1103)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:97)
at java.lang.Thread.run(Thread.java:722)
"JavaFX-Launcher" prio=5 tid=0x00007f81730a0000 nid=0x16f899000 waiting on condition [0x000000016f898000]
java.lang.Thread.State: WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x000000014e704ae8> (a java.util.concurrent.CountDownLatch$Sync)
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:186)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:834)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.doAcquireSharedInterruptibly(AbstractQueuedSynchronizer.java:994)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireSharedInterruptibly(AbstractQueuedSynchronizer.java:1303)
at java.util.concurrent.CountDownLatch.await(CountDownLatch.java:236)
at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:326)
at com.sun.javafx.application.LauncherImpl.access$000(LauncherImpl.java:47)
at com.sun.javafx.application.LauncherImpl$1.run(LauncherImpl.java:115)
at java.lang.Thread.run(Thread.java:722)
"Service Thread" daemon prio=5 tid=0x00007f8175006000 nid=0x16f620000 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C1 CompilerThread3" daemon prio=5 tid=0x00007f8175005800 nid=0x16f51d000 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread2" daemon prio=5 tid=0x00007f8176037000 nid=0x16f41a000 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread1" daemon prio=5 tid=0x00007f817402f000 nid=0x16f317000 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread0" daemon prio=5 tid=0x00007f817402d000 nid=0x16f214000 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Signal Dispatcher" daemon prio=5 tid=0x00007f8174022800 nid=0x16f111000 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Finalizer" daemon prio=5 tid=0x00007f8174016000 nid=0x16edf2000 in Object.wait() [0x000000016edf1000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x000000014e5693a0> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:135)
- locked <0x000000014e5693a0> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:151)
at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:177)
"Reference Handler" daemon prio=5 tid=0x00007f8174015800 nid=0x16ecef000 in Object.wait() [0x000000016ecee000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x000000014e568c78> (a java.lang.ref.Reference$Lock)
at java.lang.Object.wait(Object.java:503)
at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:133)
- locked <0x000000014e568c78> (a java.lang.ref.Reference$Lock)
"main" prio=5 tid=0x00007f8173034800 nid=0x10e723000 waiting on condition [0x000000010e721000]
java.lang.Thread.State: WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x000000014e6f3f80> (a java.util.concurrent.CountDownLatch$Sync)
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:186)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:834)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.doAcquireSharedInterruptibly(AbstractQueuedSynchronizer.java:994)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireSharedInterruptibly(AbstractQueuedSynchronizer.java:1303)
at java.util.concurrent.CountDownLatch.await(CountDownLatch.java:236)
at com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:134)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at com.javafx.main.Main.launchApp(Main.java:453)
at com.javafx.main.Main.main(Main.java:601)
"VM Thread" prio=5 tid=0x00007f8174013000 nid=0x16ebec000 runnable
"GC task thread#0 (ParallelGC)" prio=5 tid=0x00007f8173041800 nid=0x168ff9000 runnable
"GC task thread#1 (ParallelGC)" prio=5 tid=0x00007f8173042000 nid=0x1690fc000 runnable
"GC task thread#2 (ParallelGC)" prio=5 tid=0x00007f8173043000 nid=0x1691ff000 runnable
"GC task thread#3 (ParallelGC)" prio=5 tid=0x00007f8173043800 nid=0x169302000 runnable
"GC task thread#4 (ParallelGC)" prio=5 tid=0x00007f8173044000 nid=0x169405000 runnable
"GC task thread#5 (ParallelGC)" prio=5 tid=0x00007f8175800000 nid=0x169508000 runnable
"GC task thread#6 (ParallelGC)" prio=5 tid=0x00007f8173044800 nid=0x16960b000 runnable
"GC task thread#7 (ParallelGC)" prio=5 tid=0x00007f8173045800 nid=0x16970e000 runnable
"VM Periodic Task Thread" prio=5 tid=0x00007f817500f000 nid=0x16f723000 waiting on condition
JNI global references: 268
This happens on Lion with JavaFX 2.1.0 with both the latest JDK7 (build 1.7.0_04-ea-b11) beta and JDK6 (1.6.0_29-b11-402-11D50b).
I have tried several example applications, including the sample application of Netbeans 7.1.
The issue looks similar to http://javafx-jira.kenai.com/browse/RT-15698, but I'm not embedding JavaFX.
This is example code generated by Netbeans 7.1 that fails to start:
{code}
public class Test extends Application {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage primaryStage) {
primaryStage.setTitle("Hello World!");
Button btn = new Button();
btn.setText("Say 'Hello World'");
btn.setOnAction(new EventHandler<ActionEvent>() {
@Override
public void handle(ActionEvent event) {
System.out.println("Hello World!");
}
});
StackPane root = new StackPane();
root.getChildren().add(btn);
primaryStage.setScene(new Scene(root, 300, 250));
primaryStage.show();
}
}
{code}
This is the thread dump of the process:
Full thread dump Java HotSpot(TM) 64-Bit Server VM (23.0-b14 mixed mode):
"Attach Listener" daemon prio=5 tid=0x00007f8176099800 nid=0x16efeb000 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Prism Font Disposer" daemon prio=5 tid=0x00007f817320c800 nid=0x183c3c000 in Object.wait() [0x0000000183c3b000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x000000014ec79f98> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:135)
- locked <0x000000014ec79f98> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:151)
at com.sun.t2k.Disposer.run(Disposer.java:71)
at java.lang.Thread.run(Thread.java:722)
"Thread-3" daemon prio=5 tid=0x00007f81750b5000 nid=0x181e3a000 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"JavaFX Application Thread" prio=5 tid=0x00007f8173869000 nid=0x7fff7b7b7960 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Disposer" daemon prio=5 tid=0x00007f81740eb800 nid=0x181735000 in Object.wait() [0x0000000181734000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x000000014e700a28> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:135)
- locked <0x000000014e700a28> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:151)
at com.sun.glass.utils.Disposer.run(Disposer.java:69)
at java.lang.Thread.run(Thread.java:722)
"QuantumRenderer-0" daemon prio=5 tid=0x00007f8173826800 nid=0x16f99c000 waiting on condition [0x000000016f99b000]
java.lang.Thread.State: WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x000000014e6fec40> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:186)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2043)
at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442)
at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1043)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1103)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:97)
at java.lang.Thread.run(Thread.java:722)
"JavaFX-Launcher" prio=5 tid=0x00007f81730a0000 nid=0x16f899000 waiting on condition [0x000000016f898000]
java.lang.Thread.State: WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x000000014e704ae8> (a java.util.concurrent.CountDownLatch$Sync)
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:186)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:834)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.doAcquireSharedInterruptibly(AbstractQueuedSynchronizer.java:994)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireSharedInterruptibly(AbstractQueuedSynchronizer.java:1303)
at java.util.concurrent.CountDownLatch.await(CountDownLatch.java:236)
at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:326)
at com.sun.javafx.application.LauncherImpl.access$000(LauncherImpl.java:47)
at com.sun.javafx.application.LauncherImpl$1.run(LauncherImpl.java:115)
at java.lang.Thread.run(Thread.java:722)
"Service Thread" daemon prio=5 tid=0x00007f8175006000 nid=0x16f620000 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C1 CompilerThread3" daemon prio=5 tid=0x00007f8175005800 nid=0x16f51d000 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread2" daemon prio=5 tid=0x00007f8176037000 nid=0x16f41a000 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread1" daemon prio=5 tid=0x00007f817402f000 nid=0x16f317000 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread0" daemon prio=5 tid=0x00007f817402d000 nid=0x16f214000 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Signal Dispatcher" daemon prio=5 tid=0x00007f8174022800 nid=0x16f111000 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Finalizer" daemon prio=5 tid=0x00007f8174016000 nid=0x16edf2000 in Object.wait() [0x000000016edf1000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x000000014e5693a0> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:135)
- locked <0x000000014e5693a0> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:151)
at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:177)
"Reference Handler" daemon prio=5 tid=0x00007f8174015800 nid=0x16ecef000 in Object.wait() [0x000000016ecee000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x000000014e568c78> (a java.lang.ref.Reference$Lock)
at java.lang.Object.wait(Object.java:503)
at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:133)
- locked <0x000000014e568c78> (a java.lang.ref.Reference$Lock)
"main" prio=5 tid=0x00007f8173034800 nid=0x10e723000 waiting on condition [0x000000010e721000]
java.lang.Thread.State: WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x000000014e6f3f80> (a java.util.concurrent.CountDownLatch$Sync)
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:186)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:834)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.doAcquireSharedInterruptibly(AbstractQueuedSynchronizer.java:994)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireSharedInterruptibly(AbstractQueuedSynchronizer.java:1303)
at java.util.concurrent.CountDownLatch.await(CountDownLatch.java:236)
at com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:134)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at com.javafx.main.Main.launchApp(Main.java:453)
at com.javafx.main.Main.main(Main.java:601)
"VM Thread" prio=5 tid=0x00007f8174013000 nid=0x16ebec000 runnable
"GC task thread#0 (ParallelGC)" prio=5 tid=0x00007f8173041800 nid=0x168ff9000 runnable
"GC task thread#1 (ParallelGC)" prio=5 tid=0x00007f8173042000 nid=0x1690fc000 runnable
"GC task thread#2 (ParallelGC)" prio=5 tid=0x00007f8173043000 nid=0x1691ff000 runnable
"GC task thread#3 (ParallelGC)" prio=5 tid=0x00007f8173043800 nid=0x169302000 runnable
"GC task thread#4 (ParallelGC)" prio=5 tid=0x00007f8173044000 nid=0x169405000 runnable
"GC task thread#5 (ParallelGC)" prio=5 tid=0x00007f8175800000 nid=0x169508000 runnable
"GC task thread#6 (ParallelGC)" prio=5 tid=0x00007f8173044800 nid=0x16960b000 runnable
"GC task thread#7 (ParallelGC)" prio=5 tid=0x00007f8173045800 nid=0x16970e000 runnable
"VM Periodic Task Thread" prio=5 tid=0x00007f817500f000 nid=0x16f723000 waiting on condition
JNI global references: 268