With the successful deployment of the auth(entic|oris)ation system to staging/CD, we need to move some of the existing features over to using the new auth(entic|oris)ation system.
This issue tracks the migration of user collections.
The user collections are stored in redis, and linked to the user using [the user id][0]. This ID is entirely different from that in the auth(entic|oris)ation system, unless we get the go-ahead to [migrate the user accounts][1].
The auth(entic|oris)ation system provides the following endpoint(s) for getting user details
Since we know the form that the user account are stored in redis[1], we can use that to search for user collections.
The steps would be something like:
#### Anonymous Collections
Users can create and work with collections without being authenticated to the system. Such collections (which I dub "anonymous collections") are ephemeral. They were linked to the session[2] via an anonymous user_id.
In the older system, a user was able to import such anonymous collections by selecting "Import existing collections" when they logged in (see the `import_traits_to_user` function in the sessions[2] module). We need to maintain this feature. This will probably require reworking the code, to get rid of the sessions[2] module while retaining most of what it does.