[prev in list] [next in list] [prev in thread] [next in thread]
List: apache-modperl
Subject: Re: mod_perl , ChildInitHandler, OpenApi
From: "Randolf Richardson" <randolf () modperl ! pl>
Date: 2019-12-09 8:31:50
Message-ID: 5DEE0676.2447.25D8A4F () randolf ! modperl ! pl
[Download RAW message or body]
You can use the $r->pnotes to pass blessed Perl objects between
handlers that run at different phases:
Apache2::RequestUtil -- $r->pnotes
https://perl.apache.org/docs/2.0/api/Apache2/RequestUtil.html#C_pnotes_
(I'm assuming that you're using mod_perl2.)
> Hi,
>
> we're running our application build with mod_perl and MasonX::WebApp::ApacheHandler \
> (quite old, yes I know) Now I would like to use OpenAPI::Client to connect to some \
> other web services we need. OpenAPI::Client generates code based on the api \
> specification, but this takes 3 -4 seconds , which is far too slow to call it on \
> every request. How can I initialize the OpenAPI::Client during server startup and \
> use the compiled code later ( i.e. access the object created)? I'm thinking about \
> doing this in a ChildInitHandler, but I have no idea, where to "store" the result. \
> We're using mom_event in production, anything to consider with this ?
> Thanks
> Rolf
>
Randolf Richardson - randolf@inter-corporate.com
Inter-Corporate Computer & Network Services, Inc.
Beautiful British Columbia, Canada
https://www.inter-corporate.com/
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic