Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Storage ¶
type Storage interface { // SaveBatch saves a new batch of usernames into Storage. // It can not be ascertained that each element in names will be unique, // hence SaveBatch must be designed to ignore error on such conflict // // Errors are logged to Logger SaveBatch(ctx context.Context, names []Username) (savedCount int64) // FetchNewUsername from Storage // Note that the fetched username can not be reused FetchNewUsername(ctx context.Context) (string, error) }
Click to show internal directories.
Click to hide internal directories.