-
Notifications
You must be signed in to change notification settings - Fork 4
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
Refactor: Switch to use username for document key instead of email #29
Comments
Summary: The Conduit spec requires email for login, but otherwise username is used by most other endpoints. I'm making the assumption that login will happen less frequently than other operations, so therefore the overall app will be less affected by the overhead of SQL when using it for login and k/v elsewhere. Endpoint analysis:
Handlers that needs changed:
Data access that needs changed:
Auth changes:
Migration changes:
Validator changes:
Controllers/Endpoints changes:
|
I think this went pretty smoothly. All tests are passing, and a manual run-through of the endpoints is working okay. |
Seems like username is a better choice for document key, especially since endpoints Follow, Unfollow, and Get profile all have username in their URL. Username is going to be used more for lookups than Email. Using a K-V operation in Couchbase is faster than a SQL query, if the result is only ever supposed to be ONE user/profile. So therefore, refactor to use K-V more often.
The text was updated successfully, but these errors were encountered: