Skip to content

Improve candidate account creation using bulk create #499

Description

@bri25yu

For https://github.com/compserv/hknweb/blob/master/hknweb/forms.py#L243

Currently each user creation is separate in a for loop, which is a single query per user, very slow. Try https://docs.djangoproject.com/en/4.1/ref/models/querysets/#bulk-create for bulk creation of users to speed this up to avoid timeout.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions