Adding pluginv2 support for libnetwork (part 1)

Legacy plugins (aka pluginv1) calls in libnetwork are replaced with
calls using the new plugin model (aka pluginv2). pkg/plugins is still
used for managing the http client connections to the plugin.

This commit makes the necessary changes in docker/docker. Part 2 will
will take care of the libnetwork changes.

Signed-off-by: Anusha Ragunathan <anusha@docker.com>
Upstream-commit: 17b8aba1d924e505563af400d758b89c8406961d
Component: engine
This commit is contained in:
Anusha Ragunathan
2016-09-06 14:30:55 -07:00
parent 17a1a5ab1b
commit 2f08c46e47
4 changed files with 35 additions and 29 deletions
+3 -2
View File
@@ -623,11 +623,12 @@ func NewDaemon(config *Config, registryService registry.Service, containerdRemot
return nil, err
}
if err := d.restore(); err != nil {
// Plugin system initialization should happen before restore. Dont change order.
if err := pluginInit(d, config, containerdRemote); err != nil {
return nil, err
}
if err := pluginInit(d, config, containerdRemote); err != nil {
if err := d.restore(); err != nil {
return nil, err
}