Subscriber

google.pubsub.v1. Subscriber

Represents a Subscriber

Constructor

new Subscriber(rpcImpl, requestDelimitedopt, responseDelimitedopt)

Constructs a new Subscriber service.

Parameters:
Name Type Attributes Default Description
rpcImpl $protobuf.RPCImpl

RPC implementation

requestDelimited boolean <optional>
false

Whether requests are length-delimited

responseDelimited boolean <optional>
false

Whether responses are length-delimited

Extends

  • $protobuf.rpc.Service

Methods

(static) create(rpcImpl, requestDelimitedopt, responseDelimitedopt) → {Subscriber}

Creates new Subscriber service using the specified rpc implementation.

Parameters:
Name Type Attributes Default Description
rpcImpl $protobuf.RPCImpl

RPC implementation

requestDelimited boolean <optional>
false

Whether requests are length-delimited

responseDelimited boolean <optional>
false

Whether responses are length-delimited

acknowledge(request, callback) → {undefined}

Calls Acknowledge.

Parameters:
Name Type Description
request google.pubsub.v1.IAcknowledgeRequest

AcknowledgeRequest message or plain object

callback google.pubsub.v1.Subscriber.AcknowledgeCallback

Node-style callback called with the error, if any, and Empty

acknowledge(request) → {Promise.<google.protobuf.Empty>}

Calls Acknowledge.

Parameters:
Name Type Description
request google.pubsub.v1.IAcknowledgeRequest

AcknowledgeRequest message or plain object

createSnapshot(request, callback) → {undefined}

Calls CreateSnapshot.

Parameters:
Name Type Description
request google.pubsub.v1.ICreateSnapshotRequest

CreateSnapshotRequest message or plain object

callback google.pubsub.v1.Subscriber.CreateSnapshotCallback

Node-style callback called with the error, if any, and Snapshot

createSnapshot(request) → {Promise.<google.pubsub.v1.Snapshot>}

Calls CreateSnapshot.

Parameters:
Name Type Description
request google.pubsub.v1.ICreateSnapshotRequest

CreateSnapshotRequest message or plain object

createSubscription(request, callback) → {undefined}

Calls CreateSubscription.

Parameters:
Name Type Description
request google.pubsub.v1.ISubscription

Subscription message or plain object

callback google.pubsub.v1.Subscriber.CreateSubscriptionCallback

Node-style callback called with the error, if any, and Subscription

createSubscription(request) → {Promise.<google.pubsub.v1.Subscription>}

Calls CreateSubscription.

Parameters:
Name Type Description
request google.pubsub.v1.ISubscription

Subscription message or plain object

deleteSnapshot(request, callback) → {undefined}

Calls DeleteSnapshot.

Parameters:
Name Type Description
request google.pubsub.v1.IDeleteSnapshotRequest

DeleteSnapshotRequest message or plain object

callback google.pubsub.v1.Subscriber.DeleteSnapshotCallback

Node-style callback called with the error, if any, and Empty

deleteSnapshot(request) → {Promise.<google.protobuf.Empty>}

Calls DeleteSnapshot.

Parameters:
Name Type Description
request google.pubsub.v1.IDeleteSnapshotRequest

DeleteSnapshotRequest message or plain object

deleteSubscription(request, callback) → {undefined}

Calls DeleteSubscription.

Parameters:
Name Type Description
request google.pubsub.v1.IDeleteSubscriptionRequest

DeleteSubscriptionRequest message or plain object

callback google.pubsub.v1.Subscriber.DeleteSubscriptionCallback

Node-style callback called with the error, if any, and Empty

deleteSubscription(request) → {Promise.<google.protobuf.Empty>}

Calls DeleteSubscription.

Parameters:
Name Type Description
request google.pubsub.v1.IDeleteSubscriptionRequest

DeleteSubscriptionRequest message or plain object

getSnapshot(request, callback) → {undefined}

Calls GetSnapshot.

Parameters:
Name Type Description
request google.pubsub.v1.IGetSnapshotRequest

GetSnapshotRequest message or plain object

callback google.pubsub.v1.Subscriber.GetSnapshotCallback

Node-style callback called with the error, if any, and Snapshot

getSnapshot(request) → {Promise.<google.pubsub.v1.Snapshot>}

Calls GetSnapshot.

Parameters:
Name Type Description
request google.pubsub.v1.IGetSnapshotRequest

GetSnapshotRequest message or plain object

getSubscription(request, callback) → {undefined}

Calls GetSubscription.

Parameters:
Name Type Description
request google.pubsub.v1.IGetSubscriptionRequest

GetSubscriptionRequest message or plain object

callback google.pubsub.v1.Subscriber.GetSubscriptionCallback

Node-style callback called with the error, if any, and Subscription

getSubscription(request) → {Promise.<google.pubsub.v1.Subscription>}

Calls GetSubscription.

Parameters:
Name Type Description
request google.pubsub.v1.IGetSubscriptionRequest

GetSubscriptionRequest message or plain object

listSnapshots(request, callback) → {undefined}

Calls ListSnapshots.

Parameters:
Name Type Description
request google.pubsub.v1.IListSnapshotsRequest

ListSnapshotsRequest message or plain object

callback google.pubsub.v1.Subscriber.ListSnapshotsCallback

Node-style callback called with the error, if any, and ListSnapshotsResponse

listSnapshots(request) → {Promise.<google.pubsub.v1.ListSnapshotsResponse>}

Calls ListSnapshots.

Parameters:
Name Type Description
request google.pubsub.v1.IListSnapshotsRequest

ListSnapshotsRequest message or plain object

listSubscriptions(request, callback) → {undefined}

Calls ListSubscriptions.

Parameters:
Name Type Description
request google.pubsub.v1.IListSubscriptionsRequest

ListSubscriptionsRequest message or plain object

callback google.pubsub.v1.Subscriber.ListSubscriptionsCallback

Node-style callback called with the error, if any, and ListSubscriptionsResponse

listSubscriptions(request) → {Promise.<google.pubsub.v1.ListSubscriptionsResponse>}

Calls ListSubscriptions.

Parameters:
Name Type Description
request google.pubsub.v1.IListSubscriptionsRequest

ListSubscriptionsRequest message or plain object

modifyAckDeadline(request, callback) → {undefined}

Calls ModifyAckDeadline.

Parameters:
Name Type Description
request google.pubsub.v1.IModifyAckDeadlineRequest

ModifyAckDeadlineRequest message or plain object

callback google.pubsub.v1.Subscriber.ModifyAckDeadlineCallback

Node-style callback called with the error, if any, and Empty

modifyAckDeadline(request) → {Promise.<google.protobuf.Empty>}

Calls ModifyAckDeadline.

Parameters:
Name Type Description
request google.pubsub.v1.IModifyAckDeadlineRequest

ModifyAckDeadlineRequest message or plain object

modifyPushConfig(request, callback) → {undefined}

Calls ModifyPushConfig.

Parameters:
Name Type Description
request google.pubsub.v1.IModifyPushConfigRequest

ModifyPushConfigRequest message or plain object

callback google.pubsub.v1.Subscriber.ModifyPushConfigCallback

Node-style callback called with the error, if any, and Empty

modifyPushConfig(request) → {Promise.<google.protobuf.Empty>}

Calls ModifyPushConfig.

Parameters:
Name Type Description
request google.pubsub.v1.IModifyPushConfigRequest

ModifyPushConfigRequest message or plain object

pull(request, callback) → {undefined}

Calls Pull.

Parameters:
Name Type Description
request google.pubsub.v1.IPullRequest

PullRequest message or plain object

callback google.pubsub.v1.Subscriber.PullCallback

Node-style callback called with the error, if any, and PullResponse

pull(request) → {Promise.<google.pubsub.v1.PullResponse>}

Calls Pull.

Parameters:
Name Type Description
request google.pubsub.v1.IPullRequest

PullRequest message or plain object

seek(request, callback) → {undefined}

Calls Seek.

Parameters:
Name Type Description
request google.pubsub.v1.ISeekRequest

SeekRequest message or plain object

callback google.pubsub.v1.Subscriber.SeekCallback

Node-style callback called with the error, if any, and SeekResponse

seek(request) → {Promise.<google.pubsub.v1.SeekResponse>}

Calls Seek.

Parameters:
Name Type Description
request google.pubsub.v1.ISeekRequest

SeekRequest message or plain object

streamingPull(request, callback) → {undefined}

Calls StreamingPull.

Parameters:
Name Type Description
request google.pubsub.v1.IStreamingPullRequest

StreamingPullRequest message or plain object

callback google.pubsub.v1.Subscriber.StreamingPullCallback

Node-style callback called with the error, if any, and StreamingPullResponse

streamingPull(request) → {Promise.<google.pubsub.v1.StreamingPullResponse>}

Calls StreamingPull.

Parameters:
Name Type Description
request google.pubsub.v1.IStreamingPullRequest

StreamingPullRequest message or plain object

updateSnapshot(request, callback) → {undefined}

Calls UpdateSnapshot.

Parameters:
Name Type Description
request google.pubsub.v1.IUpdateSnapshotRequest

UpdateSnapshotRequest message or plain object

callback google.pubsub.v1.Subscriber.UpdateSnapshotCallback

Node-style callback called with the error, if any, and Snapshot

updateSnapshot(request) → {Promise.<google.pubsub.v1.Snapshot>}

Calls UpdateSnapshot.

Parameters:
Name Type Description
request google.pubsub.v1.IUpdateSnapshotRequest

UpdateSnapshotRequest message or plain object

updateSubscription(request, callback) → {undefined}

Calls UpdateSubscription.

Parameters:
Name Type Description
request google.pubsub.v1.IUpdateSubscriptionRequest

UpdateSubscriptionRequest message or plain object

callback google.pubsub.v1.Subscriber.UpdateSubscriptionCallback

Node-style callback called with the error, if any, and Subscription

updateSubscription(request) → {Promise.<google.pubsub.v1.Subscription>}

Calls UpdateSubscription.

Parameters:
Name Type Description
request google.pubsub.v1.IUpdateSubscriptionRequest

UpdateSubscriptionRequest message or plain object

Type Definitions

AcknowledgeCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#acknowledge.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.protobuf.Empty <optional>

Empty

CreateSnapshotCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#createSnapshot.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.Snapshot <optional>

Snapshot

CreateSubscriptionCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#createSubscription.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.Subscription <optional>

Subscription

DeleteSnapshotCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#deleteSnapshot.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.protobuf.Empty <optional>

Empty

DeleteSubscriptionCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#deleteSubscription.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.protobuf.Empty <optional>

Empty

GetSnapshotCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#getSnapshot.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.Snapshot <optional>

Snapshot

GetSubscriptionCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#getSubscription.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.Subscription <optional>

Subscription

ListSnapshotsCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#listSnapshots.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.ListSnapshotsResponse <optional>

ListSnapshotsResponse

ListSubscriptionsCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#listSubscriptions.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.ListSubscriptionsResponse <optional>

ListSubscriptionsResponse

ModifyAckDeadlineCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#modifyAckDeadline.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.protobuf.Empty <optional>

Empty

ModifyPushConfigCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#modifyPushConfig.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.protobuf.Empty <optional>

Empty

PullCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#pull.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.PullResponse <optional>

PullResponse

SeekCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#seek.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.SeekResponse <optional>

SeekResponse

StreamingPullCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#streamingPull.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.StreamingPullResponse <optional>

StreamingPullResponse

UpdateSnapshotCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#updateSnapshot.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.Snapshot <optional>

Snapshot

UpdateSubscriptionCallback(error, responseopt)

Callback as used by google.pubsub.v1.Subscriber#updateSubscription.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.pubsub.v1.Subscription <optional>

Subscription