class MyModel(models.Model):
    prefix = models.CharField(max_length=3)
slug = models.SlugField(max_length=255)
name = models.CharField(max_length=255)
Django: how to do get_or_create() in a threadsafe way?