Skip to content

Commit 2b02901

Browse files
authored
Merge pull request #6391 from BOINC/dpa_assim
sample assimilator: rename rather than copy output files
2 parents 474589e + 4a802b5 commit 2b02901

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

sched/sample_assimilator.cpp

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,9 @@
1717

1818
// A sample assimilator that:
1919
// 1) if success, copy the output file(s) to a directory
20-
// ../results/batchid
21-
// If 1 output file, its name is the WU name
22-
// If >1 files, file i is named <wuname>_i
23-
// 2) if failure, write a message to <wuname>_error
20+
// ../results/<batchid>/<wu_name>__file_<log_name>
21+
// where <log_name> is the file's logical name
22+
// 2) if failure, write a message to result/<batch_id>/<wuname>_error
2423

2524
// Note: daemons like this run in project/tmp_<host>
2625

@@ -92,7 +91,7 @@ int assimilate_handler(
9291
sprintf(buf, "%s/%d/%s__file_%s",
9392
outdir, wu.batch, wu.name, fi.logical_name.c_str()
9493
);
95-
retval = boinc_copy(fi.path.c_str() , buf);
94+
retval = boinc_rename(fi.path.c_str() , buf);
9695
if (!retval) {
9796
file_copied = true;
9897
}

0 commit comments

Comments
 (0)