<p>I am new to Kubernetes.</p>

<ol>
<li><p>I have seen pod automaticaĺly restart in case of failure.</p></li>
<li><p>When node failure happens, new pod regenerate to another node.</p></li>
</ol>

<p>In both cases, 
  What happens when pod gets failed in the middle of the process, (say: httpsession)? Can we provide the same session to the already logged in user.
  Please forgive if the question is irrelevant.</p>

JibinNajeeb
<p>Yes, you can use health-checks like readiness and liveness probes for your pod. No traffic will be routed to the pod till readiness check passes and pod will be restarted if liveness check fails. These checks can be added to your pod-spec. </p>

<p>And session management is not handled by k8s. It must be done by the application itself. 
Anyhow, If you want to persist some data you can use PV and PVC and bind the volume to your pod.</p>
