Skip to content

Migrate services to NestJS #1005

@lamkeewei

Description

@lamkeewei

After migrating sequelize in #1006, we will continue to make use of Nest in standalone application mode to instantiate services. Existing tests should be preserved and used to prevent regressions.

At the same time, models should passed directly to services instead of passing in sequelize.

Services to be migrated:

  • AuthService
  • CheckerService
  • TemplateService
  • Mailer
  • TotpGenerator
  • Logger

Example of how this would look like in boostrap:

const app = await NestFactory.createApplicationContext(AppModule)
...
const checker = new CheckerController({ service: app.get(CheckerService) })

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions