You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by lhe <lr...@web.de> on 2008/01/10 20:42:17 UTC

SMX4 - FilePoller Example like in SMX3?

Hi,

yesterday I tried ServiceMix 4 for the first time. I downloaded the binary
and got it running.
The camel example as described didn't worked for me but I then just took the
Apache Felix tutorial and built some of the examples there. I deployed them
successfully to smx4 and they worked fine. (as expected for OSGi)

So now I am looking for some tutorial to do a simple example application
like this:

A file poller watches a folder for new files and hand them over to some
other service (I would expect an OSGi service?). 

I think such a simple example was delivered with servicemix 3. (file binding
or something like this)

Can anyone describe what I have to do for this? I suppose that something
like a file poller should be a standard citizen of the new servicemix.

Any help is welcome.

Best regargs,
Lars

-- 
View this message in context: http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14742056.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: SMX4 - FilePoller Example like in SMX3?

Posted by James Strachan <ja...@gmail.com>.
On 11/01/2008, lhe77 <la...@compart.net> wrote:
> Hi Guillaume,
>
> this clarified the situation a little.
> So the NMR subproject is used to have the standard JBI 1.0 functionality,
> right?
> But now I am a little confused what the OSGi is used for?

OSGi is used to handle the classloader /deployment mechanism; plus
ServiceMix 4 is using the OSGi registry to host NMR endpoints.

JBI 1.0 deployment units can be translated into bundles on the fly.

The big change as a user is you can avoid using JBI 1.0 deployment
units if you want - so rather than a number of SUs plus SAs to deploy
a route, you could just deploy a single OSGI bundle with the
configuration in a META-INF/spring/config.xml file

I added this to the FAQ
http://cwiki.apache.org/SMX4RUN/why-does-servicemix-use-osgi.html

-- 
James
-------
http://macstrac.blogspot.com/

Open Source Integration
http://open.iona.com

Re: SMX4 - FilePoller Example like in SMX3?

Posted by Guillaume Nodet <gn...@gmail.com>.
I will check in my local changes, but I've been able to deploy all the JBI
components from ServiceMix 3 but the WS-Notification SE (haven't really
looked why yet).
Note that the creation of the JBI component is done when the bundle is
started, but asynchronously and the process can be quite long (I'll try to
fix that later).
Also, JBI artifacts are currently not automatically started, so you'd have
to run
   jbi start servicemix-http
   jbi start servicemix-jsr181
   jbi start wsdl-first-sa

But lemme fix all this and I'll get back to you soon.

On Jan 16, 2008 9:13 AM, lhe77 <la...@compart.net> wrote:

>
> Guillaume,
>
> as I told you yesterday I tried now to run the wsdl-first example in smx4
> as
> well.
> I followed the instructions exactly (installed runtime, installed nmr,
> copied shared-compat into deploy folder, copied jsr181 and http as well as
> the wsdl-first-sa into deploy folder).
> When starting smx4 there is no special error output or something.
> When doing jbi ls the following output is what I got:
>
> jbi ls:
> Shared Libraries
> ----------------
> servicemix-shared - 3.2.1 - ServiceMix :: Shared Compat
>
> Components
> ----------
> servicemix-jsr181 - Shutdown - ServiceMix :: JSR-181 Service Engine
> servicemix-http - Shutdown - ServiceMix :: HTTP
>
> Somehow the wsdl-first-sa is not recognized. I also tried to move in all
> of
> my own bc, se and sa and only few of the sa's are recognized by the jbi ls
> comand.
>
> What could be the reason for that?
>
> Regards,
> Lars
>
>
>
>
> gnodet wrote:
> >
> > I have been able to deploy one of the example from ServiceMix 3 (the
> wsdl
> > first one) by using the latest runtime and nmr snapshots.
> > You should be able to deploy your plain JBI artifacts into the deploy
> > folder, but for them to be recognized as JBI artifacts, you need to
> > install
> > the NMR project into it.
> > You can try the instructions on the following page:
> >   http://servicemix.apache.org/nmr/1-quick-start.html
> > The missing bits on this page is how to deploy your JBI example.  You
> need
> > to copy servicemix-shared-compat, servicemix-jsr181, servicemix-http,
> > wsdl-first-sa into the deploy folder, then run the following commands:
> >    jbi start servicemix-jsr181
> >    jbi start servicemix-http
> >    jbi start wsdl-first-sa
> > The need for these three commands will be removed at some point, and
> I'll
> > try to put the needed JBI artifacts into the OBR repo so that they can
> be
> > installed automaticaly.
> >
> > On Jan 11, 2008 11:20 AM, lhe77 <la...@compart.net> wrote:
> >
> >>
> >> Now I got the camel example running.
> >> I even installed the NMR into the runtime.
> >>
> >> Now I am a little confused how to put my binding components, engines
> and
> >> service assemblies into the runtime. I copied them to the deploy folder
> >> and
> >> they are listed when I type "osgi list". (on most of my components the
> >> version info says "(null)". What's wrong there?)
> >> They are listed as active but when trying to use my composite
> >> application,
> >> nothing happens. What's the trick to get them running?
> >>
> >> Regards,
> >> Lars
> >>
> >> --
> >> View this message in context:
> >>
> http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14753142.html
> >> Sent from the ServiceMix - User mailing list archive at Nabble.com.
> >>
> >>
> >
> >
> > --
> > Cheers,
> > Guillaume Nodet
> > ------------------------
> > Blog: http://gnodet.blogspot.com/
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14873586.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/

Re: SMX4 - FilePoller Example like in SMX3?

Posted by lhe77 <la...@compart.net>.
I had a deeper look into the log and found the following:


09:07:09,782 | INFO  | FelixStartLevel  | FileSystemXmlApplicationContext  |
pport.AbstractApplicationContext  400 | Refreshing
org.apache.xbean.spring.context.FileSystemXmlApplicationContext@df8b14:
display name [xbean]; startup date [Wed Jan 16 09:07:09 CET 2008]; root of
context hierarchy
09:07:09,824 | INFO  | FelixStartLevel  | XBeanXmlBeanDefinitionReader     |
tory.xml.XmlBeanDefinitionReader  303 | Loading XML bean definitions from
file
[/home/lhe/apache-servicemix-runtime-1.0-m2-SNAPSHOT/data/jbi/43/wsdl-first-jsr181-su/xbean.xml]
09:07:12,662 | INFO  | FelixStartLevel  | FileSystemXmlApplicationContext  |
pport.AbstractApplicationContext  415 | Bean factory for application context
[org.apache.xbean.spring.context.FileSystemXmlApplicationContext@df8b14]:
org.springframework.beans.factory.support.DefaultListableBeanFactory@c360a5
09:07:12,677 | INFO  | FelixStartLevel  | DefaultListableBeanFactory       |
pport.DefaultListableBeanFactory  398 | Pre-instantiating singletons in
org.springframework.beans.factory.support.DefaultListableBeanFactory@c360a5:
defining beans [org.apache.servicemix.jsr181.Jsr181Endpoint#0]; parent:
org.apache.servicemix.common.xbean.SimpleBeanFactory@24c672
09:07:15,757 | INFO  | FelixStartLevel  | FileSystemXmlApplicationContext  |
pport.AbstractApplicationContext  822 | Closing
org.apache.xbean.spring.context.FileSystemXmlApplicationContext@df8b14:
display name [xbean]; startup date [Wed Jan 16 09:07:09 CET 2008]; root of
context hierarchy
09:07:15,758 | INFO  | FelixStartLevel  | DefaultListableBeanFactory       |
ort.DefaultSingletonBeanRegistry  340 | Destroying singletons in
org.springframework.beans.factory.support.DefaultListableBeanFactory@c360a5:
defining beans [org.apache.servicemix.jsr181.Jsr181Endpoint#0]; parent:
org.apache.servicemix.common.xbean.SimpleBeanFactory@24c672
09:07:15,779 | ERROR | FelixStartLevel  | Deployer                         |
cemix.jbi.deployer.impl.Deployer  118 | Error handling bundle event
javax.jbi.management.DeploymentException: <component-task-result
xmlns="http://java.sun.com/xml/ns/jbi/management-message">
	<component-name>Component (org.apache.servicemix.jsr181.Jsr181Component)
not yet initialized</component-name>
	<component-task-result-details>
		<task-result-details>
			<task-id>deploy</task-id>
			<task-result>FAILED</task-result>
			<message-type>ERROR</message-type>
		
<task-status-msg><msg-loc-info><loc-token/><loc-message>java.lang.NullPointerException</loc-message></msg-loc-info></task-status-msg>
			<exception-info>
				<nesting-level>1</nesting-level>
				<msg-loc-info>
					<loc-token />
					<loc-message>null</loc-message>
					<stack-trace><![CDATA[java.lang.NullPointerException
	at
org.apache.servicemix.jsr181.xfire.ServiceFactoryHelper.findServiceFactory(ServiceFactoryHelper.java:128)
	at
org.apache.servicemix.jsr181.Jsr181Endpoint.registerService(Jsr181Endpoint.java:278)
	at
org.apache.servicemix.jsr181.Jsr181Endpoint.validate(Jsr181Endpoint.java:258)
	at
org.apache.servicemix.common.AbstractDeployer.validate(AbstractDeployer.java:58)
	at
org.apache.servicemix.common.xbean.BaseXBeanDeployer.validate(BaseXBeanDeployer.java:55)
	at
org.apache.servicemix.common.xbean.AbstractXBeanDeployer.deploy(AbstractXBeanDeployer.java:96)
	at
org.apache.servicemix.common.BaseServiceUnitManager.doDeploy(BaseServiceUnitManager.java:88)
	at
org.apache.servicemix.common.BaseServiceUnitManager.deploy(BaseServiceUnitManager.java:69)
	at
org.apache.servicemix.jbi.deployer.impl.ServiceUnitImpl.deploy(ServiceUnitImpl.java:69)
	at
org.apache.servicemix.jbi.deployer.impl.Deployer.deployServiceAssembly(Deployer.java:197)
	at
org.apache.servicemix.jbi.deployer.impl.Deployer.register(Deployer.java:108)
	at
org.apache.servicemix.jbi.deployer.impl.AbstractBundleWatcher.onBundleStarted(AbstractBundleWatcher.java:79)
	at
org.apache.servicemix.jbi.deployer.impl.AbstractBundleWatcher.afterPropertiesSet(AbstractBundleWatcher.java:63)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1390)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1359)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:540)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:485)
	at java.security.AccessController.doPrivileged(Native Method)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:455)
	at
org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
	at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:169)
	at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
	at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:170)
	at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:413)
	at
org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:735)
	at
org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.completeRefresh(AbstractDelegatedExecutionApplicationContext.java:241)
	at
org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor$CompleteRefreshTask.run(DependencyWaiterApplicationContextExecutor.java:132)
	at
org.springframework.core.task.SyncTaskExecutor.execute(SyncTaskExecutor.java:49)
	at
org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor.stageTwo(DependencyWaiterApplicationContextExecutor.java:298)
	at
org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor.stageOne(DependencyWaiterApplicationContextExecutor.java:239)
	at
org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor.refresh(DependencyWaiterApplicationContextExecutor.java:158)
	at
org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.refresh(AbstractDelegatedExecutionApplicationContext.java:120)
	at
org.springframework.osgi.extender.internal.ContextLoaderListener$2.run(ContextLoaderListener.java:631)
	at
org.springframework.core.task.SyncTaskExecutor.execute(SyncTaskExecutor.java:49)
	at
org.springframework.osgi.extender.internal.ContextLoaderListener.maybeCreateApplicationContextFor(ContextLoaderListener.java:671)
	at
org.springframework.osgi.extender.internal.ContextLoaderListener$ContextBundleListener.handleEvent(ContextLoaderListener.java:180)
	at
org.springframework.osgi.extender.internal.ContextLoaderListener$BaseListener.bundleChanged(ContextLoaderListener.java:125)
	at
org.apache.felix.framework.util.EventDispatcher.invokeBundleListenerCallback(EventDispatcher.java:690)
	at
org.apache.felix.framework.util.EventDispatcher.fireEventImmediately(EventDispatcher.java:619)
	at
org.apache.felix.framework.util.EventDispatcher.fireBundleEvent(EventDispatcher.java:532)
	at org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:3558)
	at org.apache.felix.framework.Felix._startBundle(Felix.java:1586)
	at org.apache.felix.framework.Felix.startBundle(Felix.java:1514)
	at org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:1100)
	at org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:258)
	at java.lang.Thread.run(Thread.java:595)
]]></stack-trace>
				</msg-loc-info>
			</exception-info>
		</task-result-details>
	</component-task-result-details>
</component-task-result>
	at
org.apache.servicemix.common.ManagementSupport.failure(ManagementSupport.java:46)
	at
org.apache.servicemix.jsr181.Jsr181Endpoint.validate(Jsr181Endpoint.java:260)
	at
org.apache.servicemix.common.AbstractDeployer.validate(AbstractDeployer.java:58)
	at
org.apache.servicemix.common.xbean.BaseXBeanDeployer.validate(BaseXBeanDeployer.java:55)
	at
org.apache.servicemix.common.xbean.AbstractXBeanDeployer.deploy(AbstractXBeanDeployer.java:96)
	at
org.apache.servicemix.common.BaseServiceUnitManager.doDeploy(BaseServiceUnitManager.java:88)
	at
org.apache.servicemix.common.BaseServiceUnitManager.deploy(BaseServiceUnitManager.java:69)
	at
org.apache.servicemix.jbi.deployer.impl.ServiceUnitImpl.deploy(ServiceUnitImpl.java:69)
	at
org.apache.servicemix.jbi.deployer.impl.Deployer.deployServiceAssembly(Deployer.java:197)
	at
org.apache.servicemix.jbi.deployer.impl.Deployer.register(Deployer.java:108)
	at
org.apache.servicemix.jbi.deployer.impl.AbstractBundleWatcher.onBundleStarted(AbstractBundleWatcher.java:79)
	at
org.apache.servicemix.jbi.deployer.impl.AbstractBundleWatcher.afterPropertiesSet(AbstractBundleWatcher.java:63)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1390)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1359)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:540)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:485)
	at java.security.AccessController.doPrivileged(Native Method)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:455)
	at
org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
	at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:169)
	at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
	at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:170)
	at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:413)
	at
org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:735)
	at
org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.completeRefresh(AbstractDelegatedExecutionApplicationContext.java:241)
	at
org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor$CompleteRefreshTask.run(DependencyWaiterApplicationContextExecutor.java:132)
	at
org.springframework.core.task.SyncTaskExecutor.execute(SyncTaskExecutor.java:49)
	at
org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor.stageTwo(DependencyWaiterApplicationContextExecutor.java:298)
	at
org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor.stageOne(DependencyWaiterApplicationContextExecutor.java:239)
	at
org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor.refresh(DependencyWaiterApplicationContextExecutor.java:158)
	at
org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.refresh(AbstractDelegatedExecutionApplicationContext.java:120)
	at
org.springframework.osgi.extender.internal.ContextLoaderListener$2.run(ContextLoaderListener.java:631)
	at
org.springframework.core.task.SyncTaskExecutor.execute(SyncTaskExecutor.java:49)
	at
org.springframework.osgi.extender.internal.ContextLoaderListener.maybeCreateApplicationContextFor(ContextLoaderListener.java:671)
	at
org.springframework.osgi.extender.internal.ContextLoaderListener$ContextBundleListener.handleEvent(ContextLoaderListener.java:180)
	at
org.springframework.osgi.extender.internal.ContextLoaderListener$BaseListener.bundleChanged(ContextLoaderListener.java:125)
	at
org.apache.felix.framework.util.EventDispatcher.invokeBundleListenerCallback(EventDispatcher.java:690)
	at
org.apache.felix.framework.util.EventDispatcher.fireEventImmediately(EventDispatcher.java:619)
	at
org.apache.felix.framework.util.EventDispatcher.fireBundleEvent(EventDispatcher.java:532)
	at org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:3558)
	at org.apache.felix.framework.Felix._startBundle(Felix.java:1586)
	at org.apache.felix.framework.Felix.startBundle(Felix.java:1514)
	at org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:1100)
	at org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:258)
	at java.lang.Thread.run(Thread.java:595)


Anyway I can't find a solution myself. Maybe this helps to analyze the
problem.

Lars





lhe77 wrote:
> 
> Guillaume,
> 
> as I told you yesterday I tried now to run the wsdl-first example in smx4
> as well.
> I followed the instructions exactly (installed runtime, installed nmr,
> copied shared-compat into deploy folder, copied jsr181 and http as well as
> the wsdl-first-sa into deploy folder).
> When starting smx4 there is no special error output or something.
> When doing jbi ls the following output is what I got:
> 
> jbi ls:
> Shared Libraries
> ----------------
> servicemix-shared - 3.2.1 - ServiceMix :: Shared Compat
> 
> Components
> ----------
> servicemix-jsr181 - Shutdown - ServiceMix :: JSR-181 Service Engine
> servicemix-http - Shutdown - ServiceMix :: HTTP
> 
> Somehow the wsdl-first-sa is not recognized. I also tried to move in all
> of my own bc, se and sa and only few of the sa's are recognized by the jbi
> ls comand.
> 
> What could be the reason for that?
> 
> Regards,
> Lars
> 
> 
> 
> 
> gnodet wrote:
>> 
>> I have been able to deploy one of the example from ServiceMix 3 (the wsdl
>> first one) by using the latest runtime and nmr snapshots.
>> You should be able to deploy your plain JBI artifacts into the deploy
>> folder, but for them to be recognized as JBI artifacts, you need to
>> install
>> the NMR project into it.
>> You can try the instructions on the following page:
>>   http://servicemix.apache.org/nmr/1-quick-start.html
>> The missing bits on this page is how to deploy your JBI example.  You
>> need
>> to copy servicemix-shared-compat, servicemix-jsr181, servicemix-http,
>> wsdl-first-sa into the deploy folder, then run the following commands:
>>    jbi start servicemix-jsr181
>>    jbi start servicemix-http
>>    jbi start wsdl-first-sa
>> The need for these three commands will be removed at some point, and I'll
>> try to put the needed JBI artifacts into the OBR repo so that they can be
>> installed automaticaly.
>> 
>> On Jan 11, 2008 11:20 AM, lhe77 <la...@compart.net> wrote:
>> 
>>>
>>> Now I got the camel example running.
>>> I even installed the NMR into the runtime.
>>>
>>> Now I am a little confused how to put my binding components, engines and
>>> service assemblies into the runtime. I copied them to the deploy folder
>>> and
>>> they are listed when I type "osgi list". (on most of my components the
>>> version info says "(null)". What's wrong there?)
>>> They are listed as active but when trying to use my composite
>>> application,
>>> nothing happens. What's the trick to get them running?
>>>
>>> Regards,
>>> Lars
>>>
>>> --
>>> View this message in context:
>>> http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14753142.html
>>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>>
>>>
>> 
>> 
>> -- 
>> Cheers,
>> Guillaume Nodet
>> ------------------------
>> Blog: http://gnodet.blogspot.com/
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14873717.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: SMX4 - FilePoller Example like in SMX3?

Posted by lhe77 <la...@compart.net>.
Guillaume,

as I told you yesterday I tried now to run the wsdl-first example in smx4 as
well.
I followed the instructions exactly (installed runtime, installed nmr,
copied shared-compat into deploy folder, copied jsr181 and http as well as
the wsdl-first-sa into deploy folder).
When starting smx4 there is no special error output or something.
When doing jbi ls the following output is what I got:

jbi ls:
Shared Libraries
----------------
servicemix-shared - 3.2.1 - ServiceMix :: Shared Compat

Components
----------
servicemix-jsr181 - Shutdown - ServiceMix :: JSR-181 Service Engine
servicemix-http - Shutdown - ServiceMix :: HTTP

Somehow the wsdl-first-sa is not recognized. I also tried to move in all of
my own bc, se and sa and only few of the sa's are recognized by the jbi ls
comand.

What could be the reason for that?

Regards,
Lars




gnodet wrote:
> 
> I have been able to deploy one of the example from ServiceMix 3 (the wsdl
> first one) by using the latest runtime and nmr snapshots.
> You should be able to deploy your plain JBI artifacts into the deploy
> folder, but for them to be recognized as JBI artifacts, you need to
> install
> the NMR project into it.
> You can try the instructions on the following page:
>   http://servicemix.apache.org/nmr/1-quick-start.html
> The missing bits on this page is how to deploy your JBI example.  You need
> to copy servicemix-shared-compat, servicemix-jsr181, servicemix-http,
> wsdl-first-sa into the deploy folder, then run the following commands:
>    jbi start servicemix-jsr181
>    jbi start servicemix-http
>    jbi start wsdl-first-sa
> The need for these three commands will be removed at some point, and I'll
> try to put the needed JBI artifacts into the OBR repo so that they can be
> installed automaticaly.
> 
> On Jan 11, 2008 11:20 AM, lhe77 <la...@compart.net> wrote:
> 
>>
>> Now I got the camel example running.
>> I even installed the NMR into the runtime.
>>
>> Now I am a little confused how to put my binding components, engines and
>> service assemblies into the runtime. I copied them to the deploy folder
>> and
>> they are listed when I type "osgi list". (on most of my components the
>> version info says "(null)". What's wrong there?)
>> They are listed as active but when trying to use my composite
>> application,
>> nothing happens. What's the trick to get them running?
>>
>> Regards,
>> Lars
>>
>> --
>> View this message in context:
>> http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14753142.html
>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>
>>
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
> 
> 

-- 
View this message in context: http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14873586.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: SMX4 - FilePoller Example like in SMX3?

Posted by Guillaume Nodet <gn...@gmail.com>.
I have been able to deploy one of the example from ServiceMix 3 (the wsdl
first one) by using the latest runtime and nmr snapshots.
You should be able to deploy your plain JBI artifacts into the deploy
folder, but for them to be recognized as JBI artifacts, you need to install
the NMR project into it.
You can try the instructions on the following page:
  http://servicemix.apache.org/nmr/1-quick-start.html
The missing bits on this page is how to deploy your JBI example.  You need
to copy servicemix-shared-compat, servicemix-jsr181, servicemix-http,
wsdl-first-sa into the deploy folder, then run the following commands:
   jbi start servicemix-jsr181
   jbi start servicemix-http
   jbi start wsdl-first-sa
The need for these three commands will be removed at some point, and I'll
try to put the needed JBI artifacts into the OBR repo so that they can be
installed automaticaly.

On Jan 11, 2008 11:20 AM, lhe77 <la...@compart.net> wrote:

>
> Now I got the camel example running.
> I even installed the NMR into the runtime.
>
> Now I am a little confused how to put my binding components, engines and
> service assemblies into the runtime. I copied them to the deploy folder
> and
> they are listed when I type "osgi list". (on most of my components the
> version info says "(null)". What's wrong there?)
> They are listed as active but when trying to use my composite application,
> nothing happens. What's the trick to get them running?
>
> Regards,
> Lars
>
> --
> View this message in context:
> http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14753142.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/

Re: SMX4 - FilePoller Example like in SMX3?

Posted by lhe77 <la...@compart.net>.
Jeff,

thank you for the information. I'll keep an eye on it.

Regards 
Lars



Jeff Yu wrote:
> 
> Currently, the NMR/JBI hasn't finished it yet... please refer to
> http://issues.apache.org/activemq/browse/SMX4RUN &
> http://issues.apache.org/activemq/browse/SMX4NMR to see those JIRA task.
> 
> 
> On Jan 11, 2008 6:20 PM, lhe77 <la...@compart.net> wrote:
> 
>>
>> Now I got the camel example running.
>> I even installed the NMR into the runtime.
>>
>> Now I am a little confused how to put my binding components, engines and
>> service assemblies into the runtime. I copied them to the deploy folder
>> and
>> they are listed when I type "osgi list". (on most of my components the
>> version info says "(null)". What's wrong there?)
>> They are listed as active but when trying to use my composite
>> application,
>> nothing happens. What's the trick to get them running?
>>
>> Regards,
>> Lars
>>
>> --
>> View this message in context:
>> http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14753142.html
>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>
>>
> 
> 
> -- 
> Thanks
> Jeff
> 
> 

-- 
View this message in context: http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14754998.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: SMX4 - FilePoller Example like in SMX3?

Posted by Jeff Yu <je...@gmail.com>.
Currently, the NMR/JBI hasn't finished it yet... please refer to
http://issues.apache.org/activemq/browse/SMX4RUN &
http://issues.apache.org/activemq/browse/SMX4NMR to see those JIRA task.


On Jan 11, 2008 6:20 PM, lhe77 <la...@compart.net> wrote:

>
> Now I got the camel example running.
> I even installed the NMR into the runtime.
>
> Now I am a little confused how to put my binding components, engines and
> service assemblies into the runtime. I copied them to the deploy folder
> and
> they are listed when I type "osgi list". (on most of my components the
> version info says "(null)". What's wrong there?)
> They are listed as active but when trying to use my composite application,
> nothing happens. What's the trick to get them running?
>
> Regards,
> Lars
>
> --
> View this message in context:
> http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14753142.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>


-- 
Thanks
Jeff

Re: Writing a ServiceMix component

Posted by Andrea Zoppello <zo...@tiscali.it>.
Hi,

If you're interested, you could look at spagic-project here:

http://forge.objectweb.org/projects/spagic
http://spagic.org

it will provide an advanced jdbc component ( It's implemented as a 
lightweight lw component ) where you could:

1) Execute sql statements or call stored procedure

2) Map each parameters of an input normalizad message to your query, 
stored procedure, with xpath
extraction rules.

Andrea


marco.mistroni@uk.bnpparibas.com ha scritto:
> hello all,
>  
>         i need to write an application in which i need to listens to , 
> let's say, 10 queues for incoming messages.
> This message will be parsed , resulting in a set of SQL statements that 
> need to be inserted into the database.
> I looked at ServiceMix as a possible solution for that (instead of having 
> a set of n threads sitting there and waiting to receive messages)..
>
>
> Now, forgetting about fault tolerance and doing the easy way, i figured 
> out i'll need @least a component that listens to a queue and one that 
> insert data into the database.
>
> I had a look at existing components, and i was able to find the one that 
> listens to queue but not one for inserting database.... 
>
> So, unless someone knows of an existing one.. i think i'll have to write 
> my own.......
>
> anyone could comment?
>
>
> thanks and regards
>          marco
>
>
> This communication is confidential, may be privileged and is meant only for the intended recipient.  If you are 
> not the intended recipient, please notify the sender by reply and delete this message from your system.  Any 
> unauthorised dissemination, distribution or copying hereof is prohibited.
>
> BNP Paribas Fund Services UK Limited, BNP Paribas Trust Corporation UK Limited, BNP Paribas UK Limited, 
> BNP Paribas Commodity Futures Ltd and Investment Fund Services Limited are authorised and regulated by 
> the Financial Services Authority.
>
> BNP Paribas, BNP Paribas Securities Services and BNP Paribas Private Bank are authorised by the CECEI 
> and AMF.  BNP Paribas London Branch, BNP Paribas Securities Services London Branch and BNP Paribas 
> Private Bank London Branch are regulated by the Financial Services Authority for the conduct of their UK 
> business.  BNP Paribas Securities Services London Branch is also a member of the London Stock Exchange.
>
>
>   


Re: Writing a ServiceMix component

Posted by ilango <il...@yahoo.com>.
Interesting, because I am working on similar lines. Have you got something working so far. I could brainstorm myself and come up with ideas?
   
  Do you wish to share what you have done so far?

marco.mistroni@uk.bnpparibas.com wrote:
  hello all,

i need to write an application in which i need to listens to , 
let's say, 10 queues for incoming messages.
This message will be parsed , resulting in a set of SQL statements that 
need to be inserted into the database.
I looked at ServiceMix as a possible solution for that (instead of having 
a set of n threads sitting there and waiting to receive messages)..


Now, forgetting about fault tolerance and doing the easy way, i figured 
out i'll need @least a component that listens to a queue and one that 
insert data into the database.

I had a look at existing components, and i was able to find the one that 
listens to queue but not one for inserting database.... 

So, unless someone knows of an existing one.. i think i'll have to write 
my own.......

anyone could comment?


thanks and regards
marco


This communication is confidential, may be privileged and is meant only for the intended recipient. If you are 
not the intended recipient, please notify the sender by reply and delete this message from your system. Any 
unauthorised dissemination, distribution or copying hereof is prohibited.

BNP Paribas Fund Services UK Limited, BNP Paribas Trust Corporation UK Limited, BNP Paribas UK Limited, 
BNP Paribas Commodity Futures Ltd and Investment Fund Services Limited are authorised and regulated by 
the Financial Services Authority.

BNP Paribas, BNP Paribas Securities Services and BNP Paribas Private Bank are authorised by the CECEI 
and AMF. BNP Paribas London Branch, BNP Paribas Securities Services London Branch and BNP Paribas 
Private Bank London Branch are regulated by the Financial Services Authority for the conduct of their UK 
business. BNP Paribas Securities Services London Branch is also a member of the London Stock Exchange.






       
---------------------------------
Never miss a thing.   Make Yahoo your homepage.

Writing a ServiceMix component

Posted by ma...@uk.bnpparibas.com.
hello all,
 
        i need to write an application in which i need to listens to , 
let's say, 10 queues for incoming messages.
This message will be parsed , resulting in a set of SQL statements that 
need to be inserted into the database.
I looked at ServiceMix as a possible solution for that (instead of having 
a set of n threads sitting there and waiting to receive messages)..


Now, forgetting about fault tolerance and doing the easy way, i figured 
out i'll need @least a component that listens to a queue and one that 
insert data into the database.

I had a look at existing components, and i was able to find the one that 
listens to queue but not one for inserting database.... 

So, unless someone knows of an existing one.. i think i'll have to write 
my own.......

anyone could comment?


thanks and regards
         marco


This communication is confidential, may be privileged and is meant only for the intended recipient.  If you are 
not the intended recipient, please notify the sender by reply and delete this message from your system.  Any 
unauthorised dissemination, distribution or copying hereof is prohibited.

BNP Paribas Fund Services UK Limited, BNP Paribas Trust Corporation UK Limited, BNP Paribas UK Limited, 
BNP Paribas Commodity Futures Ltd and Investment Fund Services Limited are authorised and regulated by 
the Financial Services Authority.

BNP Paribas, BNP Paribas Securities Services and BNP Paribas Private Bank are authorised by the CECEI 
and AMF.  BNP Paribas London Branch, BNP Paribas Securities Services London Branch and BNP Paribas 
Private Bank London Branch are regulated by the Financial Services Authority for the conduct of their UK 
business.  BNP Paribas Securities Services London Branch is also a member of the London Stock Exchange.


Re: SMX4 - FilePoller Example like in SMX3?

Posted by lhe77 <la...@compart.net>.
Now I got the camel example running. 
I even installed the NMR into the runtime.

Now I am a little confused how to put my binding components, engines and
service assemblies into the runtime. I copied them to the deploy folder and
they are listed when I type "osgi list". (on most of my components the
version info says "(null)". What's wrong there?)
They are listed as active but when trying to use my composite application,
nothing happens. What's the trick to get them running?

Regards,
Lars

-- 
View this message in context: http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14753142.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: SMX4 - FilePoller Example like in SMX3?

Posted by lhe77 <la...@compart.net>.
Hi Guillaume,

this clarified the situation a little.
So the NMR subproject is used to have the standard JBI 1.0 functionality,
right?
But now I am a little confused what the OSGi is used for? 
The standard integrator or component developer (I read that there will be no
components any longer, just Endpoints) will never write raw OSGi services?

Just a little example:
If I am going to write a component that receives IPP and LPR print jobs and
puts the jobs to the jbi bus. How would this be done in the new smx? Still
by writing a binding component or do I write an OSGi service for this? If
OSGi, how do I put the jobs on the bus?

I know, a lot of questions...I am still a little confused.
Anyway, I will try the camel example now again ;)

Regards,
Lars




gnodet wrote:
> 
> On Jan 11, 2008 1:01 AM, Guillaume Nodet <gn...@gmail.com> wrote:
> 
>> Hi Lars !
>>
>> On Jan 10, 2008 8:42 PM, lhe <lr...@web.de> wrote:
>>
>> >
>> > Hi,
>> >
>> > yesterday I tried ServiceMix 4 for the first time. I downloaded the
>> > binary
>> > and got it running.
>> > The camel example as described didn't worked for me but I then just
>> took
>> > the
>> > Apache Felix tutorial and built some of the examples there. I deployed
>> > them
>> > successfully to smx4 and they worked fine. (as expected for OSGi)
>>
>>
>> I will update the page to make sure the camel example works.
>>
> 
> Snapshots are being deployed, so please try again in one hour or so.
> 
> 
>>
>>
>>
>> >
>> >
>> > So now I am looking for some tutorial to do a simple example
>> application
>> > like this:
>> >
>> > A file poller watches a folder for new files and hand them over to some
>> > other service (I would expect an OSGi service?).
>>
>>
>> Not an OSGi service directly.  I mean, it will be a ServiceMix endpoint,
>> and such endpoints are registered as OSGi services, but you won't be able
>> to
>> use any existing OSGi service for that.
>>
>>
>> >
>> >
>> > I think such a simple example was delivered with servicemix 3. (file
>> > binding
>> > or something like this)
>> >
>> > Can anyone describe what I have to do for this? I suppose that
>> something
>> > like a file poller should be a standard citizen of the new servicemix.
>>
>>
>> Sure.  The confusion may come from the fact that i think you have
>> downloaded and tested ServiceMix Runtime, which is not a bus in any way.
>> This will be provided by ServiceMix NMR (see
>> http://servicemix.apache.org/runtime/faq.html).
>> The ServiceMix NMR will provide a JBI 1.0 container so that you'll be
>> able
>> to deploy any JBI compliant application.  Another way will be to deploy a
>> simple camel route inside the runtime, as camel is now composed of OSGi
>> bundles.
>> Such an example may be part of the ServiceMix NMR or of the camel
>> integration for ServiceMix 4.
>>
>> Does that make sense ?
>>
>>
>> >
>> >
>> > Any help is welcome.
>> >
>> > Best regargs,
>> > Lars
>> >
>> > --
>> > View this message in context:
>> >
>> http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14742056.html
>> > Sent from the ServiceMix - User mailing list archive at Nabble.com.
>> >
>> >
>>
>>
>> --
>> Cheers,
>> Guillaume Nodet
>> ------------------------
>> Blog: http://gnodet.blogspot.com/
> 
> 
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
> 
> 

-- 
View this message in context: http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14750582.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: SMX4 - FilePoller Example like in SMX3?

Posted by Guillaume Nodet <gn...@gmail.com>.
On Jan 11, 2008 1:01 AM, Guillaume Nodet <gn...@gmail.com> wrote:

> Hi Lars !
>
> On Jan 10, 2008 8:42 PM, lhe <lr...@web.de> wrote:
>
> >
> > Hi,
> >
> > yesterday I tried ServiceMix 4 for the first time. I downloaded the
> > binary
> > and got it running.
> > The camel example as described didn't worked for me but I then just took
> > the
> > Apache Felix tutorial and built some of the examples there. I deployed
> > them
> > successfully to smx4 and they worked fine. (as expected for OSGi)
>
>
> I will update the page to make sure the camel example works.
>

Snapshots are being deployed, so please try again in one hour or so.


>
>
>
> >
> >
> > So now I am looking for some tutorial to do a simple example application
> > like this:
> >
> > A file poller watches a folder for new files and hand them over to some
> > other service (I would expect an OSGi service?).
>
>
> Not an OSGi service directly.  I mean, it will be a ServiceMix endpoint,
> and such endpoints are registered as OSGi services, but you won't be able to
> use any existing OSGi service for that.
>
>
> >
> >
> > I think such a simple example was delivered with servicemix 3. (file
> > binding
> > or something like this)
> >
> > Can anyone describe what I have to do for this? I suppose that something
> > like a file poller should be a standard citizen of the new servicemix.
>
>
> Sure.  The confusion may come from the fact that i think you have
> downloaded and tested ServiceMix Runtime, which is not a bus in any way.
> This will be provided by ServiceMix NMR (see
> http://servicemix.apache.org/runtime/faq.html).
> The ServiceMix NMR will provide a JBI 1.0 container so that you'll be able
> to deploy any JBI compliant application.  Another way will be to deploy a
> simple camel route inside the runtime, as camel is now composed of OSGi
> bundles.
> Such an example may be part of the ServiceMix NMR or of the camel
> integration for ServiceMix 4.
>
> Does that make sense ?
>
>
> >
> >
> > Any help is welcome.
> >
> > Best regargs,
> > Lars
> >
> > --
> > View this message in context:
> > http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14742056.html
> > Sent from the ServiceMix - User mailing list archive at Nabble.com.
> >
> >
>
>
> --
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/




-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/

Re: SMX4 - FilePoller Example like in SMX3?

Posted by Guillaume Nodet <gn...@gmail.com>.
Hi Lars !

On Jan 10, 2008 8:42 PM, lhe <lr...@web.de> wrote:

>
> Hi,
>
> yesterday I tried ServiceMix 4 for the first time. I downloaded the binary
> and got it running.
> The camel example as described didn't worked for me but I then just took
> the
> Apache Felix tutorial and built some of the examples there. I deployed
> them
> successfully to smx4 and they worked fine. (as expected for OSGi)


I will update the page to make sure the camel example works.


>
>
> So now I am looking for some tutorial to do a simple example application
> like this:
>
> A file poller watches a folder for new files and hand them over to some
> other service (I would expect an OSGi service?).


Not an OSGi service directly.  I mean, it will be a ServiceMix endpoint, and
such endpoints are registered as OSGi services, but you won't be able to use
any existing OSGi service for that.


>
>
> I think such a simple example was delivered with servicemix 3. (file
> binding
> or something like this)
>
> Can anyone describe what I have to do for this? I suppose that something
> like a file poller should be a standard citizen of the new servicemix.


Sure.  The confusion may come from the fact that i think you have downloaded
and tested ServiceMix Runtime, which is not a bus in any way.  This will be
provided by ServiceMix NMR (see
http://servicemix.apache.org/runtime/faq.html).
The ServiceMix NMR will provide a JBI 1.0 container so that you'll be able
to deploy any JBI compliant application.  Another way will be to deploy a
simple camel route inside the runtime, as camel is now composed of OSGi
bundles.
Such an example may be part of the ServiceMix NMR or of the camel
integration for ServiceMix 4.

Does that make sense ?


>
>
> Any help is welcome.
>
> Best regargs,
> Lars
>
> --
> View this message in context:
> http://www.nabble.com/SMX4---FilePoller-Example-like-in-SMX3--tp14742056s12049p14742056.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/