rgw: objectlock: improve client error messages
A bucket object lock configuration can only be set on buckets
created with the object-lock option enabled. Likewise, on
object lock or object retention hold can only be set on objects
in buckets with object lock enabled. Object lock and related
policy and policy violations are also potentially confusing
to client users.
Raise the debug level to 4, but add a human-readable client error
message, when object lock constraints are violated.
Fixes: https://tracker.ceph.com/issues/49541
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
(cherry picked from commit
7583374e5294b1c1c16068999123fef98827e9dc)
Conflicts:
src/rgw/rgw_op.cc