22 Commits

Author SHA1 Message Date
Xiang Li
9143329c85 storage: implement requestProgress 2016-03-03 09:39:29 -08:00
Anthony Romano
c0eac7ab72 storage: support watch on ranges 2016-02-29 15:20:41 -08:00
Anthony Romano
c5b51946eb *: exported godoc fixups 2016-02-21 20:36:44 -08:00
Anthony Romano
ee1a03167d storage, v3: pass compaction revision through watchresponse 2016-02-12 14:06:59 -08:00
Xiang Li
52416fafb0 storage: send compaction 2016-02-02 23:17:27 -08:00
Anthony Romano
20461ab11a *: fix many typos 2016-01-31 21:42:39 -08:00
Gyu-Ho Lee
366e7a879f *: fill in WatchResponse.Header
Related to coreos#3848.
2016-01-06 15:12:53 -08:00
Anthony Romano
21a6ade53d storage: change type of WatchIDs from int64 to WatchID 2016-01-04 19:52:22 -08:00
Gyu-Ho Lee
556d4a6932 *: remove CancelFunc return for Watch. Use Cancel for watch. 2016-01-04 16:17:55 -08:00
Gyu-Ho Lee
6540f47dfa *: WatchResponse for multiple Events with WatchID
storage/storagepb: remove watchID from Event

storage: add WatchResponse to watcher.go to wrap events, watchID

storage: watchableStore to use WatchResponse

storage: kv_test with WatchResponse

etcdserver/api/v3rpc: watch to receive storage.WatchResponse type
2016-01-03 16:32:48 -08:00
Xiang Li
eda0eefc25 *: support watcher cancellation inside watchStream 2016-01-03 00:20:21 -08:00
Xiang Li
807db7e2aa storage: rename watching -> watcher 2016-01-02 20:20:22 -08:00
Xiang Li
ee0b3f42ed *: rename watcher to watchStream
Watcher vs Watching in storage pkg is confusing. Watcher should be named
as watchStream since it contains a channel as stream to send out events.
Then we can rename watching to watcher, which actually watches on a key
and send watched events through watchStream.

This commits renames watcher to watchStram.
2016-01-02 16:03:57 -08:00
Gyu-Ho Lee
5aded6cd77 storage: watcher.go events slice 2015-12-31 19:26:20 -08:00
Yicheng Qin
deb1da5f57 storage: add watch ID to identify watchings
One watcher includes multiple watchings, and their events are
sent out through one channel. For the received event, user would like to
know which watching it belongs to.

Introduce a watch ID. When watching on some key, user will get a watch
ID. The watch ID is attached to all events that is observed by this
watch.
2015-11-21 11:19:17 -08:00
Gyu-Ho Lee
6e5eb03544 storage: move watcherGauge to watchable_store
watcherGauge should be increased everytime we creates Watcher, not per watch
method call.
2015-11-04 13:17:47 -08:00
Gyu-Ho Lee
4ebf28aa2e storage: add metrics to watcher
This adds metrics to watcher, and changes some order in MustRegister function
calls in init (same order that we define the gauges).
2015-11-04 13:01:52 -08:00
Xiang Li
a1129dd5a5 storage: support multiple watching per watcher
We want to support multiple watchings per one watcher chan. Then
we can have one single go routine to watch multiple keys/prefixs.
2015-11-03 12:36:11 -08:00
Xiang Li
f71bcfa8ce storage: move watcher interface into watcher.go 2015-10-28 21:10:58 -07:00
Xiang Li
6556bf1643 storage: remove the endRev of watcher 2015-10-17 15:59:49 -07:00
Jonathan Boulle
7848ac3979 *: add missing license headers 2015-09-15 14:09:01 -07:00
Yicheng Qin
ec43e0a4c3 storage: introduce WatchableKV and watch feature
WatchableKV is an interface upon KV, and supports watch feature.
2015-09-14 23:53:03 -07:00