Skip to content

Commit

Permalink
Add string format on LOG.debug
Browse files Browse the repository at this point in the history
  • Loading branch information
lucashimpens committed Jun 19, 2024
1 parent 8f499e7 commit 446f2fa
Showing 1 changed file with 8 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ public Answer createAuto(String tagS, String campaign, String user, JSONArray re

@Override
public String enrichTagWithCloudProviderBuild(String provider, String system, String tagS, String user, String pass) {
LOG.debug("Trying to enrish tag '" + tagS + "' with Cloud service provider Build (" + provider + ").");
LOG.debug("Trying to enrish tag '{}' with Cloud service provider Build ({}).", tagS, provider);
if (StringUtil.isEmpty(tagS)) {
return null;
}
Expand All @@ -329,10 +329,10 @@ public String enrichTagWithCloudProviderBuild(String provider, String system, St
case TestCaseExecution.ROBOTPROVIDER_BROWSERSTACK:
if ((tag != null) && (StringUtil.isEmpty(tag.getBrowserstackBuildHash()) || "BSHash".equalsIgnoreCase(tag.getBrowserstackBuildHash()))) {
String newBuildHash = browserstackService.getBrowserStackBuildHashFromEndpoint(system, tagS, user, pass, "api.browserstack.com/automate/builds.json");
LOG.debug("Result : " + newBuildHash);
LOG.debug("Result : {}", newBuildHash);
tag.setBrowserstackBuildHash(newBuildHash);
newBuildHash = browserstackService.getBrowserStackBuildHashFromEndpoint(system, tagS, user, pass, "api.browserstack.com/app-automate/builds.json");
LOG.debug("Result : " + newBuildHash);
LOG.debug("Result : {}", newBuildHash);
tag.setBrowserstackAppBuildHash(newBuildHash);
Answer ans = tagDAO.updateBrowserStackBuild(tagS, tag);
return newBuildHash;
Expand Down Expand Up @@ -394,13 +394,13 @@ public void manageCampaignEndOfExecution(String tag) throws CerberusException {
AnswerList answerListQueue = new AnswerList<>();
answerListQueue = executionQueueService.readQueueOpen(tag);
if (answerListQueue.isCodeEquals(MessageEventEnum.DATA_OPERATION_OK.getCode()) && (answerListQueue.getDataList().isEmpty())) {
LOG.debug("No More executions (in queue or running) on tag : " + tag + " - " + answerListQueue.getDataList().size() + " " + answerListQueue.getMessageCodeString() + " - ");
LOG.debug("No More executions (in queue or running) on tag : {} - {} {}", tag, answerListQueue.getDataList().size(), answerListQueue.getMessageCodeString());
this.updateEndOfQueueData(tag);
} else {
LOG.debug("Still executions in queue on tag : " + tag + " - " + answerListQueue.getDataList().size() + " " + answerListQueue.getMessageCodeString());
LOG.debug("Still executions in queue on tag : {} - {} {}", tag, answerListQueue.getDataList().size(), answerListQueue.getMessageCodeString());
}
} else {
LOG.debug("Tag is already flaged with recent timestamp. " + currentTag.getDateEndQueue());
LOG.debug("Tag is already flagged with recent timestamp. {}", currentTag.getDateEndQueue());
}

}
Expand All @@ -422,7 +422,7 @@ public void manageCampaignStartOfExecution(String tag, Timestamp startOfExecutio
currentTag.setDateStartExe(startOfExecution);
tagDAO.updateDateStartExe(currentTag);
} else {
LOG.debug("Tag is already flaged with recent start of exe timestamp. " + currentTag.getDateStartExe());
LOG.debug("Tag is already flaged with recent start of exe timestamp. {}", currentTag.getDateStartExe());
}

}
Expand Down Expand Up @@ -483,8 +483,7 @@ public String formatResult(Tag tag) {
}

JSONObject getJSONEnriched() {
JSONObject result = new JSONObject();
return result;
return new JSONObject();
}

}

0 comments on commit 446f2fa

Please sign in to comment.