[
https://issues.apache.org/jira/browse/DEFT-142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13070119#comment-13070119
]
Johnathan Meehan edited comment on DEFT-142 at 7/24/11 8:38 AM:
----------------------------------------------------------------
Do you mind attach the current reflection patch?
- The unit tests are broken, but execution skipping these should be okay. To
keep things simple I assumed (and created as needed) public access to the
implementation.
Regarding clone: I guess that means that we will have the clone method abstract
in the RequestHandler class (to make it "easier" for third parties)? Like:
protected abstract Object clone() throws CloneNotSupportedException;
- Sure, with a call to clone inside. I wonder if most implementations would
even care to override this.
One different approach is to let the concrete RequestHandlers be, and use the
fact that HttpRequest is unique for each request and providoe something similar
to HttpSessions. Thoughts? (pros: less impact to existing code)
- I'll need to think about that before I comment.
was (Author: jmeehan):
The unit tests are broken, but execution skipping these should be okay.
> Dynamic creation of RequestHandlers
> -----------------------------------
>
> Key: DEFT-142
> URL: https://issues.apache.org/jira/browse/DEFT-142
> Project: Deft
> Issue Type: New Feature
> Assignee: Johnathan Meehan
> Attachments: deft_142_reflection.patch
>
>
> The outcome after a discussion with github.com/inferno-:
> (In the current design) it's volatile to have fields in user defined
> RequestHandlers in conjunction with asynchronous calls. (intermediate request
> (to same RH) could change the state of the RH)
> We should investigate the performance impact for dynamic creation of RH.
> Proposed solution:
> 1, Map<String, RequestHandler> => Map<String, Class<RequestHandler>>
> 2, Application.getHandler should create the appropriate RequestHandler using
> reflection.
> 3, UT / benchmark
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira