David,

I'm not sure how it would work with Camel without being bootstrapped through
Blueprint either. Normally it wouldn't be a big deal as it is common to just
inject OSGi services and use them in Camel just as if they were any other
Java interface.

In this particular case it is being used by a Camel component for its set
up. That probably would be OK. If you look at a Blueprint setup of the
configuration and HTTP server component, there isn't anything terribly
magical.

Having said that, I'd likely have to write it by hand as I don't control
theses Netty Camel components and Camel directly supports Blueprint and not
DS. I suspect when we get a hardened CDI that might change. PAX CDI actually
works well but evidently that isn't going to be the standard. 

For the time I'm likely going to just live with the Blueprint plus
configuration file variation of this as it comes close to what I want
without a huge amount of effort. 


        
        <bean id="configuration"
class="org.apache.camel.component.netty4.http.NettySharedHttpServerBootstrapConfiguration">
                
                <property name="port" value="8888" />
                <property name="host" value="0.0.0.0" />
                
                <property name="backlog" value="50" />
        </bean>
        
        
        <bean id="httpServer"
class="org.apache.camel.component.netty4.http.DefaultNettySharedHttpServer"
init-method="start" destroy-method="stop">
                <property name="nettyServerBootstrapConfiguration" 
ref="configuration" />
        </bean>

        
        <service ref="httpServer"
interface="org.apache.camel.component.netty4.http.NettySharedHttpServer" />



--
Sent from: http://karaf.922171.n3.nabble.com/Karaf-User-f930749.html

Reply via email to