#include "rgw_auth_s3.h"
#include "rgw_user.h"
#include "rgw_bucket.h"
+#include "rgw_zone.h"
#include "rgw_file.h"
#include "rgw_lib_frontend.h"
#include "common/errno.h"
}
get<1>(mkr) = rc;
+
+ /* case like : quota exceed will be considered as fail too*/
+ if(rc2 < 0)
+ get<1>(mkr) = rc2;
return mkr;
} /* RGWLibFS::create */
struct req_state* s = get_state();
auto compression_type =
- get_store()->get_zone_params().get_compression_type(
+ get_store()->svc.zone->get_zone_params().get_compression_type(
s->bucket_info.placement_rule);
/* not obviously supportable */
return -EIO;
}
+ op_ret = get_store()->check_quota(s->bucket_owner.get_id(), s->bucket,
+ user_quota, bucket_quota, real_ofs, true);
+ /* max_size exceed */
+ if (op_ret < 0)
+ return -EIO;
+
size_t len = data.length();
if (! len)
return 0;
}
op_ret = get_store()->check_quota(s->bucket_owner.get_id(), s->bucket,
- user_quota, bucket_quota, s->obj_size);
+ user_quota, bucket_quota, s->obj_size, true);
+ /* max_size exceed */
if (op_ret < 0) {
goto done;
}