The problem is, if I'm uploading several images one by one, some of the requests are pending for about 20 minutes and than return an empty response with crashing all session variables.
By default, as a security measure, the session key rotates every 5 minutes. The system has a recovery mechanism to recover from a just-expired key, but it can't look further back (that would defeat the purpose).
So after 10 minutes, the session key used in the ajax request is no longer valid. When the process then wants to access or update the session, it will find no session data, since the key it has is no longer valid.
So try changing the session key rotation time to 30 minutes or so, or use a different mechanism than the session.
I've already play with session key rotation, but nothing happened.
I've tried Plupload instead of Jquery Forms and the same error. It seems this error only appears in Safari (Chrome, FF, IE is okay). And I think it doesn't depend on the Session (I've omitted session variable validation).