)]}'
{"container_config_scripts/pacemaker_resource_lock.sh":[{"author":{"_account_id":6926,"name":"Bogdan Dobrelya","email":"bdobreli@redhat.com","username":"bogdando"},"change_message_id":"9364a8f792b1096ff79ba1e65b1191684a4d21f2","unresolved":true,"context_lines":[{"line_number":33,"context_line":"    local expected_data\u003d$2"},{"line_number":34,"context_line":"    local new_data\u003d$3"},{"line_number":35,"context_line":"    # we only update the lock we expect to see, so we can\u0027t update someone else\u0027s lock"},{"line_number":36,"context_line":"    cibadmin --sync-call --scope crm_config --modify --xpath \"//cluster_property_set/nvpair[@name\u003d\u0027${name}\u0027 and @value\u003d\u0027${expected_data}\u0027]/..\" --xml-text \"\u003cnvpair id\u003d\u0027${name}-pair\u0027 name\u003d\u0027${name}\u0027 value\u003d\u0027${new_data}\u0027/\u003e\" \u0026\u003e/dev/null"},{"line_number":37,"context_line":"    return $?"},{"line_number":38,"context_line":"}"},{"line_number":39,"context_line":""}],"source_content_type":"text/x-sh","patch_set":1,"id":"d8ecd9a2_8ed15f92","line":36,"range":{"start_line":36,"start_character":44,"end_line":36,"end_character":52},"updated":"2020-11-27 14:01:10.000000000","message":"I wonder how much this shows better than building diff xmls off the shadow CIB copies and calling --patch against the live cib. With concurrent operations that showed off to be more resilient in the past. But I know not much about that --modify. I hope it works as well for that case!","commit_id":"88843893c6d3e6d8c2b062a80b38798373259a69"},{"author":{"_account_id":20778,"name":"Damien Ciabrini","email":"dciabrin@redhat.com","username":"dciabrin"},"change_message_id":"68d880c4b49a45103e846ceb3d90bc10969c28f0","unresolved":true,"context_lines":[{"line_number":33,"context_line":"    local expected_data\u003d$2"},{"line_number":34,"context_line":"    local new_data\u003d$3"},{"line_number":35,"context_line":"    # we only update the lock we expect to see, so we can\u0027t update someone else\u0027s lock"},{"line_number":36,"context_line":"    cibadmin --sync-call --scope crm_config --modify --xpath \"//cluster_property_set/nvpair[@name\u003d\u0027${name}\u0027 and @value\u003d\u0027${expected_data}\u0027]/..\" --xml-text \"\u003cnvpair id\u003d\u0027${name}-pair\u0027 name\u003d\u0027${name}\u0027 value\u003d\u0027${new_data}\u0027/\u003e\" \u0026\u003e/dev/null"},{"line_number":37,"context_line":"    return $?"},{"line_number":38,"context_line":"}"},{"line_number":39,"context_line":""}],"source_content_type":"text/x-sh","patch_set":1,"id":"70c0d2ec_5d5ccdf0","line":36,"range":{"start_line":36,"start_character":44,"end_line":36,"end_character":52},"in_reply_to":"d8ecd9a2_8ed15f92","updated":"2020-12-02 14:56:19.000000000","message":"the --modify provides the same semantics (replacing a specific pattern in the CIB with something else), as well as the same concurrency guarantee. I can do so because I\u0027m only changing a single parameter in the CIB, so I don\u0027t need to compile a crm_diff for that.\n\nGoing the shadow CIB route would just mean extra steps: 1) snapshot the CIB 2) update the snapshot CIB and extract a crm_diff out of it 3) pushing the diff in the live CIB 4) cleaning up the snapshot CIB.","commit_id":"88843893c6d3e6d8c2b062a80b38798373259a69"}]}
