Skip to content

[refactoring] Replace all deprecated logger methods #685

Closed
@ldmonster

Description

@ldmonster

Is your feature request related to a problem? Please describe.

We need to replace all deprecated methods to unify code style and clean logger implementation

Describe the solution you'd like to see

Remove staticcheck linter restriction and replace all methods
golangcilint

  # TODO: replace deprecated methods
  # ignore deprecated 
  # https://staticcheck.dev/docs/checks/#SA1019
  staticcheck:
     checks: ["all","-SA1019"]

Use slog Attrs when refactoring methods

// old method
logger.Infof("user with id '%d' and name '%s' created", user.id, user.name)
// refactored method
logger.Info("user created",slog.Int64("id",user.id), slog.String("name",user.name))

Describe alternatives you've considered

Additional context

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions