DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
Refcards Trend Reports Events Over 2 million developers have joined DZone. Join Today! Thanks for visiting DZone today,
Edit Profile Manage Email Subscriptions Moderation Admin Console How to Post to DZone Article Submission Guidelines
View Profile
Sign Out
Refcards
Trend Reports
Events
Zones
Culture and Methodologies Agile Career Development Methodologies Team Management
Data Engineering AI/ML Big Data Data Databases IoT
Software Design and Architecture Cloud Architecture Containers Integration Microservices Performance Security
Coding Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Partner Zones AWS Cloud
by AWS Developer Relations
Culture and Methodologies
Agile Career Development Methodologies Team Management
Data Engineering
AI/ML Big Data Data Databases IoT
Software Design and Architecture
Cloud Architecture Containers Integration Microservices Performance Security
Coding
Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance
Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Partner Zones
AWS Cloud
by AWS Developer Relations
Building Scalable Real-Time Apps with AstraDB and Vaadin
Register Now

Trending

  • Extending Java APIs: Add Missing Features Without the Hassle
  • Comparing Cloud Hosting vs. Self Hosting
  • Observability Architecture: Financial Payments Introduction
  • Competing Consumers With Spring Boot and Hazelcast

Trending

  • Extending Java APIs: Add Missing Features Without the Hassle
  • Comparing Cloud Hosting vs. Self Hosting
  • Observability Architecture: Financial Payments Introduction
  • Competing Consumers With Spring Boot and Hazelcast
  1. DZone
  2. Software Design and Architecture
  3. Cloud Architecture
  4. JBoss Fuse—How to Setup Cluster of Servers in Fabric

JBoss Fuse—How to Setup Cluster of Servers in Fabric

Christina Lin user avatar by
Christina Lin
CORE ·
Apr. 08, 15 · Interview
Like (3)
Save
Tweet
Share
6.25K Views

Join the DZone community and get the full member experience.

Join For Free

Staying in Beijing for a technical enablement, one question I have been ask a lot is how to setup a Fabric in a cluster of servers with JBoss Fuse?

I am going to setup 2 Fuse on 2 different servers, and then join them together to form a fabric cluster.

BUT! In the real world please make it at least 3 servers, as zookeeper needs more then 3 to successfully setup it's ensembles!

First we need to create a fabric, so unzip the JBoss Fuse zip file in Server1, setup password by editing etc/user.properties.

And please do the same thing to server2. If you are testing, and tries to setup on the same machine, please remember to go to "org.apache.karaf.management.cfg" under etc/ and change the RMI related port.


Also there are a few more port you need to adjust,

org.apache.karaf.shell.cfg, change the:

  • sshPort

and last inside system.properties

  • org.osgi.service.http.port
  • activemq.port
  • activemq.jmx.url

Now, getting back to setting the cluster of fabric, start up JBoss Fuse by going into bin/ and execute fuse on server one. After it starts up, create a fabric by entering the following command:

fabric:create --wait-for-provisioning

This spins up a fabric on a container call root, now, start up JBoss Fuse on server2 by going to bin/ and execute fuse on server two. And instead of creating a fabric, we are going to join, by entering following command, as fabric:join [options] zookeeperUrl [containerName].

fabric:join --zookeeper-password admin 192.168.0.1:2181 root1

To find out what the zookeeper URL, go to your fuse command line console in Server1 and type:

config:edit io.fabric8.zookeeper
config:proplist

This will give you your zookeeper details:

                       JBossFuse:karaf@root> config:proplist
            service.pid = io.fabric8.zookeeper
            zookeeper.password = ZKENC=YWRtaW4=
            zookeeper.url = 192.168.0.1:2181
            fabric.zookeeper.pid = io.fabric8.zookeeper

And now we have successfully created a fabric on 2 servers. If you type in container-list in the command line, you should be able to see we now have 2 working server.

JBossFuse:karaf@root> container-list 
[id]                           [version] [connected] [profiles]                                         [provision status]
root*                          1.0       true        fabric, fabric-ensemble-0000-1, jboss-fuse-full    success
root1                          1.0       true        fabric                            

And if you login to Fuse management console, under Runtime-> Containers you will see the 2 root containers on both servers

To add a new container, click on +Create on top right hand corner of the page, select the parent container so it will run on the server base on the parent container. Then choose the profile you need to install on the container.

And we are done!



cluster JBoss

Published at DZone with permission of Christina Lin, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

Trending

  • Extending Java APIs: Add Missing Features Without the Hassle
  • Comparing Cloud Hosting vs. Self Hosting
  • Observability Architecture: Financial Payments Introduction
  • Competing Consumers With Spring Boot and Hazelcast

Comments

Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com

Let's be friends: