Commit Graph

44 Commits (ead67108ce911a3b4a7e38274ca645603ec4772f)

Author SHA1 Message Date
Clayton Coleman 7932bda3b3 Endpoints controller can print sensitive pod info when errors occur
In general, start to tone down the amount of log output.
2015-01-22 15:23:41 -05:00
Clayton Coleman 16683b409f endpoints controller is too verbose
Logging at v(3) instead of v(0)
2015-01-07 17:19:49 -05:00
Clayton Coleman 2c27f7d332 Allow an empty service 2014-12-09 12:48:53 -05:00
Tim Hockin ea960711ff Clean up error logs.
Use %v for errors, tidy some messages, make error messages start lowe-case
(as per go guidelines).  Just accumulated nits.
2014-11-21 09:45:26 +08:00
markturansky 8af4ccb111 v1beta3 Pod refactor 2014-11-18 09:25:42 -05:00
Clayton Coleman 6d31c2bf8a util.EncodeJSON proven harmful, remove it everywhere
People were misusing EncodeJSON in tests when they should be using
runtime.EncodeOrDie(testapi.Codec(), obj).  Removing the potential
for cutting self on sharp objects.
2014-11-13 10:38:13 -05:00
Claire Li 5a7c00754f Fix findPort: correctly handle the empty ports case 2014-11-06 21:55:43 -08:00
Claire Li c5205870c0 Refactor test for findPort in service pkg 2014-11-06 21:55:43 -08:00
Claire Li ea0c6bcbfd Refactor findPort in service pkg 2014-11-06 21:55:43 -08:00
markturansky bd7643c033 refactor services to v1beta3 2014-11-04 14:23:53 -05:00
Daniel Smith 7146ec9d49 Implement kubernetes & kubernetes-ro services 2014-10-29 11:29:28 -07:00
bgrant0607 854af6b926 Merge pull request #1966 from ddysher/Stop-test-server
Stop test server in endpoint unittest.
2014-10-27 16:35:18 -07:00
derekwaynecarr 341e404290 Fix sync service endpoints typo 2014-10-24 11:47:30 -04:00
derekwaynecarr 580cb5ea4f Rework client.Interface 2014-10-24 11:47:30 -04:00
Clayton Coleman 644eb70085 Refactor tests to split ObjectMeta from TypeMeta 2014-10-24 11:22:21 -04:00
Clayton Coleman 7550c146dc Replace struct initializers for TypeMeta with ObjectMeta 2014-10-24 11:22:21 -04:00
Clayton Coleman bc748fadfa Whitespace and old comment removal 2014-10-24 11:22:21 -04:00
Deyuan Deng f14eebf6bf Stop test server in endpoint unittest. 2014-10-22 20:14:39 -04:00
Clayton Coleman bb77a5d15f Rename ID -> Name 2014-10-22 15:00:26 -04:00
Daniel Smith d34914517f Shorten 'CodecForVersionOrDie' name, add 'ResourceVersioner' to testapi 2014-10-13 14:58:06 -07:00
Clayton Coleman 82bcdd3b3b Make ResourceVersion a string internally instead of uint64
Allows us to define different watch versioning regimes in the future
as well as to encode information with the resource version.

This changes /watch/resources?resourceVersion=3 to start the watch at
4 instead of 3, which means clients can read a resource version and
then send it back to the server. Clients should no longer do math on
resource versions.
2014-10-07 19:00:26 -04:00
Clayton Coleman d3e51a0f24 Rename JSONBase -> TypeMeta in preparation for v1beta3
Will make subsequent refactor much easier
2014-10-07 11:12:16 -04:00
Daniel Smith cc086908aa Merge pull request #1578 from brendandburns/controller
Extract the service controller from the apiserver.
2014-10-06 12:44:41 -07:00
Brendan Burns e6991d0a66 Extract the service controller from the apiserver, put it in the controller manager for now. 2014-10-03 15:27:22 -07:00
Brendan Burns e6d823da71 Use formal error checking to validate a not found err. 2014-10-03 15:08:16 -07:00
Brendan Burns f00fd8d2e3 Add an integration test for services. 2014-10-02 21:07:06 -07:00
Tim Hockin 2bac0fb2c6 Actually fix services bug 2014-10-02 15:21:28 -07:00
Tim Hockin 446bcd468e Merge pull request #1551 from brendandburns/fix
Fix error detection.  (a better fix is coming)
2014-10-02 14:58:11 -07:00
Brendan Burns c260c7d0eb Fix error detection. (a better fix is coming) 2014-10-02 14:52:48 -07:00
derekwaynecarr fc67d822c6 Add context as parameter to client interface functions 2014-10-02 12:51:36 -04:00
Clayton Coleman ff2eca97d9 Refactor the client (again) to better support auth
* Allows consumers to provide their own transports for common cases.
* Supports KUBE_API_VERSION on test cases for controlling which
  api version they test against
* Provides a common flag registration method for CLIs that need
  to connect to an API server (to avoid duplicating flags)
* Ensures errors are properly returned by the server
* Add a Context field to client.Config
2014-10-01 15:23:37 -04:00
derekwaynecarr 02e1a2e79d Update unit tests to pass a context on client create 2014-09-30 14:27:56 -04:00
Brendan Burns 17c82606eb Second step in decoupling the service controller, use the apiserver for writes too. 2014-09-26 16:44:25 -07:00
derekwaynecarr 09365fed8d Add ctx to registry interfaces 2014-09-26 15:18:42 -04:00
Clayton Coleman 5483333e29 Allow server and client to take api version as argument
* Defaults to v1beta1
* apiserver takes -storage_version which controls etcd storage version
  and the version of the client used to connect to other apiservers
* Changed signature of client.New to add version parameter
* All controller code and component code prefers the oldest (most common)
  server version
2014-09-18 23:27:28 -04:00
Clayton Coleman 61e3ce7ddc Make runtime less global for Codec
* Make Codec separate from Scheme
* Move EncodeOrDie off Scheme to take a Codec
* Make Copy work without a Codec
* Create a "latest" package that imports all versions and
  sets global defaults for "most recent encoding"
  * v1beta1 is the current "latest", v1beta2 exists
  * Kill DefaultCodec, replace it with "latest.Codec"
  * This updates the client and etcd to store the latest known version
* EmbeddedObject is per schema and per package now
* Move runtime.DefaultScheme to api.Scheme
* Split out WatchEvent since it's not an API object today, treat it
like a special object in api
* Kill DefaultResourceVersioner, instead place it on "latest" (as the
  package that understands all packages)
* Move objDiff to runtime.ObjectDiff
2014-09-16 16:26:43 -04:00
Daniel Smith 0d30a656ef Do interface{} -> runtime.Object rename everywhere 2014-09-07 22:19:24 -07:00
Brendan Burns fee2b90608 Step #1 in migrating the service controller away from the apiserver.
Start using the API server for listing services.
2014-09-02 10:25:04 -07:00
Vojtech Vitek (V-Teq) 42c656501c Add several missing pkg Godoc files
Signed-off-by: Vojtech Vitek (V-Teq) <vvitek@redhat.com>
2014-09-02 13:41:11 +02:00
Vojtech Vitek (V-Teq) 59f58cd043 Unify Godoc formatting, fix various typos
Signed-off-by: Vojtech Vitek (V-Teq) <vvitek@redhat.com>
2014-09-02 13:41:03 +02:00
Daniel Smith 3c49aa96fe Merge pull request #1026 from lavalamp/redirect
Add simple service redirection
2014-08-28 14:54:10 -07:00
Clayton Coleman 818f357128 Client should validate the incoming host value
Convert host:port and URLs passed to client.New() into the proper
values, and return an error if the value is invalid.  Change CLI
to return an error if -master is invalid.  Remove Client.rawRequest
which was not in use, and fix the involved tests. Add NewOrDie

Preserves the behavior of the client to not auth when a non-https
URL is passed (although in the future this should be corrected).
2014-08-28 13:47:36 -04:00
Daniel Smith 4de254444e Add simple service redirection 2014-08-27 20:51:41 -07:00
Clayton Coleman b5e1e044bc Move EndpointsController to its own package
Avoids recursive loop with endpoint registry defined
2014-08-27 15:49:00 -04:00