Documentation
¶
Index ¶
- Variables
- type Logger
- func (l *Logger) AddUserNoteTags(id, noteID int64)
- func (l *Logger) ChangeEmail(id int64, newEmail string)
- func (l *Logger) ChangePassword(id int64)
- func (l *Logger) ChangeUsername(id int64, newUsername string)
- func (l *Logger) CreateUserNote(id, noteID int64)
- func (l *Logger) CreateUserNoteVersion(id, noteID, noteVersionID int64)
- func (l *Logger) CreateUserTag(id, tagID int64)
- func (l *Logger) DeleteUser(id int64)
- func (l *Logger) DeleteUserNote(id, noteID int64)
- func (l *Logger) DeleteUserNoteVersion(id, noteVersionID int64)
- func (l *Logger) DeleteUserTag(id, tagID int64)
- func (l *Logger) DisableUser2FA(id int64)
- func (l *Logger) EnableUser2FA(id int64)
- func (l *Logger) FailedToSend2FAEmailCode(email string, err error)
- func (l *Logger) FailedToSendResetPasswordEmail(email string, err error)
- func (l *Logger) FailedToSendVerificationEmail(email string, err error)
- func (l *Logger) FailedToSendWelcomeEmail(email string, err error)
- func (l *Logger) ForgotPassword(id int64)
- func (l *Logger) Generate2FATOTPUrl(id int64)
- func (l *Logger) GetMyProfile(id int64)
- func (l *Logger) GetRefreshToken(id, refreshTokenID int64)
- func (l *Logger) GetUserNoteByID(id, noteID int64)
- func (l *Logger) GetUserNoteVersionByID(id, noteVersionID int64)
- func (l *Logger) GetUserTagByID(id, tagID int64)
- func (l *Logger) ListRefreshTokens(id int64)
- func (l *Logger) ListUserNoteTags(id, noteID int64)
- func (l *Logger) ListUserNoteVersions(id, noteID int64)
- func (l *Logger) ListUserNotes(id int64)
- func (l *Logger) ListUserTags(id int64)
- func (l *Logger) LogIn(id int64)
- func (l *Logger) LogOut(id int64)
- func (l *Logger) PoolStat(stat *pgxpool.Stat)
- func (l *Logger) RefreshToken(id int64)
- func (l *Logger) RegenerateUser2FARecoveryCodes(id int64)
- func (l *Logger) RemoveUserNoteTags(id, noteID int64)
- func (l *Logger) ResetPassword(id int64)
- func (l *Logger) Revoke2FATOTP(id int64)
- func (l *Logger) RevokeRefreshToken(id int64)
- func (l *Logger) RevokeRefreshTokens(id int64)
- func (l *Logger) SendEmailVerificationToken(id int64)
- func (l *Logger) SendUser2FAEmailCode(id int64)
- func (l *Logger) Sent2FAEmailCode(email string)
- func (l *Logger) SentResetPasswordEmail(email string)
- func (l *Logger) SentVerificationEmail(email string)
- func (l *Logger) SentWelcomeEmail(email string)
- func (l *Logger) ServerStarted(port string)
- func (l *Logger) ServingSwaggerUI(docsPath string)
- func (l *Logger) SignUp(id int64)
- func (l *Logger) SyncByLastSyncedAt(id int64, userTagsLastSyncedAt, userNotesLastSyncedAt *time.Time, ...)
- func (l *Logger) SyncUserNoteVersions(id, noteID, latestNoteVersionID int64)
- func (l *Logger) SyncUserNotesByLastSyncedAt(id int64, lastSyncedAt *time.Time, refreshTokenID int64)
- func (l *Logger) SyncUserTagsByLastSyncedAt(id int64, lastSyncedAt *time.Time, refreshTokenID int64)
- func (l *Logger) UpdateProfile(id int64)
- func (l *Logger) UpdateUserNote(id, noteID int64)
- func (l *Logger) UpdateUserNoteArchive(id, noteID int64, archive bool)
- func (l *Logger) UpdateUserNotePin(id, noteID int64, pin bool)
- func (l *Logger) UpdateUserNoteStar(id, noteID int64, star bool)
- func (l *Logger) UpdateUserNoteTrash(id, noteID int64, trash bool)
- func (l *Logger) UpdateUserTag(id, tagID int64)
- func (l *Logger) Verify2FATOTP(id int64)
- func (l *Logger) VerifyEmail(id int64)
Constants ¶
This section is empty.
Variables ¶
var ( // BaseLogger is the base logger for the server BaseLogger = gologger.NewDefaultLogger() // ModeLogger is the extended logger for the server with mode support ModeLogger, _ = gologgermode.NewDefaultLogger(BaseLogger) // Environment is the logger for the environment Environment, _ = goloaderenv.NewLogger( "ENV", ModeLogger, ) // Postgres is the logger for the Postgres client Postgres, _ = godatabases.NewLogger( "POSTGRES", ModeLogger, ) // Router is the logger for the router Router, _ = gonethttproute.NewLogger( "ROUTER", ModeLogger, ) // Api is the logger for the API endpoints Api, _ = NewLogger("API", ModeLogger) // CacheTokenValidator is the logger for the cache token validator CacheTokenValidator, _ = gojwtcache.NewLogger( "CACHE TOKEN VALIDATOR", ModeLogger, ) // MapperGenerator is the logger for the mapper generator MapperGenerator, _ = govalidatormapper.NewLogger( "MAPPER GENERATOR", ModeLogger, ) // MapperValidator is the logger for the mapper validator MapperValidator, _ = govalidatormappervalidator.NewLogger( "MAPPER VALIDATOR", ModeLogger, ) // MapperParser is the logger for the mapper parser MapperParser, _ = govalidatormapperparserjson.NewLogger( "MAPPER PARSER", ModeLogger, ) )
Functions ¶
This section is empty.
Types ¶
type Logger ¶
type Logger struct {
// contains filtered or unexported fields
}
Logger is the logger for the API server
func NewLogger ¶
func NewLogger(header string, modeLogger gologgermode.Logger) (*Logger, error)
NewLogger is the logger for the API server
func (*Logger) AddUserNoteTags ¶
AddUserNoteTags logs the add user note tags event
func (*Logger) ChangeEmail ¶
ChangeEmail logs the change email event
func (*Logger) ChangePassword ¶
ChangePassword logs the change password event
func (*Logger) ChangeUsername ¶
ChangeUsername logs the change username event
func (*Logger) CreateUserNote ¶
CreateUserNote logs the user note creation event
func (*Logger) CreateUserNoteVersion ¶
CreateUserNoteVersion logs the user note version creation event
func (*Logger) CreateUserTag ¶
CreateUserTag logs the user tag creation event
func (*Logger) DeleteUser ¶
DeleteUser logs the delete user event
func (*Logger) DeleteUserNote ¶
DeleteUserNote logs the delete user note event
func (*Logger) DeleteUserNoteVersion ¶
DeleteUserNoteVersion logs the delete user note version event
func (*Logger) DeleteUserTag ¶
DeleteUserTag logs the delete user tag event
func (*Logger) DisableUser2FA ¶
DisableUser2FA logs the disable user 2FA event
func (*Logger) EnableUser2FA ¶
EnableUser2FA logs the enable user 2FA event
func (*Logger) FailedToSend2FAEmailCode ¶
FailedToSend2FAEmailCode logs the failed to send 2FA email code event
func (*Logger) FailedToSendResetPasswordEmail ¶
FailedToSendResetPasswordEmail logs the failed to send reset password email event
func (*Logger) FailedToSendVerificationEmail ¶
FailedToSendVerificationEmail logs the failed to send verification email event
func (*Logger) FailedToSendWelcomeEmail ¶
FailedToSendWelcomeEmail logs the failed to send welcome email event
func (*Logger) ForgotPassword ¶
ForgotPassword logs the forgot password event
func (*Logger) Generate2FATOTPUrl ¶
Generate2FATOTPUrl logs the generate 2FA TOTP URL event
func (*Logger) GetMyProfile ¶
GetMyProfile logs the get my profile event
func (*Logger) GetRefreshToken ¶
GetRefreshToken logs the get refresh token event
func (*Logger) GetUserNoteByID ¶
GetUserNoteByID logs the get user note by ID event
func (*Logger) GetUserNoteVersionByID ¶
GetUserNoteVersionByID logs the get user note version by ID event
func (*Logger) GetUserTagByID ¶
GetUserTagByID logs the get user tag by ID event
func (*Logger) ListRefreshTokens ¶
ListRefreshTokens logs the list refresh tokens event
func (*Logger) ListUserNoteTags ¶
ListUserNoteTags logs the list user note tags event
func (*Logger) ListUserNoteVersions ¶
ListUserNoteVersions logs the list user note versions event
func (*Logger) ListUserNotes ¶
ListUserNotes logs the list user notes event
func (*Logger) ListUserTags ¶
ListUserTags logs the list user tags event
func (*Logger) RefreshToken ¶
RefreshToken logs the refresh token event
func (*Logger) RegenerateUser2FARecoveryCodes ¶
RegenerateUser2FARecoveryCodes logs the regenerate user 2FA recovery codes event
func (*Logger) RemoveUserNoteTags ¶
RemoveUserNoteTags logs the remove user note tags event
func (*Logger) ResetPassword ¶
ResetPassword logs the reset password event
func (*Logger) Revoke2FATOTP ¶
Revoke2FATOTP logs the revoke 2FA TOTP event
func (*Logger) RevokeRefreshToken ¶
RevokeRefreshToken logs the revoke refresh token event
func (*Logger) RevokeRefreshTokens ¶
RevokeRefreshTokens logs the revoke refresh tokens event
func (*Logger) SendEmailVerificationToken ¶
SendEmailVerificationToken logs the send email verification token event
func (*Logger) SendUser2FAEmailCode ¶
SendUser2FAEmailCode logs the send user 2FA email code event
func (*Logger) Sent2FAEmailCode ¶
Sent2FAEmailCode logs that the 2FA email code was sent successfully
func (*Logger) SentResetPasswordEmail ¶
SentResetPasswordEmail logs that the reset password email was sent successfully
func (*Logger) SentVerificationEmail ¶
SentVerificationEmail logs that the verification email was sent successfully
func (*Logger) SentWelcomeEmail ¶
SentWelcomeEmail logs that the welcome email was sent successfully
func (*Logger) ServerStarted ¶
ServerStarted logs a success message when the server starts
func (*Logger) ServingSwaggerUI ¶
ServingSwaggerUI logs the serving swagger UI event
func (*Logger) SyncByLastSyncedAt ¶
func (l *Logger) SyncByLastSyncedAt( id int64, userTagsLastSyncedAt, userNotesLastSyncedAt *time.Time, refreshTokenID int64, )
SyncByLastSyncedAt logs the sync by last synced at event
func (*Logger) SyncUserNoteVersions ¶
SyncUserNoteVersions logs the sync user note versions event
func (*Logger) SyncUserNotesByLastSyncedAt ¶
func (l *Logger) SyncUserNotesByLastSyncedAt( id int64, lastSyncedAt *time.Time, refreshTokenID int64, )
SyncUserNotesByLastSyncedAt logs the sync user notes by last synced at event
func (*Logger) SyncUserTagsByLastSyncedAt ¶
func (l *Logger) SyncUserTagsByLastSyncedAt( id int64, lastSyncedAt *time.Time, refreshTokenID int64, )
SyncUserTagsByLastSyncedAt logs the sync user tags by last synced at event
func (*Logger) UpdateProfile ¶
UpdateProfile logs the update profile event
func (*Logger) UpdateUserNote ¶
UpdateUserNote logs the update user note event
func (*Logger) UpdateUserNoteArchive ¶
UpdateUserNoteArchive logs the update user note archive event
func (*Logger) UpdateUserNotePin ¶
UpdateUserNotePin logs the update user note pin event
func (*Logger) UpdateUserNoteStar ¶
UpdateUserNoteStar logs the update user note star event
func (*Logger) UpdateUserNoteTrash ¶
UpdateUserNoteTrash logs the update user note trash event
func (*Logger) UpdateUserTag ¶
UpdateUserTag logs the update user tag event
func (*Logger) Verify2FATOTP ¶
Verify2FATOTP logs the verify 2FA TOTP event
func (*Logger) VerifyEmail ¶
VerifyEmail logs the verify email event