I have asked this in a few places but did not get any answers and I am hoping to find understanding from the wise monks here.
I have a perl web application (CGI::Application with ModPerl::Registry) which connects to a authenticated custom server over a socket and exchanges data (command/response) with it. Currently the web application connects to the server, authenticates and disconnects on every page request - even for the same user.
Is there some way I can use the same socket over multiple page requests which share a common session id? Creating a separate daemon that proxies connections and makes them persistent, is an option I am exploring, but would like to know if there are any simpler solutions. I have no control over the design of the custom server unfortunately, so modifying that is not currently an option. However moving to another web framework like Dancer, if that supports what I want to achieve, is definitely an option