rgw: change json formatting for swift list container

Fixes: #4048
There is some difference in the way swift formats the
xml output and the json output for list container. In
xml the entity is named 'name' and in json it is named
'subdir'.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
rgw: plain format always appends eol to data

Beforehand we just prepended the eol to the next line, so that
the last line also gets eol.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
osd: do not spam system log on successful read_log

Signed-off-by: Sage Weil <sage@inktank.com>
(cherry picked from commit 1948a02bc888fadafc29cf2e6f0a92129c68fd4c)
qa: fix iogen script

Wait 10 minutes and then stop.

Signed-off-by: Sage Weil <sage@inktank.com>
(cherry picked from commit 75c40fac603a3d21407d326e9faa8883166ad035)
qa/rbd: +x on map-snapshot-io.sh

Signed-off-by: Sage Weil <sage@inktank.com>
Revert "rgw: plain format always appends eol to data"

This commit breaks the swift unit test. The reason is that it
makes it so that returned error status ends with eol, which
is not as expected.

This reverts commit c31aff5f9f0b9fe4ada6b259dd1f424627b3e875.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
osd: improve debug output on snap collections

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Samuel Just <sam.just@inktank.com>
osd: unconditionally encode snaps buffer

Previously we would only encode the updated snaps vector for CLONE ops.
This doesn't work for MODIFY ops generated by the snap trimmer, which
may also adjust the clone collections.  It is also possible that other
operations may need to populate this field in the future (e.g.,
LOST_REVERT may, although it currently does not).

Fixes: #4071, and possibly #4051.

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Samuel Just <sam.just@inktank.com>
osd: include snaps in pg_log_entry_t::dump()

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Samuel Just <sam.just@inktank.com>
osd: update snap collections for sub_op_modify log records conditionaly

The only remaining caller is sub_op_modify().  If we do have a non-empty
op transaction, we want to do this update, regardless of what we think
last_backfill is (our notion may be not completely in sync with the
primary).  In particular, our last_backfill may be the same object but
a different snapid, but the primary disagrees and is pushing an op
transaction through.

Instead, update the collections if we have a non-empty transaction.

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Samuel Just <sam.just@inktank.com>
Merge remote-tracking branch 'gh/next'