miketheprogrammer / go-thrust

Cross Platform UI Kit powered by Blink/V8/Chromium Content Lib
MIT License
445 stars 34 forks source link

Process continues to live #44

Closed Nyarum closed 9 years ago

Nyarum commented 9 years ago

After you close the application - the process remains and begins to take more than 40% CPU.

Webserver and Thrust into a single binary file.

miketheprogrammer commented 9 years ago

Yea, i thought we had fixed this, please dont kill the application, only use the SafeExit method, or whatever exit methods have been provided in the thrust file.

Windows it is especially difficult to detect a force quit.

miketheprogrammer commented 9 years ago

@Nyarum Please see Thrust.Exit() in thrust.go also please see this for the built in safety that should be firing, note this may not always work in windows. https://github.com/miketheprogrammer/go-thrust/blob/59ae10c7294fb5ce056b3100311d48c1c9df204b/lib/connection/connection.go#L63

Edit* Although i should mention, in most of my attempts to get it working for windows, it did work. So, not sure why its not working on your machine, can you confirm the goroutine is not firing when you quit.

Nyarum commented 9 years ago

If use Thrust.Exit() then everything is fine. Can possibly keep track of the exit window Thrust?

miketheprogrammer commented 9 years ago

Thrust should emit an event when a window is closed, but if not, then you can do long polling to check the state of a window.