Silvan Jegen: 1
client: lock mutex after calling Authenticate when uploading/downloading
1 files changed, 4 insertions(+), 0 deletions(-)
In JMAP, each request returns the state string of the session object. I've found
it to be pretty good practice to check that on every request against the session
I wasn't aware of this state string! I have read up a bit about it and
from what I understand, some of the API response objects also return
the session state, which then can be used to "... quickly determine if
the session information has changed (e.g., an account has been added or
removed), so they need to refetch the object."[0]
The documentation mentions that "If the value of any other property
on the Session object changes, this string will change.". To me this
sounds like this state shouldn't change often, since the session object
contains mostly long-lived fields (like the capabilities of the server,
for example).
object you have, and if it's different, request a new session object. In this
case, that would be to call Authenticate.
If we remove that method, the only means is to then create a *new* client. This
has *some* performance hit because the old client would have been maintaining
the connections - while a new one would have to renegotiate TLS, etc.
"Tim Culverhouse" <tim@timculverhouse.com> wrote:
"Tim Culverhouse" <tim@timculverhouse.com> wrote: