mirror of
https://github.com/andwati/zitadel.git
synced 2026-11-19 19:48:45 +00:00
fix(storage): add indexes for auth.tokens (#5259)
* fix(storage): add indexes for `auth.tokens` * refactor: naming
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
package setup
|
||||
|
||||
import (
|
||||
"context"
|
||||
"database/sql"
|
||||
_ "embed"
|
||||
)
|
||||
|
||||
var (
|
||||
//go:embed 08.sql
|
||||
tokenIndexes08 string
|
||||
)
|
||||
|
||||
type AuthTokenIndexes struct {
|
||||
dbClient *sql.DB
|
||||
}
|
||||
|
||||
func (mig *AuthTokenIndexes) Execute(ctx context.Context) error {
|
||||
_, err := mig.dbClient.ExecContext(ctx, tokenIndexes08)
|
||||
return err
|
||||
}
|
||||
|
||||
func (mig *AuthTokenIndexes) String() string {
|
||||
return "08_auth_token_indexes"
|
||||
}
|
||||
Reference in New Issue
Block a user