Skip to content

Commit 70fe1a7

Browse files
vancexuLiang Mei
and
Liang Mei
authored
Fix get raw history (#534)
Co-authored-by: Liang Mei <[email protected]>
1 parent 2790692 commit 70fe1a7

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

docker/buildkite/docker-compose.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ services:
2727
- statsd
2828

2929
cadence:
30-
image: ubercadence/server:master-auto-setup
30+
image: ubercadence/server:latestRelease-auto-setup
3131
logging:
3232
driver: none
3333
ports:

src/main/java/com/uber/cadence/serviceclient/WorkflowServiceTChannel.java

+10-1
Original file line numberDiff line numberDiff line change
@@ -2429,7 +2429,14 @@ private void getWorkflowExecutionHistory(
24292429
r.getBody(WorkflowService.GetWorkflowExecutionHistory_result.class);
24302430

24312431
if (r.getResponseCode() == ResponseCode.OK) {
2432-
resultHandler.onComplete(result.getSuccess());
2432+
GetWorkflowExecutionHistoryResponse res = result.getSuccess();
2433+
if (res.getRawHistory() != null) {
2434+
History history =
2435+
InternalUtils.DeserializeFromBlobToHistoryEvents(
2436+
res.getRawHistory(), getRequest.getHistoryEventFilterType());
2437+
res.setHistory(history);
2438+
}
2439+
resultHandler.onComplete(res);
24332440
return;
24342441
}
24352442
if (result.isSetBadRequestError()) {
@@ -2447,6 +2454,8 @@ private void getWorkflowExecutionHistory(
24472454
resultHandler.onError(
24482455
new TException(
24492456
"GetWorkflowExecutionHistory failed with unknown " + "error:" + result));
2457+
} catch (TException tException) {
2458+
resultHandler.onError(tException);
24502459
} finally {
24512460
if (r != null) {
24522461
r.release();

0 commit comments

Comments
 (0)