Project

General

Profile

Mon - Prioritize messages » History » Version 1

Jessica Mack, 06/23/2015 09:22 PM

1 1 Jessica Mack
h1. Mon - Prioritize messages
2 1 Jessica Mack
3 1 Jessica Mack
h3. Summary
4 1 Jessica Mack
5 1 Jessica Mack
Some messages are more important to finish quickly than others. Some other messages take less time than others. Lots of client messages, in a big enough cluster, can and will hinder progress of another messages (some of them even critical) simply due to the amount of messages to be handled.
6 1 Jessica Mack
The monitors should thus prioritize their own, mission-critical messages over any other conceivable message. The rationale should be simple: if the client waits a small fraction of a second longer, it should be okay; if the monitor waits to handle a thousand fractions of second to handle a critical message (such as a paxos lease extension), it may trigger a timeout and cause unnecessary havoc.
7 1 Jessica Mack
8 1 Jessica Mack
h3. Owners
9 1 Jessica Mack
10 1 Jessica Mack
* Joao Eduardo Luis (Inktank)
11 1 Jessica Mack
* Name (Affiliation)
12 1 Jessica Mack
* Name
13 1 Jessica Mack
14 1 Jessica Mack
h3. Interested Parties
15 1 Jessica Mack
16 1 Jessica Mack
* Name (Affiliation)
17 1 Jessica Mack
* Name (Affiliation)
18 1 Jessica Mack
* Name
19 1 Jessica Mack
20 1 Jessica Mack
h3. Current Status
21 1 Jessica Mack
22 1 Jessica Mack
There's no support for this on the monitor. From a quick look on ceph's tree, it looks like the messenger and DispatchQueue already understand Message priority, and one can use Message::set_priority() to define a message's priority.
23 1 Jessica Mack
This blueprint can be addressed on its own, but it would be preferable if it were addressed after addressing another submitted blueprint for Giant: [[mon - Independently dispatch non-conflicting messages|mon: Independently dispatch non-conflicting messages]]
24 1 Jessica Mack
25 1 Jessica Mack
h3. Detailed Description
26 1 Jessica Mack
27 1 Jessica Mack
Once defined which messages should have higher priority when handled by the monitor, this task should be a matter of sending messages from the monitors to another monitors setting a higher priority on some of the messages.
28 1 Jessica Mack
 
29 1 Jessica Mack
For instance, with regard to message priority:
30 1 Jessica Mack
 
31 1 Jessica Mack
MMonPaxos >  MMonElection > MMonGetMap > MMonProbe > MMonQuorumService > PaxosServiceMessage > MMonSync
32 1 Jessica Mack
33 1 Jessica Mack
h3. Work items
34 1 Jessica Mack
35 1 Jessica Mack
h4. Coding tasks
36 1 Jessica Mack
37 1 Jessica Mack
# Assess priorities
38 1 Jessica Mack
# Add monitor interface to appropriately send messages with an appropriate priority (instead of having to do it manually for each single message)
39 1 Jessica Mack
# Unit-tests
40 1 Jessica Mack
** parse through logs (yuck!)
41 1 Jessica Mack
** add a workunit that sends a bunch of messages with different priorities and expects replies in a priority-based order (this needs some thought!)
42 1 Jessica Mack
43 1 Jessica Mack
h4. Documentation tasks
44 1 Jessica Mack
45 1 Jessica Mack
# doc: document message priorities