protected Builder(ClientContext clientContext) { super(SubscriberStubSettings.newBuilder(clientContext)); }
/** Returns a builder for the default ChannelProvider for this service. */ public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { return SubscriberStubSettings.defaultGrpcTransportProviderBuilder(); }
@Override public SubscriberStubSettings build() throws IOException { return new SubscriberStubSettings(this); } }
callableFactory.createUnaryCallable( createSubscriptionTransportSettings, settings.createSubscriptionSettings(), clientContext); this.getSubscriptionCallable = callableFactory.createUnaryCallable( getSubscriptionTransportSettings, settings.getSubscriptionSettings(), clientContext); this.updateSubscriptionCallable = callableFactory.createUnaryCallable( updateSubscriptionTransportSettings, settings.updateSubscriptionSettings(), clientContext); this.listSubscriptionsCallable = callableFactory.createUnaryCallable( listSubscriptionsTransportSettings, settings.listSubscriptionsSettings(), clientContext); this.listSubscriptionsPagedCallable = callableFactory.createPagedCallable( listSubscriptionsTransportSettings, settings.listSubscriptionsSettings(), clientContext); this.deleteSubscriptionCallable = callableFactory.createUnaryCallable( deleteSubscriptionTransportSettings, settings.deleteSubscriptionSettings(), clientContext); this.modifyAckDeadlineCallable = callableFactory.createUnaryCallable(
SubscriberStubSettings.newBuilder() .setTransportChannelProvider( SubscriberStubSettings.defaultGrpcTransportProviderBuilder() .setMaxInboundMessageSize(20 << 20) // 20MB .build())
/** * Constructs an instance of SubscriptionAdminClient, using the given settings. This is protected * so that it is easy to make a subclass, but otherwise, the static factory methods should be * preferred. */ protected SubscriptionAdminClient(SubscriptionAdminSettings settings) throws IOException { this.settings = settings; this.stub = ((SubscriberStubSettings) settings.getStubSettings()).createStub(); }
/** Returns the object with the settings used for calls to createSnapshot. */ public UnaryCallSettings<CreateSnapshotRequest, Snapshot> createSnapshotSettings() { return ((SubscriberStubSettings) getStubSettings()).createSnapshotSettings(); }
/** Returns the object with the settings used for calls to createSubscription. */ public UnaryCallSettings<Subscription, Subscription> createSubscriptionSettings() { return ((SubscriberStubSettings) getStubSettings()).createSubscriptionSettings(); }
/** Returns the object with the settings used for calls to acknowledge. */ /* package-private */ UnaryCallSettings<AcknowledgeRequest, Empty> acknowledgeSettings() { return ((SubscriberStubSettings) getStubSettings()).acknowledgeSettings(); }
private static Builder createDefault() { return new Builder(SubscriberStubSettings.newBuilder()); }
public static TransportChannelProvider defaultTransportChannelProvider() { return defaultGrpcTransportProviderBuilder().build(); }
public static final GrpcSubscriberStub create( ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { return new GrpcSubscriberStub( SubscriberStubSettings.newBuilder().build(), clientContext, callableFactory); }
public static final GrpcSubscriberStub create(ClientContext clientContext) throws IOException { return new GrpcSubscriberStub(SubscriberStubSettings.newBuilder().build(), clientContext); }
private SubscriberStub getSubscriber(ProcessContext context) throws IOException { final SubscriberStubSettings subscriberStubSettings = SubscriberStubSettings.newBuilder() .setCredentialsProvider(FixedCredentialsProvider.create(getGoogleCredentials(context))) .build(); return GrpcSubscriberStub.create(subscriberStubSettings); } }
SubscriberStubSettings.newBuilder() .setExecutorProvider(FixedExecutorProvider.create(alarmsExecutor)) .setCredentialsProvider(builder.credentialsProvider)
@Override public SubscriberStub createSubscriberStub() { SubscriberStubSettings.Builder subscriberStubSettings = SubscriberStubSettings.newBuilder();
@Override public SubscriberStub createSubscriberStub() { SubscriberStubSettings.Builder subscriberStubSettings = SubscriberStubSettings.newBuilder();