Project

General

Profile

Actions

Feature #303

closed

objecter: limit in-flight ops and/or bytes written

Added by Sage Weil over 13 years ago. Updated over 13 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
-
Target version:
% Done:

0%

Source:
Tags:
Backport:
Reviewed:
Affected Versions:
Pull request ID:
Actions #1

Updated by Sage Weil over 13 years ago

  • Target version set to v0.22
Actions #2

Updated by Sage Weil over 13 years ago

This should be really easy to implement using the Throttle class in the io submission methods (need to do both sync and async).

Maybe request count and byte count? g_conf.objecter_max_requests, object_max_request_bytes ?

Actions #3

Updated by Greg Farnum over 13 years ago

  • Assignee set to Greg Farnum
Actions #4

Updated by Greg Farnum over 13 years ago

I'm not sure this is actually feasible via the current objecter interface. It doesn't do much locking on its own and the layer above it (ie, the Client) does a lot of locking around Objecter calls so the Objecter can't really block. Without being able to block it can't slow down the rate of data input -- it can slow down how quickly it sends data out over the wire, but then it's just building up memory pressure locally. :/

Actions #5

Updated by Greg Farnum over 13 years ago

After talking with Sage we're going to implement accounting in a non-blocking fashion in the Objecter, and then add a throttle function which Objecter's users can call prior to a read/write if they wish to and can assure that their locking will work out okay.
This throttle function will unlock Objecter::client_lock if it blocks on the throttle call and re-lock it before returning.

Actions #6

Updated by Greg Farnum over 13 years ago

  • Status changed from New to 4

This was actually pretty simple to do; I have it locally right now.
I added some Throttler changes to remove the potential sleeping in take and put.

Waiting to close to find out if I should do more with it.

Actions #7

Updated by Greg Farnum over 13 years ago

  • Status changed from 4 to In Progress

Going to add a switch so you can set the Objecter to throttle by default for you.

Actions #8

Updated by Greg Farnum over 13 years ago

  • Status changed from In Progress to 4

Added switch, reverted throttler changes, and implemented the switch in librados. Tested it briefly via rados tool, and it completed a benchmark write/read while limiting the write ops. It probably limited the read ops too but they're so fast it's hard to tell with the async calls being used.

Actions #10

Updated by Sage Weil over 13 years ago

  • Status changed from 4 to Resolved
Actions

Also available in: Atom PDF