Skip to content

Commit

Permalink
delete handwritten PushConfig
Browse files Browse the repository at this point in the history
  • Loading branch information
pongad committed Jan 6, 2017
1 parent b0cac2f commit 49107e2
Show file tree
Hide file tree
Showing 10 changed files with 57 additions and 528 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
import com.google.cloud.Page;
import com.google.cloud.Policy;
import com.google.cloud.Service;
import com.google.pubsub.v1.PushConfig;
import java.io.IOException;
import java.util.List;
import java.util.Map;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@
import com.google.pubsub.v1.ListTopicsRequest;
import com.google.pubsub.v1.ListTopicsResponse;
import com.google.pubsub.v1.ModifyPushConfigRequest;
import com.google.pubsub.v1.PushConfig;
import java.io.IOException;
import java.util.List;
import java.util.Map;
Expand Down Expand Up @@ -326,12 +327,12 @@ public void replacePushConfig(String subscription, PushConfig pushConfig) {

@Override
public Future<Void> replacePushConfigAsync(String subscription, PushConfig pushConfig) {
ModifyPushConfigRequest request = ModifyPushConfigRequest.newBuilder()
.setSubscription(
SubscriberClient.formatSubscriptionName(getOptions().getProjectId(), subscription))
.setPushConfig(pushConfig != null ? pushConfig.toPb()
: com.google.pubsub.v1.PushConfig.getDefaultInstance())
.build();
ModifyPushConfigRequest request =
ModifyPushConfigRequest.newBuilder()
.setSubscription(
SubscriberClient.formatSubscriptionName(getOptions().getProjectId(), subscription))
.setPushConfig(pushConfig != null ? pushConfig : PushConfig.getDefaultInstance())
.build();
return transform(rpc.modify(request), EMPTY_TO_VOID_FUNCTION);
}

Expand Down

This file was deleted.

Loading

0 comments on commit 49107e2

Please sign in to comment.