Erik,

In theory, JBI was built for this: being able to use components from different vendors together to build/integrate services. The source code for the Spagic components is also available on-line.

On the other hand, if you want to avoid bringing in additional components, it's perfectly fine to use your JSR-181 webmethod to access the database. A POJO with JSR-181 annotations is available as a service on the ESB, so you can always integrate it with other transports/technologies if you need to. ServiceMix already has a fair amount of JBI components and the list is growing with every release, providing you with the flexibility that is required in business application nowadays.


Gert

Erik Allais wrote:
Gert,

My first idea was to add the necessary code to access the DB directly in my
JSR-181 webmethod
But i wonder if there is another way to do that...
The JDBC component from spagic is great but i fear to use something that
will not (maybe) work in the future...
Regards,
Erik


Gert Vanthienen wrote:
Erik,

Is your message flow something like...
    HTTP/SOAP  ->   JSR-181 SU   -->  RDBMS

If so, wouldn't it be an option to add the necessary code to access the DB right there in your JSR-181 webmethod?


Gert

Erik Allais wrote:
Gert,

Can i use the logic implemented inside the servicemix-bean SU in my
webmethod (jsr-181)
My webservice must send query to my database

Regards,
Erik


Gert Vanthienen wrote:
Erik,


If you just want to create a SA that is able to access a database with JDBC, you can consider the use of a servicemix-bean SU, in which you can just write Java code to handle a message exchange (using JDBC or whatever Java technology you want). This would probably be the easiest solution for you.

You could also write your own JDBC SE, to add JDBC functionality to the JBI container and afterwards build a SA that targets this new SE. There is a tutorial on writing these on http://incubator.apache.org/servicemix/hello-world-se.html, but be sure to check out http://incubator.apache.org/servicemix/should-i-create-my-own-jbi-components.html first. BTW, this would be a very welcome addition to ServiceMix, so any contributions would be appreciated...


Gert



Erik Allais wrote:
hi,
Where can i find some tutorial to make my own SA with jdbc support?

Regards,
Erik


Andrea Zoppello-2 wrote:
Yes right,

But this is referred to the JDBC Poller Binding component. If you need the service engine you must take the file spagic-advanced-jdbc-1.0.0-RC1.jar under SMX_HOME/lib/optional.

Andrea Zoppello
Erik Allais ha scritto:
Andrea Zoppello-2 wrote:
Here the instructions:

- For the JDBC poller just download
spagic-service-manager1.0.0-RC1.zip <http://forge.objectweb.org/project/download.php?group_id=298&file_id=8566> and unzip it the jdbcpoller is in
   /SMX_HOME/install/servicemix-jdbc-3.1-incubating-installer.zip


Do you mean spagic-jdbc-1.0.0-RC1-incubating-installer.zip file?



Reply via email to