English 中文(简体)
为什么联合考试委员会不等待用户申请所引发的 da子read子?
原标题:Why does the JVM not wait for daemon threads spawned by user application?

"The virtual machine terminates if the last non-daemon thread has finished." My question is, What happens to the daemon threads spawned by the application? Why does the JVM not wait for them to finish?

最佳回答

透镜的全目的是,如果是唯一的胎面,它不会活着。 你可能希望这样做的原因很多。

例如,用户在申请时,可能会在背景的达蒙透视(而不是在事件时穿透)。 在完成这项任务之前,用户试图退出申请。 在目前阶段,申请开发商可能已经决定,最好立即关闭申请,而不是将关闭未遂推迟到长期计算完成之前,因此决定分配计算线索达卢蒙的地位。

问题回答

Because they re daemon threads. That s what it means. It doesn t mean anything else.





相关问题
Spring Properties File

Hi have this j2ee web application developed using spring framework. I have a problem with rendering mnessages in nihongo characters from the properties file. I tried converting the file to ascii using ...

Logging a global ID in multiple components

I have a system which contains multiple applications connected together using JMS and Spring Integration. Messages get sent along a chain of applications. [App A] -> [App B] -> [App C] We set a ...

Java Library Size

If I m given two Java Libraries in Jar format, 1 having no bells and whistles, and the other having lots of them that will mostly go unused.... my question is: How will the larger, mostly unused ...

How to get the Array Class for a given Class in Java?

I have a Class variable that holds a certain type and I need to get a variable that holds the corresponding array class. The best I could come up with is this: Class arrayOfFooClass = java.lang....

SQLite , Derby vs file system

I m working on a Java desktop application that reads and writes from/to different files. I think a better solution would be to replace the file system by a SQLite database. How hard is it to migrate ...

热门标签