)]}'
{"manifests/plugins/ovs/opendaylight.pp":[{"author":{"_account_id":6681,"name":"Brent Eagles","email":"beagles@redhat.com","username":"beagles"},"change_message_id":"75d3773d696b4338ba82698a2d629051be8bffe2","unresolved":false,"context_lines":[{"line_number":73,"context_line":"  }"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"  # set mappings for VLAN or Flat provider networks"},{"line_number":76,"context_line":"  if ($provider_mappings !\u003d []) {"},{"line_number":77,"context_line":"    $pr_map_str \u003d join($provider_mappings, \u0027,\u0027)"},{"line_number":78,"context_line":"    exec { \u0027Set provider_mappings Other Option\u0027:"},{"line_number":79,"context_line":"      command \u003d\u003e \"ovs-vsctl set Open_vSwitch $(ovs-vsctl get Open_vSwitch . _uuid) other_config:provider_mappings\u003d${pr_map_str}\","}],"source_content_type":"text/x-puppet","patch_set":1,"id":"1a95cdbc_8d914d55","line":76,"updated":"2016-10-05 17:29:27.000000000","message":"I know this is pretty much how OVS is doing this but what do you think of doing something like:\n\n\nif ! empty($provider_mappings) {\n    $pr_map_str \u003d join(any2array($provider_mappings), \u0027,\u0027))\n\nI know this change is precisely because you are changing tripleo to pass this in via a list, but this would also work for other users of the module if they were to pass in a string instead. As it is here if someone somehow passes in an empty string, the if will test true and the code will choke on the join.","commit_id":"00046793bc1a06e1ec02277f422296368a88e8f9"},{"author":{"_account_id":7984,"name":"Jason Guiditta","email":"jguiditt@redhat.com","username":"jayg"},"change_message_id":"516f20e5556006ce76f2cc3aff2807dfb6f32482","unresolved":false,"context_lines":[{"line_number":73,"context_line":"  }"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"  # set mappings for VLAN or Flat provider networks"},{"line_number":76,"context_line":"  if ($provider_mappings !\u003d []) {"},{"line_number":77,"context_line":"    $pr_map_str \u003d join($provider_mappings, \u0027,\u0027)"},{"line_number":78,"context_line":"    exec { \u0027Set provider_mappings Other Option\u0027:"},{"line_number":79,"context_line":"      command \u003d\u003e \"ovs-vsctl set Open_vSwitch $(ovs-vsctl get Open_vSwitch . _uuid) other_config:provider_mappings\u003d${pr_map_str}\","}],"source_content_type":"text/x-puppet","patch_set":1,"id":"1a95cdbc_f0546122","line":76,"in_reply_to":"1a95cdbc_280d8790","updated":"2016-10-05 19:38:50.000000000","message":"What about simply adding a validate_array($provider_mappings)?  That would give the user an error if they sent in a string, or any other incorrect type","commit_id":"00046793bc1a06e1ec02277f422296368a88e8f9"},{"author":{"_account_id":17280,"name":"Tim Rozet","email":"trozet@redhat.com","username":"trozet"},"change_message_id":"b32395455c8e26650f7ff9ce4c02defb8aa77639","unresolved":false,"context_lines":[{"line_number":73,"context_line":"  }"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"  # set mappings for VLAN or Flat provider networks"},{"line_number":76,"context_line":"  if ($provider_mappings !\u003d []) {"},{"line_number":77,"context_line":"    $pr_map_str \u003d join($provider_mappings, \u0027,\u0027)"},{"line_number":78,"context_line":"    exec { \u0027Set provider_mappings Other Option\u0027:"},{"line_number":79,"context_line":"      command \u003d\u003e \"ovs-vsctl set Open_vSwitch $(ovs-vsctl get Open_vSwitch . _uuid) other_config:provider_mappings\u003d${pr_map_str}\","}],"source_content_type":"text/x-puppet","patch_set":1,"id":"1a95cdbc_280d8790","line":76,"in_reply_to":"1a95cdbc_8d914d55","updated":"2016-10-05 17:37:05.000000000","message":"I think the change is not only just for TripleO.  Since we are passing in a list of key value pairs to this variable, I think it makes sense to be an array.  As for accepting multiple types, I\u0027ll leave that one to the master of puppet, Emilien :)","commit_id":"00046793bc1a06e1ec02277f422296368a88e8f9"},{"author":{"_account_id":7745,"name":"Denis Egorenko","email":"degorenko@mirantis.com","username":"degorenko"},"change_message_id":"2b846ac0c5383508fb59d26ffaac6bf3bec0a868","unresolved":false,"context_lines":[{"line_number":73,"context_line":"  }"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"  # set mappings for VLAN or Flat provider networks"},{"line_number":76,"context_line":"  if ($provider_mappings !\u003d []) {"},{"line_number":77,"context_line":"    $pr_map_str \u003d join($provider_mappings, \u0027,\u0027)"},{"line_number":78,"context_line":"    exec { \u0027Set provider_mappings Other Option\u0027:"},{"line_number":79,"context_line":"      command \u003d\u003e \"ovs-vsctl set Open_vSwitch $(ovs-vsctl get Open_vSwitch . _uuid) other_config:provider_mappings\u003d${pr_map_str}\","}],"source_content_type":"text/x-puppet","patch_set":2,"id":"1a95cdbc_2010244e","line":76,"range":{"start_line":76,"start_character":6,"end_line":76,"end_character":30},"updated":"2016-10-06 10:21:11.000000000","message":"please use empty function from stdlib","commit_id":"07ac81f12e028efc02f78d1bf5dbc099fa30dc68"},{"author":{"_account_id":17280,"name":"Tim Rozet","email":"trozet@redhat.com","username":"trozet"},"change_message_id":"8848d10cda4f469176b91da1fd61e7d8498407b6","unresolved":false,"context_lines":[{"line_number":73,"context_line":"  }"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"  # set mappings for VLAN or Flat provider networks"},{"line_number":76,"context_line":"  if ($provider_mappings !\u003d []) {"},{"line_number":77,"context_line":"    $pr_map_str \u003d join($provider_mappings, \u0027,\u0027)"},{"line_number":78,"context_line":"    exec { \u0027Set provider_mappings Other Option\u0027:"},{"line_number":79,"context_line":"      command \u003d\u003e \"ovs-vsctl set Open_vSwitch $(ovs-vsctl get Open_vSwitch . _uuid) other_config:provider_mappings\u003d${pr_map_str}\","}],"source_content_type":"text/x-puppet","patch_set":2,"id":"1a95cdbc_94f2116e","line":76,"range":{"start_line":76,"start_character":6,"end_line":76,"end_character":30},"in_reply_to":"1a95cdbc_2010244e","updated":"2016-10-06 13:20:30.000000000","message":"OK.  I will also add validate_array.","commit_id":"07ac81f12e028efc02f78d1bf5dbc099fa30dc68"},{"author":{"_account_id":14985,"name":"Alex Schultz","email":"aschultz@next-development.com","username":"mwhahaha"},"change_message_id":"81ed61bc8159518ac13f2fa6b3dfc44f1ee89fad","unresolved":false,"context_lines":[{"line_number":75,"context_line":"  # set mappings for VLAN or Flat provider networks"},{"line_number":76,"context_line":"  validate_array($provider_mappings)"},{"line_number":77,"context_line":"  if ! empty($provider_mappings) {"},{"line_number":78,"context_line":"    $pr_map_str \u003d join($provider_mappings, \u0027,\u0027)"},{"line_number":79,"context_line":"    exec { \u0027Set provider_mappings Other Option\u0027:"},{"line_number":80,"context_line":"      command \u003d\u003e \"ovs-vsctl set Open_vSwitch $(ovs-vsctl get Open_vSwitch . _uuid) other_config:provider_mappings\u003d${pr_map_str}\","},{"line_number":81,"context_line":"      unless  \u003d\u003e \"ovs-vsctl list Open_vSwitch | grep \u0027provider_mappings\u0027 | grep ${pr_map_str}\","}],"source_content_type":"text/x-puppet","patch_set":4,"id":"fa6399be_54f54481","line":78,"updated":"2016-10-10 22:07:28.000000000","message":"you can just use join(any2array($provider_mappings), \u0027,\u0027) and still support strings. That\u0027s probably prefered over just droping support for it.","commit_id":"ea0d4ba22a5ff191596a3cd84428dbc0488f4f5c"},{"author":{"_account_id":17280,"name":"Tim Rozet","email":"trozet@redhat.com","username":"trozet"},"change_message_id":"3285fc274faabfe2c1ed794e770453c6a7012dd1","unresolved":false,"context_lines":[{"line_number":75,"context_line":"  # set mappings for VLAN or Flat provider networks"},{"line_number":76,"context_line":"  validate_array($provider_mappings)"},{"line_number":77,"context_line":"  if ! empty($provider_mappings) {"},{"line_number":78,"context_line":"    $pr_map_str \u003d join($provider_mappings, \u0027,\u0027)"},{"line_number":79,"context_line":"    exec { \u0027Set provider_mappings Other Option\u0027:"},{"line_number":80,"context_line":"      command \u003d\u003e \"ovs-vsctl set Open_vSwitch $(ovs-vsctl get Open_vSwitch . _uuid) other_config:provider_mappings\u003d${pr_map_str}\","},{"line_number":81,"context_line":"      unless  \u003d\u003e \"ovs-vsctl list Open_vSwitch | grep \u0027provider_mappings\u0027 | grep ${pr_map_str}\","}],"source_content_type":"text/x-puppet","patch_set":4,"id":"fa6399be_e7d67ec4","line":78,"in_reply_to":"fa6399be_54f54481","updated":"2016-10-11 18:08:12.000000000","message":"Done","commit_id":"ea0d4ba22a5ff191596a3cd84428dbc0488f4f5c"},{"author":{"_account_id":14985,"name":"Alex Schultz","email":"aschultz@next-development.com","username":"mwhahaha"},"change_message_id":"be37b4aa9b39d97ebd572b24a890d57a9f1b2fb5","unresolved":false,"context_lines":[{"line_number":73,"context_line":"  }"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"  # set mappings for VLAN or Flat provider networks"},{"line_number":76,"context_line":"  if ! empty($provider_mappings) {"},{"line_number":77,"context_line":"    $pr_map_str \u003d join(any2array($provider_mappings), \u0027,\u0027)"},{"line_number":78,"context_line":"    exec { \u0027Set provider_mappings Other Option\u0027:"},{"line_number":79,"context_line":"      command \u003d\u003e \"ovs-vsctl set Open_vSwitch $(ovs-vsctl get Open_vSwitch . _uuid) other_config:provider_mappings\u003d${pr_map_str}\","}],"source_content_type":"text/x-puppet","patch_set":5,"id":"fa6399be_9ea0abf6","line":76,"range":{"start_line":76,"start_character":5,"end_line":76,"end_character":32},"updated":"2016-10-11 19:55:47.000000000","message":"So one of those minor backwards compatibility things, $provider_mappings \u003d false will cause this to error because empty only works with array, hashes, strings and integers.  You can get around this by doing if $providing_mappings and !empty($provider_mappings) { ... } which would still support if someone had set provider_mappings to false in their catalog.","commit_id":"d256c2ee5186daea3a0c0698d37644e539591570"},{"author":{"_account_id":17280,"name":"Tim Rozet","email":"trozet@redhat.com","username":"trozet"},"change_message_id":"4ffdd764f5005839e79cd9c618518b14a8e7fdbe","unresolved":false,"context_lines":[{"line_number":73,"context_line":"  }"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"  # set mappings for VLAN or Flat provider networks"},{"line_number":76,"context_line":"  if ! empty($provider_mappings) {"},{"line_number":77,"context_line":"    $pr_map_str \u003d join(any2array($provider_mappings), \u0027,\u0027)"},{"line_number":78,"context_line":"    exec { \u0027Set provider_mappings Other Option\u0027:"},{"line_number":79,"context_line":"      command \u003d\u003e \"ovs-vsctl set Open_vSwitch $(ovs-vsctl get Open_vSwitch . _uuid) other_config:provider_mappings\u003d${pr_map_str}\","}],"source_content_type":"text/x-puppet","patch_set":5,"id":"fa6399be_5e8e1379","line":76,"range":{"start_line":76,"start_character":5,"end_line":76,"end_character":32},"in_reply_to":"fa6399be_9ea0abf6","updated":"2016-10-11 19:57:23.000000000","message":"Done","commit_id":"d256c2ee5186daea3a0c0698d37644e539591570"}],"releasenotes/notes/odl_modify_provider_mappings-e1dfed970a78112b.yaml":[{"author":{"_account_id":6681,"name":"Brent Eagles","email":"beagles@redhat.com","username":"beagles"},"change_message_id":"8cf705ce14ee6cf694d21b4438658960d9b9ad9f","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"deprecations:"},{"line_number":3,"context_line":"  - Configuring OpenDaylight OVS provider_mappings as a string argument."},{"line_number":4,"context_line":"fixes:"},{"line_number":5,"context_line":"  - Opendaylight OVS provider_mappings argument is now an array type."}],"source_content_type":"text/x-yaml","patch_set":4,"id":"1a95cdbc_c474a637","line":2,"updated":"2016-10-07 17:53:09.000000000","message":"Needs confirmation from puppet cores, but I think this is more of an upgrade note.","commit_id":"ea0d4ba22a5ff191596a3cd84428dbc0488f4f5c"},{"author":{"_account_id":17280,"name":"Tim Rozet","email":"trozet@redhat.com","username":"trozet"},"change_message_id":"3285fc274faabfe2c1ed794e770453c6a7012dd1","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"deprecations:"},{"line_number":3,"context_line":"  - Configuring OpenDaylight OVS provider_mappings as a string argument."},{"line_number":4,"context_line":"fixes:"},{"line_number":5,"context_line":"  - Opendaylight OVS provider_mappings argument is now an array type."}],"source_content_type":"text/x-yaml","patch_set":4,"id":"fa6399be_27d956f4","line":2,"in_reply_to":"1a95cdbc_c474a637","updated":"2016-10-11 18:08:12.000000000","message":"Done","commit_id":"ea0d4ba22a5ff191596a3cd84428dbc0488f4f5c"}]}
