{"action":"created","issue":{"url":"https://api.github.com/repos/saltstack-formulas/postgres-formula/issues/119","repository_url":"https://api.github.com/repos/saltstack-formulas/postgres-formula","labels_url":"https://api.github.com/repos/saltstack-formulas/postgres-formula/issues/119/labels{/name}","comments_url":"https://api.github.com/repos/saltstack-formulas/postgres-formula/issues/119/comments","events_url":"https://api.github.com/repos/saltstack-formulas/postgres-formula/issues/119/events","html_url":"https://github.com/saltstack-formulas/postgres-formula/pull/119","id":175967922,"number":119,"title":"Map Pillar dicts for PostgreSQL entities to the Salt state arguments","user":{"login":"vutny","id":16338056,"avatar_url":"https://avatars.githubusercontent.com/u/16338056?v=3","gravatar_id":"","url":"https://api.github.com/users/vutny","html_url":"https://github.com/vutny","followers_url":"https://api.github.com/users/vutny/followers","following_url":"https://api.github.com/users/vutny/following{/other_user}","gists_url":"https://api.github.com/users/vutny/gists{/gist_id}","starred_url":"https://api.github.com/users/vutny/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vutny/subscriptions","organizations_url":"https://api.github.com/users/vutny/orgs","repos_url":"https://api.github.com/users/vutny/repos","events_url":"https://api.github.com/users/vutny/events{/privacy}","received_events_url":"https://api.github.com/users/vutny/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2016-09-09T09:35:30Z","updated_at":"2016-09-12T03:30:02Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/saltstack-formulas/postgres-formula/pulls/119","html_url":"https://github.com/saltstack-formulas/postgres-formula/pull/119","diff_url":"https://github.com/saltstack-formulas/postgres-formula/pull/119.diff","patch_url":"https://github.com/saltstack-formulas/postgres-formula/pull/119.patch"},"body":"Hi @gravyboat \r\n\r\nThis PR introduces a breaking change in Pillar layout for such PostgreSQL entities as `users`, `tablespaces`, `databases`, `schemas` and `extensions`.\r\nBasically it gets the above dictionaries and converts underlying structure to the `postgres` state module syntax to render in the resulting SLS file. This is a pretty straight forward approach to support all arguments provided by particular state without a need to put `if` condition for each of them. Also it becomes natural to refer Salt documentation for the complete list and description of supported arguments.\r\nAdded explanation about this in `pillar.example` file.\r\n\r\nList of backwards-incompatible changes:\r\n* Previously, the `runas` argument in the Pillar was mapped to the `user` arg, and the `user` Pillar arg was mapped to the `db_user` arg in the resulting state. This is totally confusing, undocumented and hard to figure out from SLS code. Now the `user` is really the `user` and `db_user` == `db_user`.\r\n* All the entities now support the `ensure` argument (including tablespaces).\r\n* Secure permissions (`700`) is applied to a tablespace directory.\r\n* The `schemas` becomes a standalone dict at the same level as `databases` or `users`, its name and arguments are mapped to the `postgres_schema` state.\r\n* PostgreSQL extensions cannot be created *in database*, they are installed in some schema or globally. So, the `extensions` dict is also separated like the `schemas` dict, and, as expected, the arguments are mapped to the `postgres_extension` state.\r\n\r\nOverall, these changes just make things work as expected, without a need to edit SLS if there would be any new args in the `postgres` states, the SLS becomes more compact and readable, easier to debug."},"comment":{"url":"https://api.github.com/repos/saltstack-formulas/postgres-formula/issues/comments/246235711","html_url":"https://github.com/saltstack-formulas/postgres-formula/pull/119#issuecomment-246235711","issue_url":"https://api.github.com/repos/saltstack-formulas/postgres-formula/issues/119","id":246235711,"user":{"login":"gravyboat","id":1396878,"avatar_url":"https://avatars.githubusercontent.com/u/1396878?v=3","gravatar_id":"","url":"https://api.github.com/users/gravyboat","html_url":"https://github.com/gravyboat","followers_url":"https://api.github.com/users/gravyboat/followers","following_url":"https://api.github.com/users/gravyboat/following{/other_user}","gists_url":"https://api.github.com/users/gravyboat/gists{/gist_id}","starred_url":"https://api.github.com/users/gravyboat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gravyboat/subscriptions","organizations_url":"https://api.github.com/users/gravyboat/orgs","repos_url":"https://api.github.com/users/gravyboat/repos","events_url":"https://api.github.com/users/gravyboat/events{/privacy}","received_events_url":"https://api.github.com/users/gravyboat/received_events","type":"User","site_admin":false},"created_at":"2016-09-12T03:30:02Z","updated_at":"2016-09-12T03:30:02Z","body":"@javierbertoli You can merge it if you have the perms to do so, I'm always happy to share the load of reviewing all of these with other people."}}
{"actor":{"display_login":"gravyboat"}}