[
https://issues.apache.org/jira/browse/SENTRY-902?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14951358#comment-14951358
]
Sravya Tirukkovalur commented on SENTRY-902:
--------------------------------------------
Thanks for the patch [~Yibing]! Would you mind posting your patch on Review
board? That way it would be easy to leave comments? I would be happy to help
you get started. Let me know.
Some comments:
- All configuration parameters go into ServiceConstants.java
- I agree current retry logic is hard to follow. Ideally it should look like
following with having a recursive call.
{noformat}
int count = 0;
while(true) {
try {
// Some Code
// break out of loop, or return, on success
} catch (SomeException e) {
// handle exception
if (++count == maxTries) throw e;
}
}
{noformat}
> SimpleDBProviderBackend should retry the authrization process properly
> ----------------------------------------------------------------------
>
> Key: SENTRY-902
> URL: https://issues.apache.org/jira/browse/SENTRY-902
> Project: Sentry
> Issue Type: Bug
> Affects Versions: 1.4.0
> Reporter: Yibing Shi
> Assignee: Yibing Shi
> Attachments: SENTRY-902.1.patch, SENTRY-902.2.patch,
> SENTRY-902.3.patch
>
>
> Currently {{SimpleDBProviderBackend}} doesn't retry the authorization
> properly. Problems are:
> # It retry count is hard coded. Always retries once
> # No wait time between before retries
> # The method calls itself recursively, which could causes stack overflow if
> retries too many times
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)