mirror of https://github.com/BOINC/boinc.git
*** empty log message ***
svn path=/trunk/boinc/; revision=10400
This commit is contained in:
parent
a209a53311
commit
89930e4aa8
|
@ -6301,3 +6301,16 @@ David 19 June 2006
|
|||
client/
|
||||
client_state.C,h
|
||||
cpu_sched.C
|
||||
|
||||
David 19 June 2006
|
||||
- core client: remove CLIENT_STATE::handle_file_xfer_apps().
|
||||
Instead, handle this in CLIENT_STATE::update_results().
|
||||
- core client: rename RESULT::reset_files() to clear_uploaded_flags()
|
||||
|
||||
client/
|
||||
client_state.C,h
|
||||
client_types.C,h
|
||||
cpu_sched.C
|
||||
cs_apps.C
|
||||
sched/
|
||||
update_stats.C
|
||||
|
|
|
@ -1028,7 +1028,16 @@ bool CLIENT_STATE::update_results() {
|
|||
case RESULT_FILES_DOWNLOADING:
|
||||
if (input_files_available(rp)) {
|
||||
rp->state = RESULT_FILES_DOWNLOADED;
|
||||
request_schedule_cpus("files downloaded");
|
||||
if (rp->wup->avp->app_files.size()==0) {
|
||||
// if this is a file-transfer app, start the upload phase
|
||||
//
|
||||
rp->state = RESULT_FILES_UPLOADING;
|
||||
rp->clear_uploaded_flags();
|
||||
} else {
|
||||
// else try to start the computation
|
||||
//
|
||||
request_schedule_cpus("files downloaded");
|
||||
}
|
||||
action = true;
|
||||
}
|
||||
break;
|
||||
|
|
|
@ -324,7 +324,6 @@ private:
|
|||
int app_finished(ACTIVE_TASK&);
|
||||
bool start_apps();
|
||||
bool handle_finished_apps();
|
||||
void handle_file_xfer_apps();
|
||||
public:
|
||||
int schedule_result(RESULT*);
|
||||
|
||||
|
|
|
@ -1489,9 +1489,8 @@ bool RESULT::is_upload_done() {
|
|||
|
||||
// resets all FILE_INFO's in result to uploaded = false
|
||||
// if upload_when_present is true.
|
||||
// Also updates the last time the input files were used
|
||||
|
||||
void RESULT::reset_files() {
|
||||
//
|
||||
void RESULT::clear_uploaded_flags() {
|
||||
unsigned int i;
|
||||
FILE_INFO* fip;
|
||||
|
||||
|
@ -1500,15 +1499,6 @@ void RESULT::reset_files() {
|
|||
if (fip->upload_when_present) {
|
||||
fip->uploaded = false;
|
||||
}
|
||||
#if 0
|
||||
fip->update_time();
|
||||
#endif
|
||||
}
|
||||
for (i=0; i < wup->input_files.size(); i++) {
|
||||
fip = wup->input_files[i].file_info;
|
||||
#if 0
|
||||
fip->update_time();
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -445,7 +445,7 @@ struct RESULT {
|
|||
int write(MIOFILE&, bool to_server);
|
||||
int write_gui(MIOFILE&);
|
||||
bool is_upload_done(); // files uploaded?
|
||||
void reset_files();
|
||||
void clear_uploaded_flags();
|
||||
FILE_REF* lookup_file(FILE_INFO*);
|
||||
FILE_INFO* lookup_file_logical(const char*);
|
||||
void abort_inactive(int);
|
||||
|
|
|
@ -404,14 +404,6 @@ void CLIENT_STATE::schedule_cpus() {
|
|||
}
|
||||
}
|
||||
|
||||
// mark file xfer results as completed;
|
||||
// TODO: why do this here??
|
||||
//
|
||||
// Dr. A. This has been here quite a while.
|
||||
// Either we should remove the comment or we should move the code. jm7
|
||||
//
|
||||
handle_file_xfer_apps();
|
||||
|
||||
// set temporary variables
|
||||
//
|
||||
for (i=0; i<results.size(); i++) {
|
||||
|
|
|
@ -359,19 +359,6 @@ int CLIENT_STATE::choose_version_num(char* app_name, SCHEDULER_REPLY& sr) {
|
|||
return best;
|
||||
}
|
||||
|
||||
// handle file-transfer applications
|
||||
//
|
||||
void CLIENT_STATE::handle_file_xfer_apps() {
|
||||
unsigned int i;
|
||||
for (i=0; i<results.size(); i++) {
|
||||
RESULT* rp = results[i];
|
||||
if (rp->wup->avp->app_files.size() == 0 && rp->state == RESULT_FILES_DOWNLOADED) {
|
||||
rp->state = RESULT_FILES_UPLOADING;
|
||||
rp->reset_files();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void CLIENT_STATE::request_enforce_schedule(const char* where) {
|
||||
// The CPU scheduler runs when a result is completed,
|
||||
// when the end of the user-specified scheduling period is reached,
|
||||
|
|
|
@ -221,6 +221,7 @@ int main(int argc, char** argv) {
|
|||
}
|
||||
}
|
||||
|
||||
log_messages.printf(SCHED_MSG_LOG::MSG_NORMAL, "Finished\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue