Commit Graph

20 Commits

Author SHA1 Message Date
Brian Goff
682b2bccf8 Add support for tracing via OpenCencus
This adds a few flags for configuring the tracer.
Includes support for jaeger tracing (built into OC).
2018-09-26 13:48:40 -07:00
Brian Goff
083f6dee05 Refactor provider init (#360)
* Refactor provider init

This moves provider init out of vkubelet setup, instead preferring to
initialize vkubelet with a provider.

* Split API server configuration from setup.

This makes sure that configuration (which is done primarily through env
vars) is separate from actually standing up the servers.

This also makes sure to abort daemon initialization if the API servers
are not able to start.
2018-09-26 13:18:02 -07:00
Brian Goff
da5e24ef4d Move API handlers to separate package
This makes the package split a little cleaner and easier to import the
HTTP handlers for other consumers.
2018-09-18 11:08:24 -07:00
Brian Goff
74f76c75d5 Instrustment handlers for logging/error handling
This refactors a bit of the http handler code.
Moves error handling for handler functions to a generic handler.
This also has a side-effect of being able to propagate errors from the
provider to send the correct status code, provided the error type
matches a pre-defined interface.
2018-09-17 16:54:24 -07:00
Brian Goff
8eb6ab4bcd Remove intermediate API server objects
Instead just generate HTTP handler functions directly.
2018-09-17 14:47:26 -07:00
Brian Goff
8091b089a2 Plumb context to providers 2018-09-13 13:49:26 -07:00
Brian Goff
8de6693460 Don't use globals for API server
Refactors how HTTP servers are started and binds them to objects that
can store the provider rather than relying on a global.
2018-08-20 11:52:54 -07:00
Brian Goff
e8abca0ac9 Add supports for stats in ACI provider
This adds a new, optional, interface for providers that want to provide
stats.
2018-08-17 17:03:25 -07:00
Brian Goff
1e774a32b3 Use standard logging package (#323) 2018-08-17 16:50:24 -07:00
Daniel Mueller
31a415c83a Fix bug in exec command retrieval (#265)
The exec command as extracted from the query comprises only the first
part of the command and does not include potentially supplied
parameters. E.g.,
  $ kubectl exec pod -- ls -t /usr
  > command: ls

This change fixes the problem by moving away from the Query.Get API.
  $ kubectl exec pod -- ls -t /usr
  > command: [ls -t /usr]
2018-07-25 11:54:22 -07:00
Eric Jadi
89921a08c1 Added clean exec functionality + ACI implementation - V2 (#244)
* Stubs and vkubelet changes

* added dependencies

* Azure provider exec implementation

* added missing dependencies

* added vkubelet imports

* added huawei exec stub

* Fixed exec tab functionality / stdin buffer length

* Removed unused import

* Added provider function GetPodFullName + ACI implementation

* Added error handling in ACI provider exec
2018-07-06 14:12:05 -07:00
Fei Xu
8068f3cac8 gofmt the project files (#205) 2018-05-18 16:13:34 -07:00
Robbie Zhang
2b85b0d1df Fill in Default Values for CPU/Memory (#130)
Update k8s client and the dependencies
ACI client change for Mocking
Add ACI Provider Mock Tests
Add the Windows development environment
Add UT for Default Resource Requests
Enable the make test in Docker file
Update the vendors
2018-04-16 10:31:16 -07:00
Rita Zhang
8b59becf35 Return error to kubectl logs; use http statuscode 2017-12-22 00:08:10 -08:00
Rita Zhang
43137d09f7 Use mux to handle req; get tail from req 2017-12-21 21:42:05 -08:00
Rita Zhang
f047137819 Add env var for kubelet port and ensure kubelet works without logs 2017-12-20 17:35:10 -08:00
Rita Zhang
bcc5a33098 Mount secret for api server cert and key 2017-12-15 18:35:49 -08:00
Rita Zhang
105c9fdada Remove some logging 2017-12-15 17:25:19 -08:00
Rita Zhang
123863c1ae Integrate apiserver with provider GetContainerLogs 2017-12-15 17:25:19 -08:00
Rita Zhang
e0c9da5d95 Enable kubectl logs po 2017-12-15 17:25:18 -08:00