Michael Crosby
0d52c71c80
Merge pull request #2474 from dmcgowan/lease-expiration
...
Improved lease management
2018-07-20 16:54:17 -04:00
Michael Crosby
17ab11a236
Fixes for runtimev2 and checkpoint restore
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-07-20 12:09:29 -04:00
Michael Crosby
d53a96fbe4
Add comments for oci protos
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-07-18 15:12:18 -04:00
Derek McGowan
8cf3fad8d4
Add leases manager interface
...
Add leases manager to the leases package and use the
interface on the client and service.
Signed-off-by: Derek McGowan <derek@mcgstyle.net >
2018-07-18 10:43:37 -07:00
Michael Crosby
026b7d922f
Add README.md to runtime v2
...
This readme specifies shim api and authoring docs.
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-07-18 12:08:11 -04:00
Michael Crosby
fd31052d9c
Add oom events to shim
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-07-17 16:52:05 -04:00
Michael Crosby
7e49c601a8
Add shim start
for shim creation
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-07-17 10:21:29 -04:00
Michael Crosby
da1b5470cd
Runtime v2
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-07-17 10:21:29 -04:00
Michael Crosby
08150bfe76
Update ttrpc for containerd repo
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-06-28 09:53:40 -04:00
Michael Crosby
68e144c637
Set shim max procs via env var
...
This sets the shim's max procs to 2, like we already have hard coded in
the shim, with the env var so that it is set at go runtime boot.
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-06-26 10:49:59 -04:00
Evan Hazlett
a435f2886c
separate proc interfaces into standalone package
...
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com >
2018-06-07 10:03:15 -04:00
Evan Hazlett
821c8eaa91
runtime/linux/shim -> runtime/shim
...
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com >
2018-06-06 14:35:06 -04:00
Evan Hazlett
cae94b930d
linux -> runtime/linux
...
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com >
2018-05-30 09:23:10 -04:00
Michael Crosby
c87ed12da5
Move restart pkg to runtime
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-05-22 17:13:40 -04:00
Michael Crosby
ceae112f7d
Rename Runtime to PlatformRuntime
...
This renames the runtime interface to PlatformRuntime to denote the
layer at which the runtime is being abstracted. This should be used to
abstract different platforms that vary greatly and do not have full
compat with OCI based binary runtimes.
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-05-16 09:36:05 -04:00
Kunal Kushwaha
b12c3215a0
Licence header added
...
Signed-off-by: Kunal Kushwaha <kushwaha_kunal_v7@lab.ntt.co.jp >
2018-02-19 10:32:26 +09:00
Michael Crosby
95d4f53fbe
Delete task on dead shim
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2018-02-06 12:46:06 -05:00
Lantao Liu
71e42bf65c
Lock task list properly.
...
Signed-off-by: Lantao Liu <lantaol@google.com >
2017-12-03 21:20:01 +00:00
Michael Crosby
5fd0415985
Add comments and fix common lint issues
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-10-20 13:19:14 -04:00
Jess
061c719209
ListPids returns process ID and other info
...
Signed-off-by: Jess <jessica.valarezo@docker.com >
2017-10-10 22:57:15 +00:00
Michael Crosby
451421b615
Comment more packages to pass go lint
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-10-02 13:54:56 -04:00
Michael Crosby
d67763d922
Add wait API endpoint for waiting on process exit
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-09-21 15:03:58 -04:00
Michael Crosby
d22160c28e
Vendor typeurl package
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-09-19 09:43:55 -04:00
Michael Crosby
697dcdd407
Refactor task service metrics
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-09-05 17:26:26 -04:00
Kenfe-Mickael Laventure
3f34c421d3
Add missing "/tasks/exec-started" event topic
...
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com >
2017-08-29 08:27:44 -07:00
Kenfe-Mickael Laventure
d541567119
Handle SIGKILL'ed shim while daemon is running
...
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com >
2017-08-29 08:27:44 -07:00
Kenfe-Mickael Laventure
8a1b03e525
Add ExitedAt to process proto definition
...
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com >
2017-08-21 08:18:02 -07:00
Michael Crosby
4950c26757
Revert "Wait for client side copy goroutines to start"
...
This reverts commit 06dc87ae59
.
Revert "Change oom metric to const"
This reverts commit e800f08f9f
.
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-08-18 16:20:02 -04:00
Michael Crosby
e800f08f9f
Change oom metric to const
...
This removes the metric vec that was holding onto all task id and
namespace combinations forever, until containerd was restarted. This
was causing a memory leak with many task.
This also removes the shim cmd where the `Args` is quite large from the
reaper after the shim has been started cutting down on another leak.
This is the first pass through the reaper but more code is required to
fix all the issues when commands are added.
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-08-17 16:23:20 -04:00
Michael Crosby
9f13b414b9
Return exit status from Wait of stopped process
...
This changes Wait() from returning an error whenever you call wait on a
stopped process/task to returning the exit status from the process.
This also adds the exit status to the Status() call on a process/task so
that a user can Wait(), check status, then cancel the wait to avoid
races in event handling.
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-08-03 17:22:33 -04:00
Michael Crosby
a2a3451925
Implement Exec + Start for tasks service
...
This splits up the exec creation and start in the tasks service
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-08-02 13:50:08 -04:00
Kenfe-Mickael Laventure
674b460d5a
Move typeurl registrations to runtime package
...
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com >
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
61fbd2311c
windows: Refactor whole code
...
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com >
2017-07-20 18:39:46 +02:00
Derek McGowan
a8504277cc
Merge pull request #1209 from stevvooe/remove-errors
...
linux, linux/shim: remove error definitions
2017-07-18 19:18:23 -07:00
Stephen J Day
6d0bcd5aec
linux, linux/shim: remove error definitions
...
Since we now have a common set of error definitions, mapped to existing
error codes, we no longer need the specialized error codes used for
interaction with linux processes. The main issue was that string
matching was being used to map these to useful error codes. With this
change, we use errors defined in the `errdefs` package, which map
cleanly to GRPC error codes and are recoverable on either side of the
request.
The main focus of this PR was in removin these from the shim. We may
need follow ups to ensure error codes are preserved by the `Tasks`
service.
Signed-off-by: Stephen J Day <stephen.day@docker.com >
2017-07-18 15:56:49 -07:00
Kenfe-Mickael Laventure
e4beb7c554
Use constants for runtime event topics
...
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com >
2017-07-18 14:19:48 +02:00
Kenfe-Mickael Laventure
88c1db5ca5
Move taskList to the runtime package
...
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com >
2017-07-13 13:53:22 +02:00
Michael Crosby
6578565216
Use event service post for shim events
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-07-07 16:30:57 -07:00
Michael Crosby
f93bfb6233
Add Exec IDs
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-07-06 15:23:08 -07:00
Michael Crosby
a60511d5aa
Use typeurl package for spec types
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-07-05 15:37:26 -07:00
Michael Crosby
72831b6985
Use Any instead of []byte
...
This allows us to get the fully TypeURL for consuming code.
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-06-29 15:32:45 -07:00
Michael Crosby
82d0208aaa
Implement options for runtime specific settings
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-06-29 15:32:45 -07:00
Michael Crosby
e2d5522435
Change ListProcesses to ListPids
...
These rpcs only return pids []uint32 so should be named that way in
order to have other rpcs that list Processes such as Exec'd processes.
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-06-28 16:10:41 -07:00
Michael Crosby
040558cf81
Remove runtime.Event types
...
This uses the events service types for runtime events
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-06-28 10:47:22 -07:00
Michael Crosby
7c8acca29a
Move runtime interfaces to runtime package
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2017-06-28 10:10:59 -07:00
Michael Crosby
e115b52ce2
Remove containerd files
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2016-11-07 13:10:09 -08:00
Michael Crosby
97c3c3847a
Refactor epoll monitor for generic use
...
Signed-off-by: Michael Crosby <crosbymichael@gmail.com >
2016-09-22 14:03:45 -07:00
Kenfe-Mickael Laventure
db9aed5a97
Use uint32 as Event's Status type everywhere
...
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com >
2016-09-19 12:01:34 -07:00
Kenfe-Mickael Laventure
600b4d1154
Remove containerd as subreaper
...
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com >
2016-09-16 13:38:17 -07:00
Kenfe-Mickael Laventure
85050da1e0
Update ExitStatusFile correctly if process died while daemon was down
...
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com >
2016-09-16 13:30:16 -07:00