camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: PHP and OSGi?
Date Thu, 02 Jul 2015 14:36:51 GMT
Hi

Yeah there is only specialized camel-script-xxx features for those
that works in OSGi like ruby, javascript.

You cannot use php, or at least we have no osgi bundle of a library
that works and that we test with.

And is there any reason you cannot just use any of the other scripting
language or java.

On Tue, Jun 30, 2015 at 9:32 PM, Daniel Lamb <daniel@discoverygarden.ca> wrote:
> Hi,
>
> Has anyone out there ever successfully used PHP within camel routes running in an OSGi
container?   I keep getting the following error despite having camel-script installed: Bundle
php_test.xml is waiting for dependencies [(&(language=php)(objectClass=org.apache.camel.spi.LanguageResolver))]
>
> Is there an extra dependency for it a la camel-script-groovy or camel-script-jruby? 
Is this even possible?
>
> Google does not provide much information on the subject, though it alludes to a Quercus
OSGi bundle which appears to be an abandoned effort?
>
> Here’s the route I’m playing around with:
>
> <?xml version="1.0" encoding="UTF-8"?>
>
> <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
>            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>            xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.0.0"
>            xsi:schemaLocation="
>            http://www.osgi.org/xmlns/blueprint/v1.0.0 http://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd">
>
>   <camelContext xmlns="http://camel.apache.org/schema/blueprint">
>
>     <route>
>       <description>Tests PHP</description>
>       <from uri="timer://foo?period=1000"/>
>         <transform><language language="php">'TEST'</language></transform>
>         <log message="${body}"/>
>     </route>
>
>   </camelContext>
>
> </blueprint>
>
> ~Danny
>



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/

Mime
View raw message