ring

sova-soars-the-sora 2017-12-08T00:11:45.000113Z

@weavejester thanks I just grabbed (first and (second ...

sova-soars-the-sora 2017-12-08T00:12:07.000052Z

I feel bad to ask so many questions to you, but I have one more...

sova-soars-the-sora 2017-12-08T00:12:23.000026Z

how can I write directly to the session? is the session data stored on the clientside?

sova-soars-the-sora 2017-12-08T00:13:33.000109Z

I want to change the session data via sente event, which does have a ring-map but i don't think affecting the incoming copy of the ring parameters would do anything to the session. it seems like a redirect / url shift would be required to change session data w/ my understanding at this point

2017-12-08T00:28:05.000039Z

@sova It depends how you’re storing the session.

2017-12-08T00:39:22.000120Z

What session store are you using?

sova-soars-the-sora 2017-12-08T07:52:30.000107Z

@weavejester i want to write directly to the ring session, as part of the map, if possible. my current scheme just stores at atom in the clientside of login email, login time, and hash.

sova-soars-the-sora 2017-12-08T07:52:46.000038Z

user submits info over socket -> gets authentication information over socket

sova-soars-the-sora 2017-12-08T07:53:42.000266Z

but I want to make sure that if a user navigated to say /article/:whatever they would still have their login creds active. writing to localStorage won't persist this if the user has localStorage disabled, so i am thinking having ring session as a directory-level fallback

sova-soars-the-sora 2017-12-08T07:54:55.000196Z

does my approach make sense? maybe the authentication can all be ring session level...

sova-soars-the-sora 2017-12-08T07:58:16.000323Z

to be honest, i was not aware that there are different ways to store the session. what are the alternatives? (googles furiously)

2017-12-08T12:23:24.000350Z

@sova Sessions persist over requests, so they require some form of storage. By default, Ring provides two stores: an in-memory atom held on the server, and through encrypted cookies. You can also use third-party stores, or write your own, that store sessions on the filesystem or in a database.

2017-12-08T12:24:59.000376Z

You can access the store directly to update the session in most cases. Cookie stores are an exception, since they require a HTTP response.

2017-12-08T12:26:10.000137Z

If you want to have the session stored when the user logs in via a session, you need some way of setting a cookie. I believe you could do this via an XHR, or you could grab the value of the session cookie and set it with Java/Clojurescript instead.