@@ -3,40 +3,40 @@ package swarm // import "github.com/docker/docker/api/server/router/swarm"
33import (
44 "context"
55
6- basictypes "github.com/docker/docker/api/types"
6+ "github.com/docker/docker/api/types"
77 "github.com/docker/docker/api/types/backend"
8- types "github.com/docker/docker/api/types/swarm"
8+ "github.com/docker/docker/api/types/swarm"
99)
1010
1111// Backend abstracts a swarm manager.
1212type Backend interface {
13- Init (req types .InitRequest ) (string , error )
14- Join (req types .JoinRequest ) error
13+ Init (req swarm .InitRequest ) (string , error )
14+ Join (req swarm .JoinRequest ) error
1515 Leave (ctx context.Context , force bool ) error
16- Inspect () (types .Swarm , error )
17- Update (uint64 , types .Spec , types .UpdateFlags ) error
16+ Inspect () (swarm .Swarm , error )
17+ Update (uint64 , swarm .Spec , swarm .UpdateFlags ) error
1818 GetUnlockKey () (string , error )
19- UnlockSwarm (req types .UnlockRequest ) error
20- GetServices (basictypes .ServiceListOptions ) ([]types .Service , error )
21- GetService (idOrName string , insertDefaults bool ) (types .Service , error )
22- CreateService (types .ServiceSpec , string , bool ) (* basictypes .ServiceCreateResponse , error )
23- UpdateService (string , uint64 , types .ServiceSpec , basictypes .ServiceUpdateOptions , bool ) (* basictypes .ServiceUpdateResponse , error )
19+ UnlockSwarm (req swarm .UnlockRequest ) error
20+ GetServices (types .ServiceListOptions ) ([]swarm .Service , error )
21+ GetService (idOrName string , insertDefaults bool ) (swarm .Service , error )
22+ CreateService (swarm .ServiceSpec , string , bool ) (* types .ServiceCreateResponse , error )
23+ UpdateService (string , uint64 , swarm .ServiceSpec , types .ServiceUpdateOptions , bool ) (* swarm .ServiceUpdateResponse , error )
2424 RemoveService (string ) error
25- ServiceLogs (context.Context , * backend.LogSelector , * basictypes .ContainerLogsOptions ) (<- chan * backend.LogMessage , error )
26- GetNodes (basictypes .NodeListOptions ) ([]types .Node , error )
27- GetNode (string ) (types .Node , error )
28- UpdateNode (string , uint64 , types .NodeSpec ) error
25+ ServiceLogs (context.Context , * backend.LogSelector , * types .ContainerLogsOptions ) (<- chan * backend.LogMessage , error )
26+ GetNodes (types .NodeListOptions ) ([]swarm .Node , error )
27+ GetNode (string ) (swarm .Node , error )
28+ UpdateNode (string , uint64 , swarm .NodeSpec ) error
2929 RemoveNode (string , bool ) error
30- GetTasks (basictypes .TaskListOptions ) ([]types .Task , error )
31- GetTask (string ) (types .Task , error )
32- GetSecrets (opts basictypes .SecretListOptions ) ([]types .Secret , error )
33- CreateSecret (s types .SecretSpec ) (string , error )
30+ GetTasks (types .TaskListOptions ) ([]swarm .Task , error )
31+ GetTask (string ) (swarm .Task , error )
32+ GetSecrets (opts types .SecretListOptions ) ([]swarm .Secret , error )
33+ CreateSecret (s swarm .SecretSpec ) (string , error )
3434 RemoveSecret (idOrName string ) error
35- GetSecret (id string ) (types .Secret , error )
36- UpdateSecret (idOrName string , version uint64 , spec types .SecretSpec ) error
37- GetConfigs (opts basictypes .ConfigListOptions ) ([]types .Config , error )
38- CreateConfig (s types .ConfigSpec ) (string , error )
35+ GetSecret (id string ) (swarm .Secret , error )
36+ UpdateSecret (idOrName string , version uint64 , spec swarm .SecretSpec ) error
37+ GetConfigs (opts types .ConfigListOptions ) ([]swarm .Config , error )
38+ CreateConfig (s swarm .ConfigSpec ) (string , error )
3939 RemoveConfig (id string ) error
40- GetConfig (id string ) (types .Config , error )
41- UpdateConfig (idOrName string , version uint64 , spec types .ConfigSpec ) error
40+ GetConfig (id string ) (swarm .Config , error )
41+ UpdateConfig (idOrName string , version uint64 , spec swarm .ConfigSpec ) error
4242}
0 commit comments