Methods like GitHubServices.getBranch are using retry but are not retried because they are using httpRequestOption which catches exceptions and returns None.
Similarly, the GitHubServices.createRepository method uses the construct httpRequestOption().getOrElse(httpRequest()), so the API call in the httpRequestOption does not get retried.
The retry logic needs to be smarter. Perhaps create httpRequestOptionWithRetry and httpRequestWithRetry and modify code accordingly, e.g., do not retry around that.
Methods like
GitHubServices.getBranch
are usingretry
but are not retried because they are usinghttpRequestOption
which catches exceptions and returnsNone
.Similarly, the GitHubServices.createRepository method uses the construct
httpRequestOption().getOrElse(httpRequest())
, so the API call in thehttpRequestOption
does not get retried.The retry logic needs to be smarter. Perhaps create
httpRequestOptionWithRetry
andhttpRequestWithRetry
and modify code accordingly, e.g., do not retry around that.