Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Codeql Injection issue fix with develop conflicts resolved #1100

Open
wants to merge 29 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
2d836fd
DTS-37340 test log user input sanitize for codeql
Jun 7, 2024
b166288
DTS-37340 test log user input sanitize for codeql
Jun 7, 2024
5e7b83a
DTS-37340 test log user input sanitize for codeql
Jun 7, 2024
b6612c4
DTS-37340 test for access request class
Jun 7, 2024
1f49c01
DTS-37340 for new code
Jun 10, 2024
76b3e53
DTS-37340 ProjectToolConfigController
Jun 10, 2024
23e4a3c
DTS-37340 AccessRequestsController security fix
Jun 10, 2024
accbf10
DTS-37340 KPIHelperUtil security fix
Jun 10, 2024
f2f36b7
DTS-37340 SignupRequestsController security fix
Jun 10, 2024
599d3bf
DTS-37340 RolesController security fix
Jun 10, 2024
8ef4689
DTS-37340 ConnectionController security fix
Jun 10, 2024
4a2c042
DTS-37340 ForgotPasswordController security fix
Jun 10, 2024
5f2bc8c
DTS-37340 FieldMappingStructureController security fix
Jun 10, 2024
3e04098
DTS-37340 CommentsServiceImpl logs removed
Jun 10, 2024
56f6917
DTS-37340 KPIExcelDataController logs removed
Jun 10, 2024
087f0b4
DTS-37340 KpiRequest requestTrackerId sanitize
Jun 10, 2024
a8fe054
DTS-37340 SprintTraceLogServiceImp sanitize
Jun 10, 2024
183a00f
DTS-37340 SprintTraceLogServiceImp sanitize
Jun 10, 2024
8778601
DTS-37340 BambooController sanitize
Jun 10, 2024
c1c2287
DTS-37340 log removed
Jun 10, 2024
4cfda44
DTS-37340 AzureToolConfigServiceImpl sanitise
Jun 10, 2024
078d86a
DTS-37340 KPIrequest remove logs
Jun 11, 2024
cb9fbf0
DTS-37340 KPI request related remove logs
Jun 11, 2024
fb026e0
DTS-37340 sanitity method apply
Jun 11, 2024
0c3dfe1
DTS-37340 sanitity method apply
Jun 11, 2024
aebee4e
DTS-37340 removed logs
Jun 11, 2024
324ad59
DTS-37340 removed logs
Jun 11, 2024
6279f51
fix review comment and added testcase
Jun 13, 2024
8863eac
fix conflits with develop branch
Jun 13, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,6 @@ public ResponseEntity<Map> runProcessorForProjects(
ExecutionLogContext.set(processorExecutionBasicConfig.getLogContext());
MDC.put("Processor Name", jobExecuter.getProcessor().getProcessorName());
MDC.put("RequestStartTime", String.valueOf(System.currentTimeMillis()));
log.info("Received request to run the processor: {} for projects {}",
jobExecuter.getProcessor().getProcessorName(),
processorExecutionBasicConfig.getProjectBasicConfigIds());

jobExecuter.setProjectsBasicConfigIds(processorExecutionBasicConfig.getProjectBasicConfigIds());
jobExecuter.setExecutionLogContext(ExecutionLogContext.getContext());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,6 @@ public class ProcessorExecutionTraceLogServiceImpl implements ProcessorExecution

@Override
public void save(ProcessorExecutionTraceLog processorExecutionTracelog) {
log.info(
"last execution time of {} for project {} is {}. status is {} and lastSuccessfulRun is {} and LastEnableAssigneeToggleState is {} ",
processorExecutionTracelog.getProcessorName(), processorExecutionTracelog.getBasicProjectConfigId(),
processorExecutionTracelog.getExecutionEndedAt(), processorExecutionTracelog.isExecutionSuccess(),
processorExecutionTracelog.getLastSuccessfulRun(),
processorExecutionTracelog.isLastEnableAssigneeToggleState());

Optional<ProcessorExecutionTraceLog> existingTraceLogOptional = processorExecutionTraceLogRepository
.findByProcessorNameAndBasicProjectConfigId(processorExecutionTracelog.getProcessorName(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public class EditKpiConfigController {
@RequestMapping(value = "/jira/editKpi/{projectBasicConfigId}/{kpiCode}", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE) // NOSONAR
public ResponseEntity<ServiceResponse> fetchTypeValues(@PathVariable String projectBasicConfigId,
@PathVariable String kpiCode) {
projectBasicConfigId = CommonUtils.handleCrossScriptingTaintedValue(projectBasicConfigId);
projectBasicConfigId = CommonUtils.sanitizeUserInput(projectBasicConfigId);
kpiCode = CommonUtils.handleCrossScriptingTaintedValue(kpiCode);
log.info("Fetching data in KPI edit configuration for :{}", projectBasicConfigId);
Map<String, List<MetadataValue>> data = editKpiConfigService.getDataForType(projectBasicConfigId, kpiCode);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
import java.net.UnknownHostException;
import java.util.UUID;

import com.publicissapient.kpidashboard.apis.util.CommonUtils;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
Expand Down Expand Up @@ -95,7 +96,6 @@ public class ForgotPasswordController {
public ResponseEntity<ServiceResponse> processForgotPassword(@RequestBody ForgotPasswordRequest request,
HttpServletRequest httpServletRequest) {
boolean isSuccess = false;
log.info("ForgotPasswordController: requested mail {}", request.getEmail());
Authentication authentication = null;
try {
String serverPath = httpServletRequest.getScheme() + getApiHost() + httpServletRequest.getContextPath();
Expand All @@ -109,7 +109,7 @@ public ResponseEntity<ServiceResponse> processForgotPassword(@RequestBody Forgot
return ResponseEntity.ok().body(new ServiceResponse(isSuccess, "Success", authentication));
} catch (UnknownHostException e) {
log.error("UnknownHostException", e);
log.error("ForgotPasswordController: Mail can not be sent to {}", request.getEmail());
log.error("ForgotPasswordController: Mail can not be sent to {}", CommonUtils.sanitizeUserInput(request.getEmail()));
return ResponseEntity.badRequest().body(new ServiceResponse(isSuccess, "logError", null));
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ public class ForgotPasswordServiceImpl implements ForgotPasswordService {
*/
@Override
public Authentication processForgotPassword(String email, String url) {
log.info("ForgotPasswordServiceImpl: Requested mail {}", email);
Authentication authentication = getEmailExistsInDB(email);
if (authentication != null) {
String token = createForgetPasswordToken(authentication);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,15 +66,13 @@ public ResponseEntity<ServiceResponse> modifyAutoApprovConfigById(@PathVariable(
@Valid @RequestBody AutoApproveAccessConfigDTO autoAcessDTO) {
ModelMapper modelMapper = new ModelMapper();
AutoApproveAccessConfig autoApproveRole = modelMapper.map(autoAcessDTO, AutoApproveAccessConfig.class);

if (!ObjectId.isValid(id)) {
log.info("Id not valid");
return ResponseEntity.status(HttpStatus.OK).body(new ServiceResponse(false,
"access_request@" + id + " does not exist", Arrays.asList(autoAcessDTO)));
}

AutoApproveAccessConfig autoApproveData = autoApproveService.modifyAutoApprovConfigById(id, autoApproveRole);
log.info("Modifying request@{}", id);
return ResponseEntity.status(HttpStatus.OK)
.body(new ServiceResponse(true, "modified access_request@" + id, Arrays.asList(autoApproveData)));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import java.util.regex.Matcher;
import java.util.regex.Pattern;

import com.publicissapient.kpidashboard.apis.util.CommonUtils;
import org.apache.commons.lang3.StringUtils;
import org.bson.types.ObjectId;
import org.json.simple.JSONArray;
Expand Down Expand Up @@ -88,13 +89,13 @@ public List<AzurePipelinesResponseDTO> getAzurePipelineNameAndDefinitionIdList(S
}
} else {
String statusCode = response.getStatusCode().toString();
log.error("Error while fetching ProjectsAndPlanKeyList from {}. with status {}", finalUrl,
log.error("Error while fetching ProjectsAndPlanKeyList from {}. with status {}", CommonUtils.sanitizeUserInput(finalUrl),
statusCode);
}

} catch (Exception exception) {
isClientException(connection, exception);
log.error("Error while fetching ProjectsAndPlanKeyList from {}: {}", finalUrl, exception.getMessage());
log.error("Error while fetching ProjectsAndPlanKeyList from {}: {}", CommonUtils.sanitizeUserInput(finalUrl), exception.getMessage());
}
}
return responseList;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import java.util.List;

import com.publicissapient.kpidashboard.apis.util.CommonUtils;
import org.apache.commons.collections4.CollectionUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
Expand Down Expand Up @@ -56,6 +57,7 @@ public ResponseEntity<ServiceResponse> getBambooProjectsAndPlanKeys(@PathVariabl
public ResponseEntity<ServiceResponse> getBambooBranchesNameAndKeys(@PathVariable String connectionId,
@PathVariable String jobNameKey) {
ServiceResponse response;
jobNameKey = CommonUtils.sanitizeUserInput(jobNameKey);
List<BambooBranchesResponseDTO> projectKeyList = bambooToolConfigService
.getBambooBranchesNameAndKeys(connectionId, jobNameKey);
if (CollectionUtils.isEmpty(projectKeyList)) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public class BitBucketController {
public ResponseEntity<List<KpiElement>> getBitBucketAggregatedMetrics(@NotNull @RequestBody KpiRequest kpiRequest)
throws Exception { // NOSONAR
MDC.put("BitbucketKpiRequest", kpiRequest.getRequestTrackerId());
log.info("Received BitBucket KPI request {}", kpiRequest);

long bitbucketRequestStartTime = System.currentTimeMillis();
MDC.put("BitbucketRequestStartTime", String.valueOf(bitbucketRequestStartTime));
cacheService.setIntoApplicationCache(Constant.KPI_REQUEST_TRACKER_ID_KEY + KPISource.BITBUCKET.name(),
Expand Down Expand Up @@ -111,7 +111,7 @@ public ResponseEntity<List<KpiElement>> getBitBucketAggregatedMetrics(@NotNull @
public ResponseEntity<List<KpiElement>> getBitBucketKanbanAggregatedMetrics(
@NotNull @RequestBody KpiRequest kpiRequest) throws Exception { // NOSONAR
MDC.put("BitbucketKpiRequest", kpiRequest.getRequestTrackerId());
log.info(" Received BitBucket KPI request {}", kpiRequest);

long bitbucketKanbanRequestStartTime = System.currentTimeMillis();
MDC.put("BitbucketKanbanRequestStartTime", String.valueOf(bitbucketKanbanRequestStartTime));
cacheService.setIntoApplicationCache(Constant.KPI_REQUEST_TRACKER_ID_KEY + KPISource.BITBUCKETKANBAN.name(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,6 @@ public class BitBucketServiceKanbanR {
@SuppressWarnings("unchecked")
public List<KpiElement> process(KpiRequest kpiRequest) throws EntityNotFoundException {

log.info("[BITBUCKET KANBAN][{}]. Processing KPI calculation for data {}", kpiRequest.getRequestTrackerId(),
kpiRequest.getKpiList());
List<KpiElement> responseList = new ArrayList<>();
String[] kanbanProjectKeyCache = null;
try {
Expand All @@ -111,8 +109,6 @@ public List<KpiElement> process(KpiRequest kpiRequest) throws EntityNotFoundExce
KPISource.BITBUCKETKANBAN.name(), groupId, null);
if (!kpiRequest.getRequestTrackerId().toLowerCase().contains(KPISource.EXCEL.name().toLowerCase())
&& null != cachedData) {
log.info("[BITBUCKET KANBAN][{}]. Fetching value from cache for {}", kpiRequest.getRequestTrackerId(),
kpiRequest.getIds());
return (List<KpiElement>) cachedData;
}

Expand All @@ -126,12 +122,12 @@ public List<KpiElement> process(KpiRequest kpiRequest) throws EntityNotFoundExce

} catch (EntityNotFoundException enfe) {

log.error("[BITBUCKET KANBAN][{}]. Error while KPI calculation for data. No data found {} {}",
kpiRequest.getRequestTrackerId(), kpiRequest.getKpiList(), enfe);
log.error("[BITBUCKET KANBAN][{}]. Error while KPI calculation for data. No data found {}",
kpiRequest.getRequestTrackerId(), enfe);
throw enfe;
} catch (ApplicationException e) {
log.error("[BITBUCKET KANBAN][{}]. Error while KPI calculation for data {} {}",
kpiRequest.getRequestTrackerId(), kpiRequest.getKpiList(), e);
log.error("[BITBUCKET KANBAN][{}]. Error while KPI calculation for data {}",
kpiRequest.getRequestTrackerId(), e);
throw new HttpMessageNotWritableException(e.getMessage(), e);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,6 @@ public class BitBucketServiceR {
@SuppressWarnings("unchecked")
public List<KpiElement> process(KpiRequest kpiRequest) throws EntityNotFoundException {

log.info("[BITBUCKET][{}]. Processing KPI calculation for data {}", kpiRequest.getRequestTrackerId(),
kpiRequest.getKpiList());
List<KpiElement> origRequestedKpis = kpiRequest.getKpiList().stream().map(KpiElement::new)
.collect(Collectors.toList());
List<KpiElement> responseList = new ArrayList<>();
Expand All @@ -99,8 +97,6 @@ public List<KpiElement> process(KpiRequest kpiRequest) throws EntityNotFoundExce
groupId, kpiRequest.getSprintIncluded());
if (!kpiRequest.getRequestTrackerId().toLowerCase().contains(KPISource.EXCEL.name().toLowerCase())
&& null != cachedData) {
log.info("[BITBUCKET][{}]. Fetching value from cache for {}", kpiRequest.getRequestTrackerId(),
kpiRequest.getIds());
return (List<KpiElement>) cachedData;
}

Expand All @@ -125,8 +121,7 @@ public List<KpiElement> process(KpiRequest kpiRequest) throws EntityNotFoundExce
}

} catch (Exception e) {
log.error("[BITBUCKET][{}]. Error while KPI calculation for data {} {}", kpiRequest.getRequestTrackerId(),
kpiRequest.getKpiList(), e);
log.error("[BITBUCKET][{}]. Error while KPI calculation for data {}", kpiRequest.getRequestTrackerId(), e);
throw new HttpMessageNotWritableException(e.getMessage(), e);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

import javax.validation.Valid;

import com.publicissapient.kpidashboard.apis.util.CommonUtils;
import org.apache.commons.collections4.CollectionUtils;
import org.bson.types.ObjectId;
import org.springframework.beans.factory.annotation.Autowired;
Expand Down Expand Up @@ -75,7 +76,7 @@ public ResponseEntity<ServiceResponse> addCapacity(@RequestBody CapacityMaster c
@GetMapping("/{basicProjectConfigId}")
public ResponseEntity<ServiceResponse> getCapacities(@PathVariable String basicProjectConfigId) {
ServiceResponse response = null;

basicProjectConfigId = CommonUtils.sanitizeUserInput(basicProjectConfigId);
List<CapacityMaster> capacities = capacityMasterService.getCapacities(basicProjectConfigId);
if (CollectionUtils.isNotEmpty(capacities)) {
response = new ServiceResponse(true, "Capacity Data", capacities);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ public Map<String, Object> findCommentByKPIId(String node, String level, String
mappedCollection.put("kpiId", kpiId);
mappedCollection.put("CommentsInfo", finalCommentsInfo);
}
log.info("Final filter comments of matching kpiId {}", mappedCollection);
return mappedCollection;
}

Expand Down Expand Up @@ -154,7 +153,6 @@ public List<CommentViewResponseDTO> findLatestCommentSummary(List<String> nodes,
@Override
public boolean submitComment(CommentSubmitDTO comment) {
setCommentByUser(comment);
log.debug("CommentSubmitDTO info {}", comment);
List<CommentsInfo> commentsInfo = comment.getCommentsInfo();
if (CollectionUtils.isNotEmpty(commentsInfo)) {
for (CommentsInfo commentInfo : commentsInfo) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ public ResponseEntity<KPIExcelValidationDataResponse> getValidationKPIData(HttpS
Boolean isApiAuth = StringUtils.isNotEmpty(
apiKey) && apiKey.equalsIgnoreCase(request.getHeader(Constant.TOKEN_KEY));
String kpiRequestStr = kpiRequest.toString();
kpiID = CommonUtils.handleCrossScriptingTaintedValue(kpiID);
kpiRequestStr = CommonUtils.handleCrossScriptingTaintedValue(kpiRequestStr);
kpiID = CommonUtils.sanitizeUserInput(kpiID);
kpiRequestStr = CommonUtils.sanitizeUserInput(kpiRequestStr);
log.info("[KPI-EXCEL-DATA][]. Received Specific Excel KPI Data request for {} with kpiRequest {}", kpiID,
kpiRequestStr);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public void clearCache(String cacheName) {
if (cache != null) {
cache.clear();
cache.evict(cacheName);
log.info("Clearing Cache ==>> {}", cacheName);
log.info("Clearing Cache ==>> {}", CommonUtils.sanitizeUserInput(cacheName));
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,6 @@ private Boolean validateOriginWithWhitelist(List<String> originWhiteList, Boolea
throws MalformedURLException {
Boolean result = theResult;
String originHost = new URL(origin).getHost();
log.debug("value of orignHost : {}", originHost);
for (String allowedOrigin : originWhiteList) {
if (StringUtils.equalsIgnoreCase(originHost, allowedOrigin)) {
result = Boolean.TRUE;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@

import javax.validation.Valid;

import com.publicissapient.kpidashboard.apis.util.CommonUtils;
import org.apache.commons.lang3.StringUtils;
import org.modelmapper.ModelMapper;
import org.springframework.beans.factory.annotation.Autowired;
Expand Down Expand Up @@ -71,6 +72,7 @@ public class ConnectionController {
@PreAuthorize("hasPermission(#type,'CONNECTION_ACCESS')")
public ResponseEntity<ServiceResponse> getAllConnection(
@RequestParam(name = "type", required = false) String type) {
type = CommonUtils.sanitizeUserInput(type);
if (StringUtils.isEmpty(type)) {
log.info("Fetching all connection");
return ResponseEntity.status(HttpStatus.OK).body(connectionService.getAllConnection());
Expand Down Expand Up @@ -115,7 +117,6 @@ public ResponseEntity<ServiceResponse> saveConnectionDetails(@RequestBody Connec
@PreAuthorize("hasPermission(#id,'CONNECTION_ACCESS')")
public ResponseEntity<ServiceResponse> modifyConnectionById(@PathVariable String id,
@Valid @RequestBody ConnectionDTO connectionDTO) {
log.info("conn@{} updated", connectionDTO.getId());
final ModelMapper modelMapper = new ModelMapper();
final Connection conn = modelMapper.map(connectionDTO, Connection.class);
return ResponseEntity.status(HttpStatus.OK).body(connectionService.updateConnection(id, conn));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
import java.util.Set;
import java.util.stream.Collectors;

import org.apache.commons.collections4.MapUtils;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.collections4.MapUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.tuple.Pair;
import org.bson.types.ObjectId;
Expand All @@ -45,6 +45,7 @@
import com.publicissapient.kpidashboard.apis.model.AccountHierarchyData;
import com.publicissapient.kpidashboard.apis.model.AccountHierarchyDataKanban;
import com.publicissapient.kpidashboard.apis.model.KpiRequest;
import com.publicissapient.kpidashboard.apis.util.CommonUtils;
import com.publicissapient.kpidashboard.common.constant.CommonConstant;
import com.publicissapient.kpidashboard.common.model.application.AccountHierarchy;
import com.publicissapient.kpidashboard.common.model.application.AdditionalFilterCategory;
Expand Down Expand Up @@ -168,7 +169,7 @@ public List<AccountHierarchyDataKanban> getFilteredBuildsKanban(KpiRequest kpiRe

if (filteredDataSetNew.isEmpty()) {
log.error("[FILTERED-DATA][{}]. No filtered data found in the cache for the filter level{} and id{}",
kpiRequest.getRequestTrackerId(), kpiRequest.getLevel(), kpiRequest.getIds());
kpiRequest.getRequestTrackerId(), CommonUtils.sanitizeUserInput(String.valueOf(kpiRequest.getLevel())), CommonUtils.sanitizeUserInput(Arrays.deepToString(kpiRequest.getIds())));
throw new EntityNotFoundException(KpiRequest.class, "kpiId", Arrays.deepToString(kpiRequest.getIds()));
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import java.util.List;
import java.util.Optional;

import com.publicissapient.kpidashboard.apis.util.CommonUtils;
import org.bson.types.ObjectId;
import org.json.simple.JSONArray;
import org.json.simple.JSONObject;
Expand Down Expand Up @@ -85,12 +86,12 @@ public List<GithubActionWorkflowsDTO> getGitHubWorkFlowList(String connectionId,

} else {
String statusCode = response.getStatusCode().toString();
log.error("Error while fetching getJenkinsJobNameList from {}. with status {}", url, statusCode);
log.error("Error while fetching getJenkinsJobNameList. with status {}", statusCode);
}

} catch (Exception exception) {
isClientException(connection, exception);
log.error("Error while fetching getJenkinsJobNameList from {}: {}", url, exception.getMessage());
log.error("Error while fetching getJenkinsJobNameList from {}: {}", CommonUtils.sanitizeUserInput(url), exception.getMessage());
}
}
return responseDTOList;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@

import javax.validation.constraints.NotNull;

import com.publicissapient.kpidashboard.apis.util.CommonUtils;
import org.apache.commons.collections4.CollectionUtils;
import org.slf4j.MDC;
import org.springframework.beans.factory.annotation.Autowired;
Expand Down Expand Up @@ -87,7 +88,7 @@ public class JenkinsController {
public ResponseEntity<List<KpiElement>> getJenkinsAggregatedMetrics(@NotNull @RequestBody KpiRequest kpiRequest)
throws Exception { // NOSONAR
MDC.put("JenkinsKpiRequest", kpiRequest.getRequestTrackerId());
log.info("Received Jenkins KPI request {}", kpiRequest);

long jenkinsRequestStartTime = System.currentTimeMillis();
MDC.put("JenkinsRequestStartTime", String.valueOf(jenkinsRequestStartTime));
cacheService.setIntoApplicationCache(Constant.KPI_REQUEST_TRACKER_ID_KEY + KPISource.JENKINS.name(),
Expand Down Expand Up @@ -123,7 +124,6 @@ public ResponseEntity<List<KpiElement>> getJenkinsAggregatedMetrics(@NotNull @Re
public ResponseEntity<List<KpiElement>> getJenkinsKanbanAggregatedMetrics(
@NotNull @RequestBody KpiRequest kpiRequest) throws Exception { // NOSONAR
MDC.put("JenkinsKanbanKpiRequest", kpiRequest.getRequestTrackerId());
log.info("Received Jenkins Kanban KPI request {}", kpiRequest);
long jenkinsKanbanRequestStartTime = System.currentTimeMillis();
MDC.put("JenkinsKanbanRequestStartTime", String.valueOf(jenkinsKanbanRequestStartTime));
cacheService.setIntoApplicationCache(Constant.KPI_REQUEST_TRACKER_ID_KEY + KPISource.JENKINSKANBAN.name(),
Expand Down
Loading
Loading