[ 
http://jira.amdatu.org/jira/browse/AMDATU-471?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12596#comment-12596
 ] 

Bram de Kruijff commented on AMDATU-471:
----------------------------------------

I think you are missing the point. 

1) The servlet spec says that the container must make sure that 
init()/destroy() is called only once during the lifetime of a servlet instance.

2) The HttpService spec honors this by what you quoted above. On register the 
HttpServcie calls init() on unregister it calls destroy(). As long as you make 
sure that you do not call register twice with the same servlet instance all is 
well.

3) Now the whiteboard pattern introduces a problem as you no longer have 
control over the register/unregister. Your servlet may get 
registered/unregistered/registered/unregistered simply because the whiteboard 
adapter gets updated or any other reason.

4) Thus if you publish a 3rd party servlet that may not be able to handle 
multiple init()/destroy() cycles there must be some way to detect and handle 
such an event allowing you to unpublished and publish a new instance.

Not saying that a DispatcherService dependency is the best solution, but it's a 
rather tricky issue..




 

                
> Remove DispatcherService marker interface
> -----------------------------------------
>
>                 Key: AMDATU-471
>                 URL: http://jira.amdatu.org/jira/browse/AMDATU-471
>             Project: Amdatu
>          Issue Type: Task
>          Components: Amdatu Web
>            Reporter: Bram de Kruijff
>            Assignee: Bram de Kruijff
>             Fix For: Sprint 4
>
>
> Remove DispatcherService marker interface
> * Do we need it (servlet/filter lifecycle)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
http://jira.amdatu.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        
_______________________________________________
Amdatu-developers mailing list
[email protected]
http://lists.amdatu.org/mailman/listinfo/amdatu-developers

Reply via email to