How do I get a hold of the session object in my form handler? I have build a form in D8 and on submit I want to save the form values into a session, so that I can access them 3, 4,.... page requests later.
In D7 I just used 

$_SESSION['key'] = $value


I have a feeling, in D8 and symfony, this is (very) bad practice. How should I solve this?
At the moment I'm using the following chunk of code, but I don't know if this is the correct way:

$session = new Session();
$session-&gt;set('name', 'value');

$name = $session-&gt;get('name');
The conversion to the Symfony session component is not yet complete, therefore you still have to access the session using the superglobal.

Follow https://www.drupal.org/node/1858196 and its sub-issues, if you like to stay up to date regarding this issue.