Ian Davis
a288333e6f
fix(server/server.go): /v2/stats endpoints emit application/json content type header
2014-06-30 10:50:43 +01:00
Yicheng Qin
934c28d498
fix(peer_server): set store and registry when setting raft server
...
New raft server needs new store and registry.
2014-05-20 13:12:12 -07:00
Yicheng Qin
17e299995c
refactor(peer_server): remove standby mode in peer server
2014-05-07 09:10:09 -07:00
Yicheng Qin
c7116a37c0
fix(server): dispatch SetClusterConfigCommand correctly
2014-04-22 14:02:54 -07:00
Yicheng Qin
9f228550a2
Merge pull request #730 from unihorn/65
...
chore(server): deprecate mod temporarily
2014-04-18 10:46:09 -07:00
Yicheng Qin
67600603c5
chore: rename proxy mode to standby mode
...
It makes the name more reasonable.
2014-04-17 08:04:42 -07:00
Yicheng Qin
a1a91ab75a
chore(server): deprecate mod temporarily
2014-04-15 12:50:36 -07:00
Yicheng Qin
76ac1da7ea
feat(server): add HEAD for v1/watch
2014-04-08 17:37:05 -07:00
Yicheng Qin
89d3df242c
chore(server): handle HEAD for key space efficiently
...
Implement HEAD in server/v1 and server/v2 functions to avoid
time wasting on JSON marhsal.
2014-04-07 18:55:07 -07:00
Yicheng Qin
28f19dec60
feat(server): make header-only requests work
2014-04-07 13:51:33 -07:00
Ben Johnson
174b9ff343
bump(github.com/goraft/raft): 6bf34b9
...
Move from coreos/raft to goraft/raft and update to latest.
2014-03-24 15:09:47 -07:00
Ben Johnson
7d4fda550d
Machine join/remove v2 API.
2014-03-18 16:25:21 -06:00
Ben Johnson
c8d6b26dfd
Add auto-demotion after peer inactivity.
2014-03-03 11:15:05 -07:00
Ben Johnson
1d961b8e56
Add proxy mode.
2014-02-22 15:02:20 -07:00
Yicheng Qin
3a4df1612c
feat(discovery): adjust boot order to find peers
...
The boot order for peers is -discovery, -peers, log data, forming
new cluster itself.
Special rules:
1. If discovery succeeds, it would find peers specified by discover URL
only.
2. Etcd would fail when meeting bad -discovery, no -peers and log data.
Add TestDiscoveryDownNoBackupPeersWithDataDir as the test.
2014-02-17 12:53:39 -08:00
Yicheng Qin
bd56b15b6e
fix(tests/discovery): use host as -peers parameter instead of url
...
Or it cannot test the functionality correctly.
Moreover, add TestDiscoveryNoWithBackupPeers as the test for it.
2014-02-14 18:23:41 -08:00
Brian Waldon
42363001b4
fix(v2): Use case-insensitive check on bool query params
...
Fix issue #261
2014-02-07 14:29:08 -08:00
Brandon Philips
69922340f6
refactor(server): move utilities into pkg
...
like camlistore lets move these utilities into a `pkg` prefix.
2014-02-05 09:27:39 -08:00
Brandon Philips
13b6c1e684
chore(*): make everything use goven
...
for i in github.com/BurntSushi/toml github.com/coreos/go-etcd/etcd github.com/coreos/go-log/log github.com/gorilla/context github.com/rcrowley/go-metrics bitbucket.org/kardianos/osext github.com/coreos/go-systemd/journal github.com/coreos/raft code.google.com/p/goprotobuf/proto ; do goven -copy -rewrite $i; done
2014-02-01 23:44:18 -08:00
Brandon Philips
ea8a353545
chore(*): gofmt everything
2014-02-01 23:44:10 -08:00
Brian Waldon
2fe22f1890
refactor(servers): emit http.Handlers from *Server
2014-01-22 11:17:58 -08:00
Brian Waldon
a7d9efa900
refactor(server): Remove ServerConfig struct
2014-01-22 11:17:58 -08:00
Brian Waldon
0abd860f7e
refactor(server): drop Serve code; rename cors object
...
* server/cors.go renamed to http/cors.go
* all CORS code removed from Server and PeerServer
* Server and PeerServer fulfill http.Handler, now passed to http.Serve
* non-HTTP code in PeerServer.Serve moved to PeerServer.Start
2014-01-22 11:17:57 -08:00
Brian Waldon
5c3a3db2d8
refactor(server): treat Server as an http.Handler
2014-01-22 11:17:57 -08:00
Brian Waldon
d0c4916fe9
refactor(server): move listener init out of server.go
2014-01-22 11:17:26 -08:00
Brian Waldon
91fc6aabd2
chore(gofmt): Run gofmt
2014-01-22 11:17:26 -08:00
Brian Waldon
c0ff8f6026
chore(imports): Shift around some imports
2014-01-22 11:17:26 -08:00
Brian Waldon
a93d60be90
refactor(cors): Break apart CORS data and middleware
2014-01-22 11:17:26 -08:00
Brian Waldon
c47760382e
refactor(Server): Use a config struct in Server
2014-01-22 11:17:25 -08:00
Brian Waldon
7eaad5c8e0
feat(metrics): enable some metrics; push to graphite
...
* -trace flag controls whether or not to enable metrics-gathering
and the /debug/* HTTP endpoints
* -graphite-host flag controls where metrics should be sent
* timer.ae.handle metric tracks execution time of AppendEntriesRequest
2014-01-20 15:39:36 -08:00
Brandon Philips
c2077ed0b6
feat(server): add net/http/pprof endpoints
...
Add some basic profiling endpoints over http to start digging into
memory and request latencies.
2014-01-15 15:03:29 -08:00
Xiang Li
36dda352d9
fix(dispatch) should call e.Index()
2013-12-12 09:56:28 -08:00
Xiang Li
a5bca025b1
fix index inconsistence in v1 api
2013-12-11 11:12:39 -08:00
Xiang Li
40d297be66
feat add dir_flag
2013-12-05 17:10:37 -05:00
Ben Johnson
5d865e321c
Merge branch 'master' of https://github.com/coreos/etcd into mod-lock
...
Conflicts:
server/v2/tests/delete_handler_test.go
server/v2/tests/get_handler_test.go
server/v2/tests/post_handler_test.go
server/v2/tests/put_handler_test.go
third_party/github.com/coreos/go-etcd/etcd/requests.go
2013-12-04 22:36:53 -07:00
Brandon Philips
72bf216cb4
fix(server/v2): redirect to ClientURL not PeerURL
...
If consistent is set you must redirect the client to the leader's
ClientURL not the PeerURL.
2013-12-02 18:20:11 -08:00
Ben Johnson
df20be775c
Fix test harness.
2013-12-02 15:43:37 -07:00
Ben Johnson
22c2935ddb
Initial mod_lock acquire.
2013-11-27 16:59:05 -07:00
Xiang Li
b4f3d02c1c
Merge pull request #322 from xiangli-cmu/master
...
bump deps
2013-11-22 14:18:17 -08:00
Xiang Li
8a0496cfae
bump deps
2013-11-22 08:59:24 -08:00
Brandon Philips
a1ec895b91
feat(server): introduce a cors handler
...
Introduce a handler that lives under the gorilla mux and adds the
correct headers based on the request and always returns 200 OK when
there OPTIONS is called on a URL.
This fixes the ability to DELETE from the dashboard on peer X when peer
Y is the leader. As a side effect it reveals some bugs in the dashboard
though notably:
- Due to the RTT immediatly refreshing the dashboard doesn't work and
deleted keys are still there
- For some reason PUTS from peer X are creating directories and not
keys.
2013-11-21 09:25:21 -08:00
Ben Johnson
15eee885d7
Merge branch 'master' of https://github.com/coreos/etcd into clean-up-config
2013-11-19 10:13:39 -07:00
Xiang Li
1d34c82643
fix set content-type to application/json
2013-11-16 20:48:44 -08:00
Ben Johnson
cba2611c68
Renamed configuration parameters.
2013-11-15 00:13:32 -05:00
Brandon Philips
ca7e61052d
refactor(mod): remove the /etcd/ prefix
...
Originally we were going to move all of the API endpoints to /etcd/ so
that you could move etcd traffic over a multiplexed HTTP proxy with
other service but since we don't have a strong use case for this just
remove this for now.
2013-11-13 06:15:35 -08:00
Xiang Li
5abbaf59e3
Merge pull request #292 from xiangli-cmu/fix-ttl
...
WIP: fix ttl
2013-11-11 21:30:32 -08:00
Xiang Li
d8e5994c35
feat attach etcd-index,raft-index,raft-term to header
2013-11-09 20:20:47 -08:00
Xiang Li
6156d5c790
refactor separate etcd index from raft index
2013-11-09 17:55:54 -08:00
Brandon Philips
5620f88635
feat(server): insert the mod path
2013-11-08 16:59:30 -08:00
Xiang Li
f3ce75f2b4
feat add a simple speed test
2013-11-02 22:05:44 -07:00