-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Ansible: return_if_object should only allow 404 on certain situations #481
Conversation
b62650f
to
c9ba5ed
Compare
I am a robot that works on MagicModules PRs! I built this PR into one or more PRs on other repositories, and when those are closed, this PR will also be merged and closed. |
I am (still) a robot that works on MagicModules PRs! I just wanted to let you know that your changes (as of commit 4dddf4e) have been included in your existing downstream PRs. |
@@ -12,16 +12,14 @@ | |||
# See the License for the specific language governing permissions and | |||
# limitations under the License. | |||
-%> | |||
<% if object.kind? -%> | |||
def fetch_resource(module, link, kind): | |||
<%= |
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.
The method_decl
and method_call
functions were designed to get away from this anti-pattern.
Merged PR #484.
The INFO logs are getting filled with what looks like debug level information. When compiling 1 product for 1 provider there are 16k INFO statements and zero DEBUG level logs. This makes it difficult to show anything important in the standard logging without escalating to WARN. This change will move most of the output to debug level and set the default logging level to INFO. The -d flag will still show all 16K lines of output but at INFO there will only be a message for what is getting generated and what is going to be excluded. This will require a bit of a paradigm shift for people to start using debug going forward where info was previously used. <!-- A summary of the changes in this commit goes here --> <!-- Changes per downstream repository. For each repository that you expect to have changed, find the [tag] and write your commit message beneath it. More-specific tags replace less-specific tags. For example, if you provide a message under [all], a message under [puppet], and a message under [puppet-dns], the Terraform repository will have the resulting commit made using the [all] message, the Puppet Compute repository will have its commit made using [puppet], and the Puppet DNS repository will have its commit made using [puppet-dns]. You can delete unused tags, but you don't need to. The structure of the PR body is important to our CI system! The comments can be deleted, but if you want to make the downstream commits sensible, you'll need to leave the dashed line separating this PR's changes from the commit messages for downstream commits. --> ----------------------------------------------------------------- # [all] ## [terraform] ## [puppet] ### [puppet-bigquery] ### [puppet-compute] ### [puppet-container] ### [puppet-dns] ### [puppet-logging] ### [puppet-pubsub] ### [puppet-resourcemanager] ### [puppet-sql] ### [puppet-storage] ## [chef] ### [chef-compute] ### [chef-container] ### [chef-dns] ### [chef-logging] ### [chef-spanner] ### [chef-sql] ### [chef-storage] ## [ansible]
All the other providers define their config class within their Provide module so changing Terraform to be consistent with the other providers. <!-- A summary of the changes in this commit goes here --> <!-- Changes per downstream repository. For each repository that you expect to have changed, find the [tag] and write your commit message beneath it. More-specific tags replace less-specific tags. For example, if you provide a message under [all], a message under [puppet], and a message under [puppet-dns], the Terraform repository will have the resulting commit made using the [all] message, the Puppet Compute repository will have its commit made using [puppet], and the Puppet DNS repository will have its commit made using [puppet-dns]. You can delete unused tags, but you don't need to. The structure of the PR body is important to our CI system! The comments can be deleted, but if you want to make the downstream commits sensible, you'll need to leave the dashed line separating this PR's changes from the commit messages for downstream commits. --> ----------------------------------------------------------------- # [all] ## [terraform] ## [puppet] ### [puppet-bigquery] ### [puppet-compute] ### [puppet-container] ### [puppet-dns] ### [puppet-logging] ### [puppet-pubsub] ### [puppet-resourcemanager] ### [puppet-sql] ### [puppet-storage] ## [chef] ### [chef-compute] ### [chef-container] ### [chef-dns] ### [chef-logging] ### [chef-spanner] ### [chef-sql] ### [chef-storage] ## [ansible]
<!-- A summary of the changes in this commit goes here --> Changes that allow building multiple different products for a single provider in a single command. Allows -p/--product to take an array of products Also introduces a -a/--all flag to be used instead of the products parameter. <!-- Changes per downstream repository. For each repository that you expect to have changed, find the [tag] and write your commit message beneath it. More-specific tags replace less-specific tags. For example, if you provide a message under [all], a message under [puppet], and a message under [puppet-dns], the Terraform repository will have the resulting commit made using the [all] message, the Puppet Compute repository will have its commit made using [puppet], and the Puppet DNS repository will have its commit made using [puppet-dns]. You can delete unused tags, but you don't need to. The structure of the PR body is important to our CI system! The comments can be deleted, but if you want to make the downstream commits sensible, you'll need to leave the dashed line separating this PR's changes from the commit messages for downstream commits. --> -----------------------------------------------------------------
Merged PR #392.
Tracked submodules are build/puppet/_bundle build/puppet/auth build/puppet/bigquery build/puppet/compute build/puppet/sql build/puppet/storage build/puppet/spanner build/puppet/container build/puppet/dns build/puppet/pubsub build/puppet/resourcemanager build/chef/_bundle build/chef/auth build/chef/compute build/chef/sql build/chef/storage build/chef/spanner build/chef/container build/chef/dns build/chef/iam build/terraform build/ansible.
P/C had a bug where they always allowed 404s (bad!). I introduced that into Ansible too, which is a problem. This will fix it.
Create, update, delete - 404 = error has occurred and we should alert the user
Get - 404 = resource not found, which is okay because we're about to grab it.
[all]
[terraform]
[puppet]
[puppet-bigquery]
[puppet-compute]
[puppet-container]
[puppet-dns]
[puppet-logging]
[puppet-pubsub]
[puppet-resourcemanager]
[puppet-sql]
[puppet-storage]
[chef]
[chef-compute]
[chef-container]
[chef-dns]
[chef-logging]
[chef-spanner]
[chef-sql]
[chef-storage]
[ansible]