-
Notifications
You must be signed in to change notification settings - Fork 9.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Google Cloud: PubSub Topic and Subscription resources #3671
Conversation
All the other resources are prefixed by the name of the API that creates them, so instance becomes compute_instance and so on. Here, if you could use google_pubsub_topic and so on, that would be more consistent. |
@lwander I haven't used the push_config guff and wasn't entirely sure how to test it. I'll take a look at it later tonight @sparkprime I was tempted to pull the PR and redo so I'll make that change tonight as well. |
@lwander the push config section is a bit beyond what I'm up to right now. if I have time at the end of my current project I'll add it but odds are someone else will need it first. documentation has been updated as well @sparkprime resources/tests renamed to include pubsub hiearchy section |
@coffeepac, in that case, are you OK if I pick up where you left off? |
@lwander have at it my friend. Need me to do anything for that? First time passing off a PR on a project that isn't mine/internal. |
@coffeepac, I think we need someone with commit privileges to turn this into a branch so you'll get credit for starting this off. Maybe @sparkprime could help? |
This PR seems to also include some aws changes |
yeah, looks like a bad/weird rebase. those shouldn't be there. I will sort that out tonight. my apologies. |
0196d1f
to
e38d694
Compare
@sparkprime @lwander okay! sorted out the funky rebase, I have no idea what I did but a little rebase back onto upstream/master and sanity returns. thanks git! |
@lwander Shall I merge this and then you can do another PR to add whatever else, or are you planning on changing it in backwards-incompatible ways? In which case I won't do that :) |
That sounds best |
ForceNew: true, | ||
}, | ||
|
||
"topic_computed": &schema.Schema{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It doesn't look like this is documented and I don't see what use it can be. Can we remove it before merging this PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
topic_computed is the canonical name of the topic that is required by the API for creating the subscription.
however, it is already being computed from the name schema value. I'll remove it shortly.
@sparkprime change made and build fixed. ready for launch. |
Thanks, I'll merge when the current release freeze ends :) |
Hooray! Thanks buddy!
|
ec2d9d9
to
a88a69c
Compare
@lwander @sparkprime my apologies for changing this after you had accepted it, but turns out I needed the ackDeadlineSeconds config param and while I was in there I added the pushConfig sections. and a question: when is the code freeze until? thanks! |
Sorry, it's actually been several days since the freeze ended but I had a bunch of other stuff going on as well as the Thanksgiving holidays and it slipped my mind. Thanks for adding the extra stuff! There's one general problem and that's that we tend to keep as close as possible to the Google APIs, which means that the push config stuff ought to be in a nested sub-block "push_config" with "push_endpoint" and "attributes" underneath it. The way this is done in Terraform right now is to use a list of 1 element to represent the block, and raise an error if the list is > 1 elements. There is an example here with the 'website' field: https://github.com/hashicorp/terraform/blob/master/builtin/providers/google/resource_storage_bucket.go I can't merge this now as if I were to do that and we were then to change it, the change would not be backwards-compatible. However if you were to make that simple change to add the block, you would be the undisputed hero of Terraform Google pub/sub :) |
Well, I do love being a hero... On Tue, Dec 1, 2015 at 10:58 PM, Dave Cunningham [email protected]
|
@sparkprime I believe I have addressed your last two comments. thanks for your quick response once already! |
Nice one! You're not going to believe this but there's another release freeze #4133 But I'll definitely merge it when that's over. |
Freeze is over, but can I ask you to squash your commits. Last thing, I promise :) |
…e that Conflicts: builtin/providers/google/provider.go builtin/providers/google/resource_subscription.go builtin/providers/google/resource_subscription_test.go golang pubsub SDK has been released. moved topics/subscriptions to use that Conflicts: builtin/providers/google/provider.go builtin/providers/google/resource_subscription.go builtin/providers/google/resource_subscription_test.go file renames and add documentation files remove typo'd merge and type file move add to index page as well only need to define that once remove topic_computed schema value I think this was used at one point but is no longer. away. cleanup typo adds a couple more config values - ackDeadlineSeconds: number of seconds to wait for an ack - pushAttributes: attributes of a push subscription - pushEndpoint: target for a push subscription rearrange to better match current conventions respond to all of the comments
1c4cf3a
to
6f7ef2f
Compare
@sparkprime looks like we're good to go with that squash. can you take a quick look and make sure i didn't miss anything? |
Google Cloud: PubSub Topic and Subscription resources
🎊 🎊 🎊 Thank you @coffeepac! |
Glad to help! Now to find the time to finish the bigquery PR 😃 |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
create the topics and subscriptions resources.