rgw: abstract RGWProcess

RGWProcess is a generic request handler that sends request to the
workqueue for processing.
Add RGWFCGXProcess specialization. Later we'll add a new frontend that
will leverage that.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
rgw: add some debug output

Dump request environment when starting processing request. We used to do
it before, but it was recently dropped as part of a cleanup.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
osd: Correction to #6690 change

Reorder sequence so min_size check is right
Remove redundant resize of backfill

Correction to 19cff890eb6083eefdb7b709773313b2c8acbcea

Signed-off-by: David Zafman <david.zafman@inktank.com>
osd: do not send peering messages during init

Do not send any peering messages while we are still working our way
through init().

Fixes: #7093
Signed-off-by: Sage Weil <sage@inktank.com>
osd: ignore OSDMap messages while we are initializing

The mon may occasionally send OSDMap messages to random OSDs, but is not
very descriminating in that we may not have authenticated yet.  Ignore any
messages if that is the case; we will reqeust whatever we need during the
BOOTING state.

Fixes: #7093
Signed-off-by: Sage Weil <sage@inktank.com>
mon: only send messages to current OSDs

When choosing a random OSD to send a message to, verify not only that
the OSD id is up but that the session is for the same instance of that OSD
by checking that the address matches.

Fixes: #7093
Backport: emperor, dumpling
Signed-off-by: Sage Weil <sage@inktank.com>
Merge pull request #1055 from kri5/master

mailmap: Adds Christophe Courtaut

    git shortlog -nes 

shows only one Christophe Courtaut proof that the .mailmap addition is working.

Reviewed-by: Loic Dachary <loic@dachary.org>
EC-JERASURE: rewrite region-xor function using vector operations to get ~ x1.5 speedups for erasure code and guarantee proper 64-bit/128-bit buffer alignment
erasure-code: ensure that coding chunks are page aligned

When coding chunks are allocated for jerasure, their address must be
aligned to page boundaries. The requirement is actually to be aligned on
a long long boundary but bufferlist do not allow for fine tuning of the
alignment.

If padding is necessary because the total size of the data to be encoded
is not a multiple of the alignment requirements as returned by
get_alignment(), the buffer is not only padded but also rebuilt using
rebuild_page_aligned() to preserve the page alignment that is expected
of the input buffer.

The overhead of rebuilding the whole input buffer when padding is
necessary could be reduced by only reallocating one buffer for the last
data chunk, therefore reducing the amount of data being copied. However,
this optimization is not going to be used if the caller takes care of
the padding, which is likely to be the case most of the time.

Signed-off-by: Loic Dachary <loic@dachary.org>
erasure-code: relax zero copy requirements in tests

The input buffer is copied when padding is required. Remove the tests
that ensured the input buffer was not copied entirely when padding was
added.

Signed-off-by: Loic Dachary <loic@dachary.org>
osd: Remove redundant incompat feature

We can remove this CompatSet bit without worry because the only
way it could have been set is if an erasure coded pool was create.
This isn't supported as of yet.

Signed-off-by: David Zafman <david.zafman@inktank.com>
doc: Fixed hyperlink.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
doc: Updated for hostname -s and resolving to non-loopback IP address.

fixes: #6234

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
osd: Config OSD when CEPH_FEATURE_OSD_ERASURE_CODES feature first seen

Set the OSD superblock CEPH_OSD_FEATURE_INCOMPAT_SHARDS and
notify the filestore through set_allow_sharded_objects() in that order.

Signed-off-by: David Zafman <david.zafman@inktank.com>
osd: Determine if compatibility is required due to back level OSDs

fixes: #7039

Signed-off-by: David Zafman <david.zafman@inktank.com>
osd: Fix problems in ReplicatedPG::do_op() logic

Fix assert(is_degraded_object(soid)) in ReplicatedPG::wait_for_degraded_object()
  Use last_backfill_started as the backfill line
  Handle uncommon case of multi op source after backfill line and target before
  backfill line and !is_degraded_object().
  Include backfill line itself for before_backfill (<= instead of <)

Signed-off-by: David Zafman <david.zafman@inktank.com>
osd: Return false for func that returns bool

Signed-off-by: David Zafman <david.zafman@inktank.com>
messages, os, osd: Clean-up g/hobject_t MAX handling

Add check of is_max() before updating an unset pool
Use efficient is_max() instead of compare with hobject::get_max()

Signed-off-by: David Zafman <david.zafman@inktank.com>
osd: Recovery reservations need to include backfill peers

Caused by 86e4fd4f7a9848511e1bf9ae433fcd3a35a0818f

Signed-off-by: David Zafman <david.zafman@inktank.com>
osd: Interim working version with backfill reserve state changes

Signed-off-by: David Zafman <david.zafman@inktank.com>