pmatseykanets / laravel-scout-postgres

PostgreSQL Full Text Search Engine for Laravel Scout
MIT License
159 stars 36 forks source link

Unique Violation #28

Open swilla opened 5 years ago

swilla commented 5 years ago

I'm receiving a unique violation, we are queueing the the scout processes with 5 concurrent workers. Does this look like it is caused by a race condition of some sort? Maybe two jobs of the same model are being executed concurrently? How many simultaneous jobs would you recommend?

Doctrine\DBAL\Driver\PDOException:
SQLSTATE[23505]: Unique violation: 7 ERROR:  duplicate key value violates unique constraint "users_pkey"
DETAIL:  Key (id)=(136778) already exists.
SQLSTATE[23505]: Unique violation: 7 ERROR:  duplicate key value violates unique constraint "users_pkey"
DETAIL:  Key (id)=(136778) already exists. (SQL: insert into "users" ("searchable", "id") values ('136778':1 'username':2A,3A, 136778))