/- make sure predirty_nested stops if it can't wrlock versionlock (acquire_locks normally hides that detail for us)
- make sure stray inode is always opened on startup
/- make sure inode cache expire for frozen inode behaves
+- REQSCATTER/REQUNSCATTER ... can we avoid the auth pin requirement?
- look at the client_map session opening code.. versus rollback (of import, or slave request)
-- rollback vs accounting is just broken! can we avoid it.
- - even with _just_ parent dir mtime, the rollback metablob isn't sufficient during replay.. we need special handling regardless.
-
- anchor_destroy needs to xlock linklock.. which means it needs a Mutation wrapper?
- ... when it gets a caller.. someday..
- replay of dir fragmentation (dont want dir frozen, pins, etc.?)
-- rename slave in-memory rollback on failure
- proper handling of cache expire messages during rejoin phase?
-> i think cache expires are fine; the rejoin_ack handler just has to behave if rejoining items go missing
in->pop_and_dirty_projected_inode(mut->ls);
in->put(CInode::PIN_PTRWAITER);
- mut->pop_and_dirty_projected_inodes();
- mut->pop_and_dirty_projected_fnodes();
+ mut->apply();
drop_locks(mut);
+ mut->drop_local_auth_pins();
+
+ delete mut;
if (share && in->is_auth() && in->filelock.is_stable())
share_inode_max_size(in);
dout(10) << "scatter_nudge waiting for unfreeze on " << *p << dendl;
if (c)
p->add_waiter(MDSCacheObject::WAIT_UNFREEZE, c);
+ else
+ // just requeue. not ideal.. starvation prone..
+ updated_scatterlocks.push_back(&lock->xlistitem_updated);
return;
}
if (p->is_ambiguous_auth()) {
dout(10) << "scatter_nudge waiting for single auth on " << *p << dendl;
- p->add_waiter(MDSCacheObject::WAIT_SINGLEAUTH, c);
+ if (c)
+ p->add_waiter(MDSCacheObject::WAIT_SINGLEAUTH, c);
+ else
+ // just requeue. not ideal.. starvation prone..
+ updated_scatterlocks.push_back(&lock->xlistitem_updated);
return;
}
// updated
utime_t now = g_clock.now();
+ int n = updated_scatterlocks.size();
while (!updated_scatterlocks.empty()) {
ScatterLock *lock = updated_scatterlocks.front();
+
+ if (n-- == 0) break; // scatter_nudge() may requeue; avoid looping
if (!lock->is_updated()) {
updated_scatterlocks.pop_front();