Skip to content

Commit

Permalink
Attempt to fix web console check
Browse files Browse the repository at this point in the history
  • Loading branch information
Akshat-Jain committed Jul 26, 2024
1 parent 7f864cb commit afa0c96
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -587,9 +587,9 @@ private Optional<SqlStatementResult> getStatementStatus(
MSQControllerTask msqControllerTask = getMSQControllerTaskAndCheckPermission(queryId, authenticationResult, forAction);
SqlStatementState sqlStatementState = SqlStatementResourceHelper.getSqlStatementState(statusPlus);

MSQTaskReportPayload msqTaskReportPayload = null;
Optional<MSQTaskReportPayload> msqTaskReportPayload = Optional.empty();
try {
msqTaskReportPayload = SqlStatementResourceHelper.getPayload(contactOverlord(overlordClient.taskReportAsMap(queryId), queryId));
msqTaskReportPayload = Optional.ofNullable(SqlStatementResourceHelper.getPayload(contactOverlord(overlordClient.taskReportAsMap(queryId), queryId)));
}
catch (DruidException e) {
if (!e.getErrorCode().equals("notFound")) {
Expand All @@ -603,7 +603,7 @@ private Optional<SqlStatementResult> getStatementStatus(
taskResponse,
statusPlus,
sqlStatementState,
msqTaskReportPayload,
msqTaskReportPayload.orElse(null),
jsonMapper,
detail
);
Expand All @@ -622,9 +622,9 @@ private Optional<SqlStatementResult> getStatementStatus(
msqControllerTask.getQuerySpec().getDestination()
).orElse(null) : null,
null,
detail ? SqlStatementResourceHelper.getQueryStagesReport(msqTaskReportPayload) : null,
detail ? SqlStatementResourceHelper.getQueryCounters(msqTaskReportPayload) : null,
detail ? SqlStatementResourceHelper.getQueryWarningDetails(msqTaskReportPayload) : null
detail ? SqlStatementResourceHelper.getQueryStagesReport(msqTaskReportPayload.orElse(null)) : null,
detail ? SqlStatementResourceHelper.getQueryCounters(msqTaskReportPayload.orElse(null)) : null,
detail ? SqlStatementResourceHelper.getQueryWarningDetails(msqTaskReportPayload.orElse(null)) : null
));
}
}
Expand Down

0 comments on commit afa0c96

Please sign in to comment.