Commit Graph

23 Commits

Author SHA1 Message Date
Daniel Smith
6460a8cbf8 Correct confusing comment. 2014-08-11 15:58:59 -07:00
Daniel Smith
7d605467dc New scheduler API
This commit adds a Binding object. The idea is that schedulers can write
these to cause pods to be asssigned to hosts. I'll provide an implementation
along with a rudimentary scheduler plugin.

This continues k8s' tradition of phrasing all APIs as RESTful handlers.
2014-08-10 19:05:03 -07:00
Clayton Coleman
67dbd15929 Address remaining comments from #756
Rename Encoding to Codec, Versioning to ResourceVersioner.  Add
GoDoc.  Add Delete(key, recursive) to EtcdHelper
2014-08-06 11:25:35 -04:00
Clayton Coleman
4448be2d95 Expose an Encoding/Versioning interface for use with etcd
etcd_tools.go is not dependent on the specific implementation
(which is provided by pkg/api).  All EtcdHelpers are created
with an encoding object which handles Encode/Decode/DecodeInto.
Additional tests added to verify simple atomic flows.

Begins to break up api singleton pattern.
2014-08-03 21:35:33 -04:00
Daniel Smith
1cc7fce523 Add documentation and tests to conversion. 2014-08-01 14:26:36 -07:00
Daniel Smith
5c0f5e85e2 Make api use converter package. 2014-08-01 14:26:35 -07:00
Daniel Smith
242c8cdaec Add custom conversion function system.
As an example, demonstrate how Env.Key's deprecation ought to work.
2014-07-30 14:18:23 -07:00
Daniel Smith
2396bdfa1b Incorporate new types into versioned api system.
* Made externalize/internalize generic to prevent boilerplate.
* Add fuzz testing.
* All objects pass fuzz tests now.
* This turned up some things we'll need to fix eventually. Left TODOs.
2014-07-29 15:46:57 -07:00
Daniel Smith
b3cc696486 All types stored in etcd are now API objects.
This means I made an api.ContainerManifestList, and added a JSONBase to
endpoints (and changed Name -> JSONBase.ID).
2014-07-28 11:27:36 -07:00
Dan McPherson
c4f4f69b93 Fixing Typos 2014-07-28 15:56:20 +02:00
Jeromy Carriere
9cad657b4c Fix internalize for ReplicationControllerList. items were created
in a new var hiding the function-scoped var.
2014-07-25 10:44:45 -04:00
Brendan Burns
bf5ae4bb9d Fork API types. 2014-07-24 21:47:08 -07:00
Daniel Smith
69c483f620 Add APIObject for generic inclusion of API objects.
Includes test and json/yaml getters and setters.
2014-07-18 22:35:08 -07:00
Yuki Yugui Sonoda
780c441d19 Fixes golint errors in pkg/api 2014-07-08 16:08:58 +09:00
Daniel Smith
3b9735d787 Test atomic PUTs, and make them work.
Improve apiserver/logger.go's interface (it's pretty cool now).

Improve apiserver's error reporting to clients.

Improve client's handling of errors from apiserver.

Make failed PUTs return 409 (conflict)-- http status codes are amazingly
well defined for what we're doing!
2014-07-02 15:42:05 -07:00
Daniel Smith
a6144f656c Move etcd helpers to tools package so they can depend on api package. Add ResourceVersion, hook it up to etcd index to get atomic PUTs. 2014-07-02 15:42:05 -07:00
Daniel Smith
afd13edd6a Address comments; also, demonstrate one more property in test. 2014-06-26 11:36:15 -07:00
Daniel Smith
c12a3773f5 Add minion types, address other comments 2014-06-23 13:27:52 -07:00
Daniel Smith
ee75bb8dbe Address comments; Also internally start using JSONBase instead of reflect.Value of JSONBase. 2014-06-23 09:54:17 -07:00
Daniel Smith
41534c1cc5 Encode/decode working everywhere now. 2014-06-23 09:54:17 -07:00
Daniel Smith
d7b4915111 Don't make people have to worry about the Kind field. 2014-06-23 09:54:17 -07:00
Daniel Smith
fb991fb84e Change type to []byte 2014-06-23 09:54:17 -07:00
Daniel Smith
a9d9bb9d47 Add intelligent type marshalling/unmarshalling 2014-06-23 09:54:17 -07:00