When the user logs off, that would be expected as the Plex Media Server session is running within the logged in user session
You can use the Plex Service Wrapper solution offered by @cjmurph PMS As A Service to run Plex Media Server as a Service and that way log off would not have any impact