Documentation ¶
Index ¶
- type MetaClientMock
- func (c *MetaClientMock) AdminUserExists() bool
- func (c *MetaClientMock) Authenticate(username, password string) (meta.User, error)
- func (c *MetaClientMock) Close() error
- func (c *MetaClientMock) CreateContinuousQuery(database, name, query string) error
- func (c *MetaClientMock) CreateDatabase(name string) (*meta.DatabaseInfo, error)
- func (c *MetaClientMock) CreateDatabaseWithRetentionPolicy(name string, spec *meta.RetentionPolicySpec) (*meta.DatabaseInfo, error)
- func (c *MetaClientMock) CreateRetentionPolicy(database string, spec *meta.RetentionPolicySpec, makeDefault bool) (*meta.RetentionPolicyInfo, error)
- func (c *MetaClientMock) CreateShardGroup(database, policy string, timestamp time.Time) (*meta.ShardGroupInfo, error)
- func (c *MetaClientMock) CreateSubscription(database, rp, name, mode string, destinations []string) error
- func (c *MetaClientMock) CreateUser(name, password string, admin bool) (meta.User, error)
- func (c *MetaClientMock) Data() meta.Data
- func (c *MetaClientMock) Database(name string) *meta.DatabaseInfo
- func (c *MetaClientMock) Databases() []meta.DatabaseInfo
- func (c *MetaClientMock) DeleteShardGroup(database string, policy string, id uint64) error
- func (c *MetaClientMock) DropContinuousQuery(database, name string) error
- func (c *MetaClientMock) DropDatabase(name string) error
- func (c *MetaClientMock) DropRetentionPolicy(database, name string) error
- func (c *MetaClientMock) DropShard(id uint64) error
- func (c *MetaClientMock) DropSubscription(database, rp, name string) error
- func (c *MetaClientMock) DropUser(name string) error
- func (c *MetaClientMock) Open() error
- func (c *MetaClientMock) RetentionPolicy(database, name string) (rpi *meta.RetentionPolicyInfo, err error)
- func (c *MetaClientMock) SetAdminPrivilege(username string, admin bool) error
- func (c *MetaClientMock) SetData(d *meta.Data) error
- func (c *MetaClientMock) SetPrivilege(username, database string, p influxql.Privilege) error
- func (c *MetaClientMock) ShardGroupsByTimeRange(database, policy string, min, max time.Time) (a []meta.ShardGroupInfo, err error)
- func (c *MetaClientMock) ShardOwner(shardID uint64) (database, policy string, sgi *meta.ShardGroupInfo)
- func (c *MetaClientMock) UpdateRetentionPolicy(database, name string, rpu *meta.RetentionPolicyUpdate, makeDefault bool) error
- func (c *MetaClientMock) UpdateUser(name, password string) error
- func (c *MetaClientMock) User(username string) (meta.User, error)
- func (c *MetaClientMock) UserPrivilege(username, database string) (*influxql.Privilege, error)
- func (c *MetaClientMock) UserPrivileges(username string) (map[string]influxql.Privilege, error)
- func (c *MetaClientMock) Users() []meta.UserInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MetaClientMock ¶
type MetaClientMock struct { CloseFn func() error CreateContinuousQueryFn func(database, name, query string) error CreateDatabaseFn func(name string) (*meta.DatabaseInfo, error) CreateDatabaseWithRetentionPolicyFn func(name string, spec *meta.RetentionPolicySpec) (*meta.DatabaseInfo, error) CreateRetentionPolicyFn func(database string, spec *meta.RetentionPolicySpec, makeDefault bool) (*meta.RetentionPolicyInfo, error) CreateShardGroupFn func(database, policy string, timestamp time.Time) (*meta.ShardGroupInfo, error) CreateSubscriptionFn func(database, rp, name, mode string, destinations []string) error CreateUserFn func(name, password string, admin bool) (meta.User, error) DatabaseFn func(name string) *meta.DatabaseInfo DatabasesFn func() []meta.DatabaseInfo DataFn func() meta.Data DeleteShardGroupFn func(database string, policy string, id uint64) error DropContinuousQueryFn func(database, name string) error DropDatabaseFn func(name string) error DropRetentionPolicyFn func(database, name string) error DropSubscriptionFn func(database, rp, name string) error DropShardFn func(id uint64) error DropUserFn func(name string) error OpenFn func() error RetentionPolicyFn func(database, name string) (rpi *meta.RetentionPolicyInfo, err error) AuthenticateFn func(username, password string) (ui meta.User, err error) AdminUserExistsFn func() bool SetAdminPrivilegeFn func(username string, admin bool) error SetDataFn func(*meta.Data) error SetPrivilegeFn func(username, database string, p influxql.Privilege) error ShardGroupsByTimeRangeFn func(database, policy string, min, max time.Time) (a []meta.ShardGroupInfo, err error) ShardOwnerFn func(shardID uint64) (database, policy string, sgi *meta.ShardGroupInfo) UpdateRetentionPolicyFn func(database, name string, rpu *meta.RetentionPolicyUpdate, makeDefault bool) error UpdateUserFn func(name, password string) error UserPrivilegeFn func(username, database string) (*influxql.Privilege, error) UserPrivilegesFn func(username string) (map[string]influxql.Privilege, error) UserFn func(username string) (meta.User, error) UsersFn func() []meta.UserInfo }
MetaClientMock is a mockable implementation of meta.MetaClient.
func (*MetaClientMock) AdminUserExists ¶
func (c *MetaClientMock) AdminUserExists() bool
func (*MetaClientMock) Authenticate ¶
func (c *MetaClientMock) Authenticate(username, password string) (meta.User, error)
func (*MetaClientMock) Close ¶
func (c *MetaClientMock) Close() error
func (*MetaClientMock) CreateContinuousQuery ¶
func (c *MetaClientMock) CreateContinuousQuery(database, name, query string) error
func (*MetaClientMock) CreateDatabase ¶
func (c *MetaClientMock) CreateDatabase(name string) (*meta.DatabaseInfo, error)
func (*MetaClientMock) CreateDatabaseWithRetentionPolicy ¶
func (c *MetaClientMock) CreateDatabaseWithRetentionPolicy(name string, spec *meta.RetentionPolicySpec) (*meta.DatabaseInfo, error)
func (*MetaClientMock) CreateRetentionPolicy ¶
func (c *MetaClientMock) CreateRetentionPolicy(database string, spec *meta.RetentionPolicySpec, makeDefault bool) (*meta.RetentionPolicyInfo, error)
func (*MetaClientMock) CreateShardGroup ¶
func (c *MetaClientMock) CreateShardGroup(database, policy string, timestamp time.Time) (*meta.ShardGroupInfo, error)
func (*MetaClientMock) CreateSubscription ¶
func (c *MetaClientMock) CreateSubscription(database, rp, name, mode string, destinations []string) error
func (*MetaClientMock) CreateUser ¶
func (*MetaClientMock) Data ¶
func (c *MetaClientMock) Data() meta.Data
func (*MetaClientMock) Database ¶
func (c *MetaClientMock) Database(name string) *meta.DatabaseInfo
func (*MetaClientMock) Databases ¶
func (c *MetaClientMock) Databases() []meta.DatabaseInfo
func (*MetaClientMock) DeleteShardGroup ¶
func (c *MetaClientMock) DeleteShardGroup(database string, policy string, id uint64) error
func (*MetaClientMock) DropContinuousQuery ¶
func (c *MetaClientMock) DropContinuousQuery(database, name string) error
func (*MetaClientMock) DropDatabase ¶
func (c *MetaClientMock) DropDatabase(name string) error
func (*MetaClientMock) DropRetentionPolicy ¶
func (c *MetaClientMock) DropRetentionPolicy(database, name string) error
func (*MetaClientMock) DropShard ¶
func (c *MetaClientMock) DropShard(id uint64) error
func (*MetaClientMock) DropSubscription ¶
func (c *MetaClientMock) DropSubscription(database, rp, name string) error
func (*MetaClientMock) DropUser ¶
func (c *MetaClientMock) DropUser(name string) error
func (*MetaClientMock) Open ¶
func (c *MetaClientMock) Open() error
func (*MetaClientMock) RetentionPolicy ¶
func (c *MetaClientMock) RetentionPolicy(database, name string) (rpi *meta.RetentionPolicyInfo, err error)
func (*MetaClientMock) SetAdminPrivilege ¶
func (c *MetaClientMock) SetAdminPrivilege(username string, admin bool) error
func (*MetaClientMock) SetPrivilege ¶
func (c *MetaClientMock) SetPrivilege(username, database string, p influxql.Privilege) error
func (*MetaClientMock) ShardGroupsByTimeRange ¶
func (c *MetaClientMock) ShardGroupsByTimeRange(database, policy string, min, max time.Time) (a []meta.ShardGroupInfo, err error)
func (*MetaClientMock) ShardOwner ¶
func (c *MetaClientMock) ShardOwner(shardID uint64) (database, policy string, sgi *meta.ShardGroupInfo)
func (*MetaClientMock) UpdateRetentionPolicy ¶
func (c *MetaClientMock) UpdateRetentionPolicy(database, name string, rpu *meta.RetentionPolicyUpdate, makeDefault bool) error
func (*MetaClientMock) UpdateUser ¶
func (c *MetaClientMock) UpdateUser(name, password string) error
func (*MetaClientMock) UserPrivilege ¶
func (c *MetaClientMock) UserPrivilege(username, database string) (*influxql.Privilege, error)
func (*MetaClientMock) UserPrivileges ¶
func (*MetaClientMock) Users ¶
func (c *MetaClientMock) Users() []meta.UserInfo
Click to show internal directories.
Click to hide internal directories.