perl - Dynamic package loading under plackup with Starman -



perl - Dynamic package loading under plackup with Starman -

i running web app under plackup starman , trying dynamically load , instantiate packages based on user requests. using 'require $packagename;' load bundle $packagename contains name of package, names stored in config file. execute known set of commands on instance classes inherit base of operations class , contain set of known methods.

this works fine under apache, reason plackup saying cannot locate bundle though @inc contains library path , bundle names absolute lastly directory in lib path. is, bundle name base::my::package.

anyone experience issue? need update other path within starman? executing plackup -i flag updating environment perl5lib variable. tried 'use lib /...' in main app class, none of these work.

thanks

require take module names (e.g. scalar::util) when they're specified barewords. if give require string, needs relative path module (e.g. scalar/util.pm). can around doing require within eval (the string-parameter form of eval), e.g. eval "require $package".

see check list of module installed in machine

perl psgi starman

Comments

Popular posts from this blog

delphi - blogger via idHTTP : error 400 bad request -

c++ - compiler errors when initializing EXPECT_CALL with function which has program_options::variables_map as parameter -

How do I check if an insert was successful with MySQLdb in Python? -