osd
- pg split should be a work queue
-- pg split needs to fix up pg stats. this is tricky with the clone overlap business...
- generalize ack semantics? or just change ack from memory to journal? memory/journal/disk...
- rdlocks
- optimize remove wrt recovery pushes
// split
split_pg(parent, children, t);
+ parent->update_stats();
+ parent->write_info(t);
+
// unlock parent, children
parent->unlock();
for (map<pg_t,PG*>::iterator q = children.begin(); q != children.end(); q++) {
}
t.collection_add(pgid.to_coll(), parentid.to_coll(), poid);
t.collection_remove(parentid.to_coll(), poid);
+
+ // add to child stats
+ child->info.stats.num_bytes += st.st_size;
+ child->info.stats.num_kb += SHIFT_ROUND_UP(st.st_size, 10);
+ child->info.stats.num_objects++;
+ if (poid.snap && poid.snap != CEPH_NOSNAP)
+ child->info.stats.num_object_clones++;
} else {
dout(20) << " leaving " << poid << " in " << parentid << dendl;
}
}
+
+ // sub off child stats
+ for (map<pg_t,PG*>::iterator p = children.begin();
+ p != children.end();
+ p++) {
+ parent->info.stats.sub(p->second->info.stats);
+ }
}