Ensuring unique indexes on nosql datastores

  softwareengineering

I am building a User Service. User would be able to register with emailId or phone no. Upon successful registration, they can choose a username (which should be unique)

It is easy to do on SQL datastores where I will create a unique index on emailID and userName.

But because of scale reasons let’s say I am not able to choose SQL datastore, How can this use case be modelled on nosql datastores?

LEAVE A COMMENT