in reply to mod_perl - using input filters and bucket brigades to pass data to subrequests
Don't make subrequests unless you have a real reason for it, like needing to run some special auth handler that can't be called directly from perl. They have overhead and complicate things. You can easily set a specific handler or directly call some perl code without any need for subrequests. It's simpler and faster.
The way to pass data between phases or requests is $r->pnotes(). You just put the data there and then grab it in the next phase or subrequest. If you are in a subrequest, you have to ask for the parent request's record and look there for it. I think that's just $r->parent() but that's off the top of my head and could be wrong.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: mod_perl - using input filters and bucket brigades to pass data to subrequests
by walinsky (Scribe) on Mar 10, 2008 at 21:39 UTC | |
by perrin (Chancellor) on Mar 11, 2008 at 05:38 UTC |