|
|
access scoped beans from PHP Bridge
Good day-
I'm afraid this won't be possible without alot of work but here goes...
I'm using the PHP Bridge (sourceforge) product to integrate a 3rd-party PHP module into a SpringMVC-based application. It is no trouble to make the web or root application context available to PHP pages using this technology.
However, the trouble comes when resolving session- or request-scoped collaborator beans. Those scope implementations rely on servlet request data sitting in ThreadLocal stores. The problem is that the PHP Bridge implementation uses long-lived job-running threads to perform PHP interpretation and rendering. Code running in a servlet request thread submits jobs to a queue. The jobs are asynchronously picked up by the PHP jobber threads. A request thread rejoins its job by occasionally checking its status--so no relationship exists between a request thread and the jobber that performs the work.
What I'm looking for is extension points in the request and session scope mechanisms to override the store-handling for this kind of scenario.
Otherwise, I think I'd need to write a custom scope for some of our session- and request-scoped beans--a situation I'd like to avoid because of its QA impact.
TIA,
-dub |
|