Hi JB,

I'm using Karaf 4.2.7 w/ Camel 3.0.1

Best
Gerald

> Jean-Baptiste Onofre <j...@nanthrax.net> hat am 5. April 2020 06:58 
> geschrieben:
> 
>  
> Hi
> 
> I guess the documentation is not aligned with jetty version actually used. 
> You are using Karaf 4.2.8 ?
> 
> Camel jetty feature uses the jetty version provided by pax-web/karaf, so the 
> documentation is not maybe correct for 9.4.22/27.
> 
> Regards 
> JB
> 
> > Le 4 avr. 2020 à 10:08, Gerald Kallas <catsh...@mailbox.org> a écrit :
> > 
> > Dear community,
> > 
> > I've configured a route as following snippet (following the documentation 
> > https://camel.apache.org/components/latest/jetty-component.html)
> > 
> > <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0";
> >     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> >     xsi:schemaLocation="http://www.osgi.org/xmlns/blueprint/v1.0.0
> >     https://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd";
> >     
> > xmlns:ext="http://aries.apache.org/blueprint/xmlns/blueprint-ext/v1.0.0";>
> > 
> >     <bean id="constraint" 
> > class="org.eclipse.jetty.http.security.Constraint">
> >             <property name="name" value="BASIC"/>
> >             <property name="roles" value="admin"/>
> >             <property name="authenticate" value="true"/>
> >     </bean>
> > 
> >     <bean id="constraintMapping" 
> > class="org.eclipse.jetty.security.ConstraintMapping">
> >             <property name="constraint" ref="constraint"/>
> >             <property name="pathSpec" value="/*"/>
> >     </bean>
> > 
> >     <bean id="securityHandler" 
> > class="org.eclipse.jetty.security.ConstraintSecurityHandler">
> >             <property name="authenticator">
> >                     <bean 
> > class="org.eclipse.jetty.security.authentication.BasicAuthenticator"/>
> >             </property>
> >             <property name="constraintMappings">
> >                     <list>
> >                             <ref bean="constraintMapping"/>
> >                     </list>
> >             </property>
> >     </bean>
> > 
> >     <camelContext id="WEBISP001" 
> > xmlns="http://camel.apache.org/schema/blueprint?handlers=securityHandler";>
> > 
> >             <route id="WEBISP001">
> >                     <from uri="jetty:http://0.0.0.0:8182/hello"; />
> >                     <log message="hello request body: ${in.body}" />
> >             </route>
> > 
> >     </camelContext>
> > </blueprint>
> > 
> > First of all I got
> > 
> > Unresolved requirements: [[WEBISP001.xml [264](R 264.12)] 
> > osgi.wiring.package; (osgi.wiring.package=org.eclipse.jetty.http.security)]
> > 
> > Seems also that the construct
> > 
> >             <property name="constraintMappings">
> >                     <list>
> >                             <ref bean="constraintMapping"/>
> >                     </list>
> >             </property>
> > 
> > is wrong and has been changed from the syntax part.
> > 
> > Could someone post a valid example for this? And .. how to resolve the 
> > missing bundle?
> > 
> > Thanks in advance
> > Gerald

Reply via email to