feat(storage): Add pluginInfo to storageBucket

This commit is contained in:
Louis Ruch authored and Timothy Messier committed 2023-05-31 12:18:10 +00:00
1 parent 87eb94e026
commit def8e47f32
5 files changed
+93 -34

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: MPL-2.0
package plugin
import (
"context"
wpbs "github.com/hashicorp/boundary/internal/gen/worker/servers/services"
)
// StorageProxyClient provides a storage related functions that will be sent from a controller
// to a worker through a CommandClientProducer to a corresponding storage plugin.
type StorageProxyClient interface {
// OnCreateStorageBucket is a hook that runs when a storage bucket is created.
OnCreateStorageBucket(context.Context, *wpbs.OnCreateStorageBucketRequest) (*wpbs.OnCreateStorageBucketResponse, error)
// OnUpdateStorageBucket is a hook that runs when a storage bucket is updated.
OnUpdateStorageBucket(context.Context, *wpbs.OnUpdateStorageBucketRequest) (*wpbs.OnUpdateStorageBucketResponse, error)
// OnDeleteStorageBucket is a hook that runs when a storage bucket is deleted.
OnDeleteStorageBucket(context.Context, *wpbs.OnDeleteStorageBucketRequest) (*wpbs.OnDeleteStorageBucketResponse, error)
}