Skip to content

Commit dd57930

Browse files
authored
countDownLatch fix resolves #46072
Add successfulCompletionLatch.countDown(); in error handler to prevent infinite loop on error
1 parent 32522c1 commit dd57930

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

articles/cosmos-db/how-to-use-stored-procedures-triggers-udfs.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,7 @@ asyncClient.executeStoredProcedure(sprocLink, requestOptions, storedProcedureArg
125125
successfulCompletionLatch.countDown();
126126
System.out.println(storedProcedureResponse.getActivityId());
127127
}, error -> {
128+
successfulCompletionLatch.countDown();
128129
System.err.println("an error occurred while executing the stored procedure: actual cause: "
129130
+ error.getMessage());
130131
});

0 commit comments

Comments
 (0)