title: Get JSESSIONID in Angular applications
body: <p>hope you can help me with this. </p>
  
  <p>I am developing an application using Angular 8, that calls some Java REST Services (not a Spring backend, the services are written using only Jersey). When developing backend services, i used Postman app to test them, and this took me to an error: it seems that Postman automatically manages JSESSIONID, so when i try to call my service in Angular application, i realised that i have to do it manually. </p>
  
  <p>The real question is, how to manage that ID in Angular? When i call my first service, a login service, in "Network" session of Chrome console i can see in response's headers the field:</p>
  
  <pre><code>Set-Cookie: JSESSIONID=averylongstring
  </code></pre>
  
  <p>I tried, following different other questions, to get it with</p>
  
  <pre><code>response.headers.get('Set-Cookie')
  </code></pre>
  
  <p>but it returns null. If i write</p>
  
  <pre><code>console.log(response.headers)
  </code></pre>
  
  <p>in .subscribe method, i can't see any relevant header, picture is following: </p>
  
  <p><a href="https://i.stack.imgur.com/tSaoY.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/tSaoY.png" alt="enter image description here"></a></p>
  
  <p>How can I access to that id? Is an error in Angular response handling or in service? I tried to return first a custom serializable bean and then a javax.ws.rs.core.Response object, hoping to fix, but i get the same situation.</p>