Documentation ¶
Index ¶
- Variables
- func NewBigtableObjectClient(ctx context.Context, cfg Config, schemaCfg chunk.SchemaConfig) (chunk.ObjectClient, error)
- func NewGCSObjectClient(ctx context.Context, cfg GCSConfig, schemaCfg chunk.SchemaConfig) (chunk.ObjectClient, error)
- func NewStorageClientColumnKey(ctx context.Context, cfg Config, schemaCfg chunk.SchemaConfig) (chunk.IndexClient, error)
- func NewStorageClientV1(ctx context.Context, cfg Config, schemaCfg chunk.SchemaConfig) (chunk.IndexClient, error)
- func NewTableClient(ctx context.Context, cfg Config) (chunk.TableClient, error)
- type Config
- type GCSConfig
Constants ¶
This section is empty.
Variables ¶
View Source
var Fixtures = func() []testutils.Fixture { fixtures := []testutils.Fixture{} for _, gcsObjectClient := range []bool{true, false} { for _, columnKeyClient := range []bool{true, false} { for _, hashPrefix := range []bool{true, false} { fixtures = append(fixtures, &fixture{ name: fmt.Sprintf("bigtable-columnkey:%v-gcsObjectClient:%v-hashPrefix:%v", columnKeyClient, gcsObjectClient, hashPrefix), columnKeyClient: columnKeyClient, gcsObjectClient: gcsObjectClient, hashPrefix: hashPrefix, }) } } } return fixtures }()
Fixtures for unit testing GCP storage.
Functions ¶
func NewBigtableObjectClient ¶
func NewBigtableObjectClient(ctx context.Context, cfg Config, schemaCfg chunk.SchemaConfig) (chunk.ObjectClient, error)
NewBigtableObjectClient makes a new chunk.ObjectClient that stores chunks in Bigtable.
func NewGCSObjectClient ¶
func NewGCSObjectClient(ctx context.Context, cfg GCSConfig, schemaCfg chunk.SchemaConfig) (chunk.ObjectClient, error)
NewGCSObjectClient makes a new chunk.ObjectClient that writes chunks to GCS.
func NewStorageClientColumnKey ¶
func NewStorageClientColumnKey(ctx context.Context, cfg Config, schemaCfg chunk.SchemaConfig) (chunk.IndexClient, error)
NewStorageClientColumnKey returns a new v2 StorageClient.
func NewStorageClientV1 ¶
func NewStorageClientV1(ctx context.Context, cfg Config, schemaCfg chunk.SchemaConfig) (chunk.IndexClient, error)
NewStorageClientV1 returns a new v1 StorageClient.
func NewTableClient ¶
NewTableClient returns a new TableClient.
Types ¶
type Config ¶
type Config struct { Project string `yaml:"project"` Instance string `yaml:"instance"` GRPCClientConfig grpcclient.Config `yaml:"grpc_client_config"` ColumnKey bool DistributeKeys bool TableCacheEnabled bool TableCacheExpiration time.Duration }
Config for a StorageClient
func (*Config) RegisterFlags ¶
RegisterFlags adds the flags required to config this to the given FlagSet
Click to show internal directories.
Click to hide internal directories.