Browse Source

Added file release to Job::finalize()

Improved shutdown reporting


git-svn-id: https://svn.microneil.com/svn/SNF4CGP/trunk@27 59e8e3e7-56fa-483b-b4b4-fa6ab0af3dfc
master
madscientist 15 years ago
parent
commit
3f7198f89a
2 changed files with 8 additions and 2 deletions
  1. 4
    0
      SNF4CGP/ExecutiveProcess.cpp
  2. 4
    2
      SNF4CGP/JobPool.cpp

+ 4
- 0
SNF4CGP/ExecutiveProcess.cpp View File

if(Command::QUIT != C.Type) dispatchCommand(C); if(Command::QUIT != C.Type) dispatchCommand(C);
else { else {
QuitJobNumber = C.Number; QuitJobNumber = C.Number;
cout << "* SNF4CGP[" << C.Number << "] Received QUIT, shutting down..." << endl;
cout.flush();
return; return;
} }
} }
shutdownWorkerPool(); shutdownWorkerPool();
shutdownOutput(); shutdownOutput();
shutdownJobPool(); shutdownJobPool();
cout << "* SNF4CGP Shutdown completed." << endl;
cout << QuitJobNumber << " OK" << endl; cout << QuitJobNumber << " OK" << endl;
cout.flush();
} }

+ 4
- 2
SNF4CGP/JobPool.cpp View File

O << CurrentCommand.Number << " REJECTED " << formatAsCGPString(Report) << endl; O << CurrentCommand.Number << " REJECTED " << formatAsCGPString(Report) << endl;
} }
void Job::finalize() {
Output.outputJob(*this);
void Job::finalize() { // Cleanup and report this job.
closeWriter(); // In case of exception let go of our
closeReader(); // Reader and Writer now. The rest
Output.outputJob(*this); // can wait for the output processor.
} }
void Job::doWakeUp() { void Job::doWakeUp() {

Loading…
Cancel
Save