virtual ~effect_t() = default;
};
+ Ref<PG> pg; // for the sake of object class
ObjectContextRef obc;
const OpInfo& op_info;
const pg_pool_t& pool_info; // for the sake of the ObjClass API
public:
template <class MsgT>
- OpsExecuter(ObjectContextRef obc,
+ OpsExecuter(Ref<PG> pg,
+ ObjectContextRef obc,
const OpInfo& op_info,
const pg_pool_t& pool_info,
PGBackend& backend,
const MsgT& msg)
- : obc(std::move(obc)),
+ : pg(std::move(pg)),
+ obc(std::move(obc)),
op_info(op_info),
pool_info(pool_info),
backend(backend),
using rep_op_fut_t =
interruptible_future<rep_op_fut_tuple>;
template <typename MutFunc>
- rep_op_fut_t flush_changes_n_do_ops_effects(
- Ref<PG> pg,
- MutFunc&& mut_func) &&;
+ rep_op_fut_t flush_changes_n_do_ops_effects(MutFunc&& mut_func) &&;
const hobject_t &get_target() const {
return obc->obs.oi.soid;
template <typename MutFunc>
OpsExecuter::rep_op_fut_t
-OpsExecuter::flush_changes_n_do_ops_effects(Ref<PG> pg, MutFunc&& mut_func) &&
+OpsExecuter::flush_changes_n_do_ops_effects(MutFunc&& mut_func) &&
{
const bool want_mutate = !txn.empty();
// osd_op_params are instantiated by every wr-like operation.
ox->get_target());
peering_state.apply_op_stats(ox->get_target(), ox->get_stats());
return std::move(*ox).flush_changes_n_do_ops_effects(
- Ref<PG>{this},
[this, &op_info, &ops] (auto&& txn,
auto&& obc,
auto&& osd_op_p,
}
return do_osd_ops_execute<MURef<MOSDOpReply>>(
seastar::make_lw_shared<OpsExecuter>(
- std::move(obc), op_info, get_pool().info, get_backend(), *m),
+ Ref<PG>{this}, std::move(obc), op_info, *m),
m->ops,
op_info,
[this, m, rvec = op_info.allows_returnvec()] {
{
return do_osd_ops_execute<void>(
seastar::make_lw_shared<OpsExecuter>(
- std::move(obc), op_info, get_pool().info, get_backend(), msg_params),
+ Ref<PG>{this}, std::move(obc), op_info, msg_params),
ops,
std::as_const(op_info),
std::move(success_func),