Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // option 1
- arkplugin.NewSimpleServer().
- RegisterObjectStores(map[string]func() cloudprovider.ObjectStore{
- "aws": setupAws,
- "azure": azure.NewObjectStore,
- "gcp": setupGcp,
- }).
- RegisterBlockStores(map[string]func() cloudprovider.BlockStore{
- "aws": aws.NewBlockStore,
- "azure": azure.NewBlockStore,
- "gcp": abc,
- }).
- Serve()
- // option 2
- arkplugin.NewSimpleServer().
- RegisterObjectStore("aws", xxx).
- RegisterObjectStore("azure", azure.NewObjectStore).
- RegisterObjectStore("gcp", yyy).
- RegisterBlockStore("aws", aws.NewBlockStore).
- RegisterBlockStore("azure", azure.NewBlockStore).
- RegisterBlockStore("gcp": zzz).
- Serve()
- // option 3
- arkplugin.NewSimpleServer().
- Register(PluginKindObjectStore, "aws", asdf).
- Register(PluginKindObjectStore, "gcp", gdgs).
- Serve()
- // option 4
- arkplugin.NewSimpleServer().
- RegisterObjectStores(
- "aws", setupAws,
- "gcp", setupGcp,
- "azure", setupAzure,
- ).
- RegisterBlockStores(
- ...
- ).
- Serve()
Add Comment
Please, Sign In to add comment