Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ad hoc backend user creation #220

Closed
2 tasks done
ztsai opened this issue Sep 14, 2020 · 0 comments · Fixed by #227
Closed
2 tasks done

ad hoc backend user creation #220

ztsai opened this issue Sep 14, 2020 · 0 comments · Fixed by #227

Comments

@ztsai
Copy link
Contributor

ztsai commented Sep 14, 2020

  • when resolving user with appId and userId, aka backend user:

    1. do a term query on appId and appUserId (could also query on id to be appId_sha(userId) but there might be collision)
    2. if the user doesn't exist, create a new user with id being appId_sha(userId)[iii] and randomly generated name and avatar.
    3. in case of collision, generate another id somehow (since collision is unlikely, collision prevention mechanism will be tracked separately in user id collision prevention #222 )
  • unit tests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant