Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Most process abstractions support processes being destroyed whenthe program term

ID: 3619362 • Letter: M

Question

Most process abstractions support processes being destroyed whenthe program terminates, or in response to a specific killdirective. There are two common implementations, one a“poison pill” where the process is sent a command tokill itself, and the other where the system itself kills theprocess, not permitting the process to execute further at all.What actions need to be taken when a program terminates ora process is killed? What if that process destruction is not theconsequence of normal process termination, but rather is theconsequence of software failure?

Explanation / Answer

As part of a log out, restart, or shutdown sequence, loginwindow attempts to terminate all foreground and background userprocesses. It sends each process a quit application event as acourtesy, to give each process a chance to shut itself downgracefully. For foreground processes, loginwindow sends the eventand waits for a reply. For background processes, loginwindow sendsthe event but does not wait for a reply. It terminates anylingering background processes by sending a kill command.

If a foreground application fails to reply or terminate itselfafter 45 seconds, loginwindow automaticallyaborts the termination sequence. This safeguard is to protect datain various situations, such as when an application is saving alarge file to disk and is unable to terminate in the allotted time.If a foreground application is unresponsive and not doing anything,the user must use the Force Quit window to kill it beforeproceeding.

Software project failure is often devastating to anorganization. Schedule slips, buggy releases and missing featurescan mean the end of the project or even financial ruin for acompany. Oddly, there is disagreement over what it means for aproject to fail.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote