Yan Xu created MESOS-1723:
-----------------------------

             Summary: Replace "BoundedRateLimiter" with EventThrottler 
libprocess Process
                 Key: MESOS-1723
                 URL: https://issues.apache.org/jira/browse/MESOS-1723
             Project: Mesos
          Issue Type: Improvement
    Affects Versions: 0.20.0
            Reporter: Yan Xu
            Priority: Minor


To help enforce per-principal capacity for framework limiting, Master 
implements a nested struct 
[BoundedRateLimiter|https://github.com/apache/mesos/blob/0.20.0-rc2/src/master/master.hpp#L772]
 that keeps track of the capacity for the principal and the current number of 
outstanding messages. Master implements all the accounting logic 
([e.g.|https://github.com/apache/mesos/blob/0.20.0-rc2/src/master/master.cpp#L879])
 and makes sure the struct is used correctly.

The capacity enforcing logic will be cleaner and better encapsulated by if we 
replace BoundedRateLimiter with an EventThrottler libprocess Process and move 
all the aforementioned logic inside.

Note that the reason for not implementing the capacity inside 
[RateLimiter|https://github.com/apache/mesos/blob/0.20.0-rc2/3rdparty/libprocess/include/process/limiter.hpp]
 is that it is not aware of who's calling it and we have different rules for 
MessageEvents and ExitedEvents w.r.t capacity (i.e. ExitedEvents are not 
subject to capacity).



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to