Skip to content

Commit

Permalink
logging
Browse files Browse the repository at this point in the history
  • Loading branch information
BBesrour committed Dec 4, 2024
1 parent a4d612d commit f82a9b3
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -300,15 +300,15 @@ private BuildResult runScriptAndParseResults(BuildJobQueueItem buildJob, String

ZonedDateTime buildCompletedDate = ZonedDateTime.now();

msg = "~~~~~~~~~~~~~~~~~~~~ Moving test results to specified directory ~~~~~~~~~~~~~~~~~~~~";
msg = "~~~~~~~~~~~~~~~~~~~~ Moving test results to specified directory for build job " + buildJob.id() + " ~~~~~~~~~~~~~~~~~~~~";
buildLogsMap.appendBuildLogEntry(buildJob.id(), msg);
log.debug(msg);

buildJobContainerService.moveResultsToSpecifiedDirectory(containerId, buildJob.buildConfig().resultPaths(), LOCALCI_WORKING_DIRECTORY + LOCALCI_RESULTS_DIRECTORY);

// Get an input stream of the test result files.

msg = "~~~~~~~~~~~~~~~~~~~~ Collecting test results from container ~~~~~~~~~~~~~~~~~~~~";
msg = "~~~~~~~~~~~~~~~~~~~~ Collecting test results from container " + containerName + " for build job " + buildJob.id() + " ~~~~~~~~~~~~~~~~~~~~";
buildLogsMap.appendBuildLogEntry(buildJob.id(), msg);
log.info(msg);

Expand Down Expand Up @@ -349,6 +349,10 @@ private BuildResult runScriptAndParseResults(BuildJobQueueItem buildJob, String
}
}

msg = "~~~~~~~~~~~~~~~~~~~~ Parsing test results for build job " + buildJob.id() + " ~~~~~~~~~~~~~~~~~~~~";
buildLogsMap.appendBuildLogEntry(buildJob.id(), msg);
log.info(msg);

BuildResult buildResult;
try {
buildResult = parseTestResults(testResultsTarInputStream, buildJob.buildConfig().branch(), assignmentRepoCommitHash, testRepoCommitHash, buildCompletedDate,
Expand All @@ -362,7 +366,7 @@ private BuildResult runScriptAndParseResults(BuildJobQueueItem buildJob, String
}

msg = "Building and testing submission for repository " + assignmentRepositoryUri.repositorySlug() + " and commit hash " + assignmentRepoCommitHash + " took "
+ TimeLogUtil.formatDurationFrom(timeNanoStart);
+ TimeLogUtil.formatDurationFrom(timeNanoStart) + " for build job " + buildJob.id();
buildLogsMap.appendBuildLogEntry(buildJob.id(), msg);
log.info(msg);

Expand Down

0 comments on commit f82a9b3

Please sign in to comment.