Pages

Sep 13, 2018

JBoss Fuse – Fuse workshop 101 – Part Five

By Christina Lin



So far we have focused on the routing capability of Fuse, which is the wire and plug that integrate different systems together.And for now let’s just put Camel aside for a second and take a look at the container our little Fuse project can run on. And some of the tools that might help you while developing.


With JBoss Fuse, you have a number of containers.



  • Standalone Camel process

  • Apache Karaf container

  • JBoss Enterprise Application Server (WildFly)


We have been running it as a single Camel process. In this workshop I want to take a look at the the OSGi container inside JBoss Fuse, which comes from the community project Apache Karaf.


OSGI break the application into multiple modules so it is easier to manage the dependency between each modules, and this nature allows it to become very lightweight without the need to load unused modules. You can make dependency base on different version. Also OSGi helps you set boundaries between modules, so you can hide packages that you don’r want to export.


Within this lightweight container, there will be something already installed for you, for example, the log module actually includes various kind of logging libraries, so you application can use without problem. Deployer that scan for new applications, and provisioning of your application via maven, files, or features… etc. It also has exposed JMX for administration and monitoring. A-MQ is bult-in in the base container, but you have a choice of removing it if needed later.



Speaking of deployment, the unit of deployment is called “Bundle”, but it is actually a “jar” file. There are several way you can deploy it onto the container, either place your bundle inside the “deploy” folder(JBoss Fuse installation folder) or you can install it by using a install command and specify the maven detail to load it into the container.


osgi:install -s mvn:org.apache.camel/camel-core/1.5.0


And after successful installation, your bundle will become a service in side this container, and this service will be visible to other service inside, and uses them if needed.



The console for the container is really powerful, here you can see the list of thing you can see via the console.



Can I use the container in my local environment for development? Yes, through the use of JBoss Developer Studio, it is very easy to debug through it’s tooling. Go the the Fuse integration perspective, it will automatically detect JBoss Fuse, and here you could simple run your code on the by container by dragging the project to the bundle folder in JBoss Fuse. And see the execution result.



This is the slide for workshop 5.



Our 5th Camel Ride is all about the Karaf container, after this lab, you should be able to run your camel application on top of it!



Here are the lab instructions.


Here are the other parts of the workshops!


Workshop part 1 – Camel basic and components

Workshop part 2 – Data Transformation

Workshop part 3 – Enterprise Integration Pattern

Workshop part 4 – Bean Registry Source::




by i88.ca via Social Marketing by I88.CA » i88.ca

QuickBooks Self-Employed

Bigger tax refunds. Better organization. Manage your deductions with QuickBooks Self-Employed .