forked from apache/pulsar-client-cpp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Handle the exception from the token supplier (apache#458)
### Motivation When a token supplier is passed to the `AuthToken`, if exceptions are thrown from it, the application will crash immediately. A typical case is the Python wrapper might raise an exception when trying to get token. ### Modifications Catch the exception in `Commands::newConnect` because the token supplier is called in it. Then convert it to `ResultAuthenticationError`. Add `testTokenSupplierException` to verify it.
- Loading branch information
1 parent
ce6c4bc
commit e264cf7
Showing
2 changed files
with
19 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters