Improve game entry/exit with more hooks for disposal + docs #1296

Open
Cervator opened this Issue Oct 18, 2014 · 1 comment

Projects

None yet

2 participants

@Cervator
Member
Cervator commented Oct 18, 2014 edited

This is in response to recent disposal issues (mainly #1266) and the idea of including System.exit to be sure to not leaving ghost processes around (#1292)

I'm reluctant to just dive in with plain System.exit to avoid dead processes when we don't have a more solid way to catch disposal issues. We're in much better shape now than a couple weeks ago, but might still have some issues floating around with more that could pop up later and hide behind a System.exit

I'd like to make sure we catch all (few) entry and exit points and make them work consistently. For instance the recent activity with the PC facade hasn't been tested with the Applet facade to my knowledge (and the AWT facade which @mkienenb was close to fixing). Probably the browser is hard-killing the applet, but anyway.

To go with this I think we should document entry and exit points as an engine feature with its own forum thread and wiki page. Along with what the few exit codes indicate. Maybe we can somehow log the state of disposal immediately before System.exit (new utility method?) so if there is still something left we have a chance to find out. Keeping in mind the game may be unstable (out of memory, etc). Maybe there are other good metrics we can write on shutdown?

Not in a big rush to get this done (thus target beta or sooner) as there are several things I'd like to wait on / take into account:

  • Headless stable and loading/saving/disposing the same way as normal (#1049)
  • Straighten out Facades better (mainly on me to straighten out how they build and bundle - in case of any major changes)
  • Auto saves functional for both normal game and server - #477 (note: this is in progress by @flo and may conflict if this issue is worked - please wait for it to finish first!)
  • Maybe #1234 - external asset system
  • Multi world / multi-node servers (probably not - just figuring either would relate should they come up)
  • Environment-based automated testing solid including in Jenkins (has main methods and use of resources)
  • Reintroduction of the advanced monitor - #692 (currently if enabled fails to dispose)

@Cervator Cervator added this to the Beta milestone Oct 18, 2014
@Cervator
Member
Cervator commented Mar 1, 2015

Just to make a note of it - a few disposal issues have been sneaking back in slowly. I don't have a lot of details I just notice occasionally when crashing the game during testing.

@msteiger also mentioned an invalid port scenario over in #1622

@Cervator Cervator modified the milestone: Beta Jan 19, 2016
@MaxBorsch MaxBorsch was assigned by Cervator Jan 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment