Skip to content

Commit

Permalink
Merge pull request #4153 from lwander/gcp-pubsub-docs-update
Browse files Browse the repository at this point in the history
provider/google: Added missing pubsub documentation
  • Loading branch information
lwander committed Dec 4, 2015
2 parents 29d4266 + 738ad14 commit 2a49ebb
Showing 1 changed file with 23 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,15 @@ Creates a subscription in Google's pubsub queueing system. For more information

```
resource "google_pubsub_subscription" "default" {
name = "default-subscription"
topic = "default-topic"
name = "default-subscription"
topic = "default-topic"
ack_deadline_seconds = 20
push_config {
endpoint = "https://example.com/push"
attributes {
x-goog-version = "v1"
}
}
}
```

Expand All @@ -28,12 +35,22 @@ The following arguments are supported:

* `name` - (Required) A unique name for the resource, required by pubsub.
Changing this forces a new resource to be created.

* `topic` - (Required) A topic to bind this subscription to, required by pubsub.
Changing this forces a new resource to be created.

## Attributes Reference
* `ack_deadline_seconds` - (Optional) The maximum number of seconds a
subscriber has to acknowledge a received message, otherwise the message is
redelivered. Changing this forces a new resource to be created.

The optional `push_config` block supports:

The following attributes are exported:
* `push_endpoint` - (Optional) The URL of the endpoint to which messages should
be pushed. Changing this forces a new resource to be created.

* `name` - The name of the resource.
* `topic` - The topic to bind this resource to.
* `attributes` - (Optional) Key-value pairs of API supported attributes used
to control aspects of the message delivery. Currently, only
`x-goog-version` is supported, which controls the format of the data
delivery. For more information, read [the API docs
here](https://cloud.google.com/pubsub/reference/rest/v1/projects.subscriptions#PushConfig.FIELDS.attributes).
Changing this forces a new resource to be created.

0 comments on commit 2a49ebb

Please sign in to comment.