[ 
https://issues.apache.org/jira/browse/CAMEL-3549?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13002728#comment-13002728
 ] 

Christian Schneider commented on CAMEL-3549:
--------------------------------------------

Thanks for taking the time to review. Some comments inline

<cibsen> i wonder if a serial version uid is needed on a servlet? can you 
really serialize it and send it accross the wire?
The compiler showed a warning on this so I thought it would not hurt

<cibsen> i wonder if setServletName should be removed
The problem with the servlet name is that it is normally fed by the config 
which is set during init. I first also thought we could remove it. The problem 
is in OSGi. The Httpregistry is notified of new servlets using a service 
listener. This happens in parallel to the registration of the servlet. So the 
http registry may get the signal before the servlet name is set using the init 
method. So I also set it in the HttpRegistry.

I have fixed the other things you mentioned

> It should be possible to configure the CamelHttpTransportServlet using the 
> spring ContextLoaderListener
> -------------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-3549
>                 URL: https://issues.apache.org/jira/browse/CAMEL-3549
>             Project: Camel
>          Issue Type: Improvement
>          Components: camel-servlet
>    Affects Versions: 2.5.0
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 2.7.0
>
>         Attachments: camel-servlet-3549.patch
>
>
> The spring security example uses two different spring contexts.
> The first is pulled up using the spring ContextLoaderListener. It is used to 
> hook spring security into a filter.
> The second is pulled up by the CamelHttpTransportServlet. There is the main 
> configuration includeing the camel context.
> I think this is quite ugly and makes things more complicated than they need 
> to be. Especially if you also need the camel context outside the camel 
> servlet.
> So I propose to change the code of the Camel Servlet component to simply use 
> the spring context from the ContextLoaderListener. I can try to do the change 
> myself but would be happy for any comments why this was designed so and where 
> I have to be careful.

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to