Documentation ¶
Index ¶
- Constants
- Variables
- type Manager
- func (u *Manager) Close() error
- func (u *Manager) CreateOperatorUser(pass string) error
- func (u *Manager) CreateReplicationUser(password string) error
- func (m *Manager) DiscardOldPassword(user *SysUser) error
- func (p *Manager) GetUser(ctx context.Context, user string) (*User, error)
- func (m *Manager) IsOldPassDiscarded(user *SysUser) (bool, error)
- func (u *Manager) Update1100MonitorUserPrivilege() (err error)
- func (u *Manager) Update1150XtrabackupUser(pass string) (err error)
- func (u *Manager) Update160MonitorUserGrant(pass string) (err error)
- func (u *Manager) UpdatePassExpirationPolicy(user *SysUser) error
- func (u *Manager) UpdateProxyUser(user *SysUser) error
- func (m *Manager) UpdateUserPass(user *SysUser) error
- func (u *Manager) UpdateUserPassWithoutDP(user *SysUser) error
- func (u *Manager) UpsertUser(ctx context.Context, query []string, pass string) error
- type SysUser
- type User
Constants ¶
const ( Root = "root" Operator = "operator" Monitor = "monitor" Xtrabackup = "xtrabackup" Replication = "replication" ProxyAdmin = "proxyadmin" PMMServer = "pmmserver" PMMServerKey = "pmmserverkey" )
Variables ¶
var UserNames = []string{Root, Operator, Monitor, Xtrabackup, Replication, ProxyAdmin, PMMServer, PMMServerKey}
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
func (*Manager) CreateOperatorUser ¶
func (*Manager) CreateReplicationUser ¶ added in v1.9.0
func (*Manager) DiscardOldPassword ¶ added in v1.12.0
DiscardOldPassword discards old passwords of given users
func (*Manager) IsOldPassDiscarded ¶ added in v1.12.0
DiscardOldPassword discards old passwords of given users
func (*Manager) Update1100MonitorUserPrivilege ¶ added in v1.14.0
Update1100MonitorUserPrivilege grants system_user privilege for monitor
func (*Manager) Update1150XtrabackupUser ¶ added in v1.15.0
Update1150XtrabackupUser grants all needed rights to the xtrabackup user
func (*Manager) Update160MonitorUserGrant ¶ added in v1.6.0
Update160MonitorUserGrant grants SERVICE_CONNECTION_ADMIN rights to the monitor user if pxc version is 8 or more and sets the MAX_USER_CONNECTIONS parameter to 100 (empirically determined)
func (*Manager) UpdatePassExpirationPolicy ¶ added in v1.13.0
UpdatePassExpirationPolicy sets user password expiration policy to never
func (*Manager) UpdateProxyUser ¶ added in v1.12.0
func (*Manager) UpdateUserPass ¶ added in v1.12.0
UpdateUserPass updates user passwords but retains the current password using Dual Password feature of MySQL 8.
func (*Manager) UpdateUserPassWithoutDP ¶ added in v1.12.0
UpdateUserPassWithoutDP updates user pass without Dual Password feature introduced in MsSQL 8