http://qs321.pair.com?node_id=11138140


in reply to When does it make sense to preload modules when starting Starman?

IMO it makes sense to preload modules if these modules take a long time to initialize and you have a good chance of sharing their data among the forked copies.

Examples I can think of are caching some (largish) resources in memory, or modules that autogenerate lots of code.

Database connections sound interesting, but usually, DBI database handles need to be reinitialized after a fork() call, so that won't work.