Fix error message for checkVolume command (#409)

This commit is contained in:
Vishesh 2024-04-17 17:27:08 +05:30 committed by GitHub
parent 3a058f3a18
commit 1b52bebd08
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 1 deletions

View File

@ -1878,7 +1878,8 @@ public class VolumeApiServiceImpl extends ManagerBase implements VolumeApiServic
} else if (jobResult instanceof ResourceAllocationException) {
throw (ResourceAllocationException)jobResult;
} else if (jobResult instanceof Throwable) {
throw new RuntimeException("Unexpected exception", (Throwable)jobResult);
Throwable throwable = (Throwable) jobResult;
throw new RuntimeException(String.format("Unexpected exception: %s", throwable.getMessage()), throwable);
}
}