Reference documentation and code samples for the Cloud PubSub V1 Client class CreateSnapshotRequest.
Request for the CreateSnapshot
method.
Generated from protobuf message google.pubsub.v1.CreateSnapshotRequest
Methods
__construct
Constructor.
Parameters | |
---|---|
Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ name |
string
Required. User-provided name for this snapshot. If the name is not provided in the request, the server will assign a random name for this snapshot on the same project as the subscription. Note that for REST API requests, you must specify a name. See the resource name rules. Format is |
↳ subscription |
string
Required. The subscription whose backlog the snapshot retains. Specifically, the created snapshot is guaranteed to retain: (a) The existing backlog on the subscription. More precisely, this is defined as the messages in the subscription's backlog that are unacknowledged upon the successful completion of the |
↳ labels |
array|Google\Protobuf\Internal\MapField
|
getName
Required. User-provided name for this snapshot. If the name is not provided
in the request, the server will assign a random name for this snapshot on
the same project as the subscription. Note that for REST API requests, you
must specify a name. See the a
href="https://cloud.google.com/pubsub/docs/admin#resource_names" resource
name rules. Format is projects/{project}/snapshots/{snap}
.
Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {
Returns | |
---|---|
Type | Description |
string |
setName
Required. User-provided name for this snapshot. If the name is not provided
in the request, the server will assign a random name for this snapshot on
the same project as the subscription. Note that for REST API requests, you
must specify a name. See the a
href="https://cloud.google.com/pubsub/docs/admin#resource_names" resource
name rules. Format is projects/{project}/snapshots/{snap}
.
Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getSubscription
Required. The subscription whose backlog the snapshot retains.
Specifically, the created snapshot is guaranteed to retain:
(a) The existing backlog on the subscription. More precisely, this is
defined as the messages in the subscription's backlog that are
unacknowledged upon the successful completion of the
CreateSnapshot
request; as well as:
(b) Any messages published to the subscription's topic following the
successful completion of the CreateSnapshot request.
Format is projects/{project}/subscriptions/{sub}
.
Generated from protobuf field string subscription = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {
Returns | |
---|---|
Type | Description |
string |
setSubscription
Required. The subscription whose backlog the snapshot retains.
Specifically, the created snapshot is guaranteed to retain:
(a) The existing backlog on the subscription. More precisely, this is
defined as the messages in the subscription's backlog that are
unacknowledged upon the successful completion of the
CreateSnapshot
request; as well as:
(b) Any messages published to the subscription's topic following the
successful completion of the CreateSnapshot request.
Format is projects/{project}/subscriptions/{sub}
.
Generated from protobuf field string subscription = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getLabels
See Creating and managing labels.
Generated from protobuf field map<string, string> labels = 3;
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\MapField |
setLabels
See Creating and managing labels.
Generated from protobuf field map<string, string> labels = 3;
Parameter | |
---|---|
Name | Description |
var |
array|Google\Protobuf\Internal\MapField
|
Returns | |
---|---|
Type | Description |
$this |