Gisle Aas wrote:
In HTTP::Cache::Transparent, I override LWP::UserAgent::simple_request and set $LWP::Simple::FULL_LWP to 1 to make sure that the full LWP::UserAgent implementation is always used. I do this without actually loading LWP::Simple, since HTTP::Cache::Transparent doesn't need LWP::Simple and some users may prefer to use LWP::UserAgent instead of LWP::Simple.It is documented (barely) that the module export the variable '$ua'. A side effect of importing this variable is that this forces the full LWP::UserAgent implementation to be used, otherwise settings on the $ua object would have no effect. I want to declare this as the official interface to force this and not document either get_old or $FULL_LWP.
With your proposal of an "official interface", I have to load LWP::Simple to be able to achieve the same effect. This is not a big issue, but it will consume memory unnecessarily. Do you think I should change this in HTTP::Cache::Transparent?
/Mattias