@@ -66,16 +66,17 @@ type QueueSet interface {
66
66
IsIdle () bool
67
67
68
68
// StartRequest begins the process of handling a request. If the
69
- // request gets queued and the number of queues is greater than
70
- // 1 then Wait uses the given hashValue as the source of entropy
71
- // as it shuffle-shards the request into a queue. The descr1 and
72
- // descr2 values play no role in the logic but appear in log
73
- // messages. This method always returns quickly (without waiting
74
- // for the request to be dequeued). If this method returns a nil
75
- // Request value then caller should reject the request and the
76
- // returned bool indicates whether the QueueSet was idle at the
77
- // moment of the return. Otherwise idle==false and the client
78
- // must call the Wait method of the Request exactly once.
69
+ // request gets queued and the number of queues is greater than 1
70
+ // then StartRequest uses the given hashValue as the source of
71
+ // entropy as it shuffle-shards the request into a queue. The
72
+ // descr1 and descr2 values play no role in the logic but appear
73
+ // in log messages. This method always returns quickly (without
74
+ // waiting for the request to be dequeued). If this method
75
+ // returns a nil Request value then caller should reject the
76
+ // request and the returned bool indicates whether the QueueSet
77
+ // was idle at the moment of the return. Otherwise idle==false
78
+ // and the client must call the Finish method of the Request
79
+ // exactly once.
79
80
StartRequest (ctx context.Context , hashValue uint64 , fsName string , descr1 , descr2 interface {}) (req Request , idle bool )
80
81
}
81
82
@@ -116,10 +117,3 @@ type DispatchingConfig struct {
116
117
// ConcurrencyLimit is the maximum number of requests of this QueueSet that may be executing at a time
117
118
ConcurrencyLimit int
118
119
}
119
-
120
- // EmptyHandler is used to notify the callee when all the queues
121
- // of a QueueSet have been drained.
122
- type EmptyHandler interface {
123
- // HandleEmpty is called to deliver the notification
124
- HandleEmpty ()
125
- }
0 commit comments