Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reconcile RetrySettings & Clock (google-cloud-java part) #1738

Merged
merged 9 commits into from
Mar 21, 2017

Conversation

vam-google
Copy link
Contributor

Reconcile RetrySettings in GAX with RetryParams in google-cloud-java
#1574
Reconcile NanoClock in GAX with Clock in google-cloud-java
#1575

Reconcile RetrySettings in GAX with RetryParams in google-cloud-java
googleapis#1574
Reconcile NanoClock in GAX with Clock in google-cloud-java
googleapis#1575
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Mar 11, 2017
pom.xml Outdated
@@ -92,7 +92,7 @@
<github.global.server>github</github.global.server>
<google.auth.version>0.6.0</google.auth.version>
<grpc.version>1.0.3</grpc.version>
<gax.version>0.4.0</gax.version>
<gax.version>0.3.2-SNAPSHOT</gax.version>

This comment was marked as spam.

This comment was marked as spam.


private TranslateOptions options;
private TranslateRpcFactory rpcFactoryMock;
private TranslateRpc translateRpcMock;
private Translate translate;

@Rule
public ExpectedException thrown = ExpectedException.none();
@Rule public ExpectedException thrown = ExpectedException.none();

This comment was marked as spam.

This comment was marked as spam.


private static final String META_FILE_ROOT = "/META-INF/maven/";
private static final String META_VERSION_KEY = "version";
private static final RetrySettings DEFAULT_RETRY_SETTINGS = getDefaultRetrySettingsBuilder()
.build();
private static final RetrySettings NO_RETRY_SETTINGS = getDefaultRetrySettingsBuilder()

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

*
* @param <V> return value of the closure that is being run with retries
* Utility class for retrying operations. For more details about the parameters, see {@link
* RetrySettings}.

This comment was marked as spam.

This comment was marked as spam.

@@ -264,6 +261,12 @@ boolean shouldRetry(Exception ex) {
}

@Override
public TimedAttemptSettings createNextAttempt(Throwable prevThrowable,
TimedAttemptSettings prevSettings) {
return null;

This comment was marked as spam.

This comment was marked as spam.

@@ -295,12 +295,9 @@ private static String message(IOException exception) {
return exception.getMessage();
}

protected static void translateAndPropagateIfPossible(RetryHelper.RetryHelperException ex) {
protected static void translate(RetryHelper.RetryHelperException ex) {
if (ex.getCause() instanceof BaseServiceException) {
throw (BaseServiceException) ex.getCause();
}

This comment was marked as spam.

This comment was marked as spam.

@@ -33,7 +35,7 @@
/**
* Exception handling used by {@link RetryHelper}.
*/
public final class ExceptionHandler implements Serializable {
public final class ExceptionHandler implements ExceptionRetryAlgorithm, Serializable {

This comment was marked as spam.

This comment was marked as spam.

@@ -33,7 +35,7 @@
/**
* Exception handling used by {@link RetryHelper}.

This comment was marked as spam.

@shinfan
Copy link
Contributor

shinfan commented Mar 20, 2017

I am concerned with the CI build failure.

@vam-google
Copy link
Contributor Author

Adressed PR comments. PTAL. The CI will not pass at this point, because it needs #1775 PR to be merged first (without that the code is not compilable)

@shinfan
Copy link
Contributor

shinfan commented Mar 20, 2017

LGTM after at least two of the tests pass.

@vam-google vam-google merged commit 95b70eb into googleapis:master Mar 21, 2017
@coveralls
Copy link

Coverage Status

Changes Unknown when pulling ca31a82 on vam-google:master into ** on GoogleCloudPlatform:master**.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants