Skip to main content

Posts

Showing posts from May, 2015

Integration Project- Micro Services Migration Story with JBoss BPM Travel Agency - Part Five

Part Five- Migrating Web Services.
This post is the fifth part of a JBoss Travel Agency Integration Demo series, and we are going to talk about how to migrate from an existing web service to JBoss Fuse. And it is so much easier then you can ever imagine. When migrating web services, we know there will be a contract already exists, it is the WSDL file. So all we have to do is just to implement this contract. If you want to know more about the micro service architecture of the demo, please see this post for more details. For now, all you have to know, it that now we are going to migrate from an already existing web service to JBoss Fuse, and then dispatch these request to difference message queue in broker, so later on the backend service can retrieve and process it.

After receiving hotel request from client, the web service will be dispatched to messaging queues. And because the result needs to go back to the client, we need to make sure the request comes back, there for we need to set…

Integration Project- Micro Services Migration Story with JBoss BPM Travel Agency - Part Four

Part Four- Persistence with JPA In the post, I am going to show you how to create the fuse side travel agency demo from scratch. We are going to take a look at how create the Flight/Hotel booking and cancellation service. If you would like to know more about the micro service architecture this demo is trying to showcase, please go to part 2 of the series
for more information. Due to the fact that Flight and Hotel booking are identical, I will be focusing on the Hotel side. What this service does, is it simply books the hotel when receives a an ID when the booking is done, it'll return a 26 character BookingID as key. This key is then used if the user wants to cancel the booking. As for cancellation, it'll return the cost to cancel it, if the key provided is not found, it'll return 0, as nothing can be cancelled using the key provided.

All request to backend services in this demo are all async, so there are different message queue in the broker connecting to the promotion,…

Integration Project- Micro Services Migration Story with JBoss BPM Travel Agency - Part Three

Part Three - Retrieving Data with JDBC
In the post, I am going to show you how to create the fuse side travel agency demo from scratch. In the original Traveling Agency project, the hotel and flight information are all hardcoded in the application, in the Fuse version, I moved the settings to database. So in the project, you will find that there is a H2 database (File) installed. If you want to know more about the micro service architecture of the demo, please see this post for more details. We are going to concentrate on creating the promotion recommendation service of flights and hotel. Using the Camel JDBC components. I am using Hotel promotion service as example, the same applies to flight too, This service lists all the available hotels to the client with condition like the location of the hotels. After retrieving all the possible hotel data from database, it'll either randomly pick one of them, or create a default hotel.

First we need to collect the request from messaging br…

Red Hat JBoss xPaaS - When xPaaS meets DEVOPS - Part Five

This post is part of short session I spoke in Japan, strictly my opinion.

The last part of my talk is about continuous delivery. The idea of this is to make enterprise more lean,
and react more responsively from user feedback. We all try to find ways to make our application more agile. The way I see many enterprise are still doing especially in my region is they tend to have a rather "Large" release. Each release contains too many updates and new functions. Due to the facts that enterprise wants to have more stable releases, so they have a tendency of having a fully tested large bundle of application to deploy. The process normally takes weeks, by the time software reaches the end users might be too late, and feedback and response to the application from user has to wait weeks. For developer, it's painful to handle all the different versions, and QAs needs to test a large set of functionalities. If anything goes wrong in production, to rollback to previous version will …

Integration Project- Micro Services Migration Story with JBoss BPM Travel Agency - Part Two

Part two - Moving towards Microservices
Recently "microservices" has become a popular phenomena in application development, if you google it, you will find hundreds definition, best practice and design patterns on this new software architecture. To me, this is not new, back on the "SOA" days, I found the hardest thing for us, is to decide the granularity of the services. That is, deciding how much data each service needs to provide, without wasting too much resource in each client call, or have tiny services that client needs to orchestrate and manage everything. For many "political" reasons, we weren't able to provide service with reasonable size, they needs to be huge with loads of business logic. At the time "Monolithic Applications" was the mainstream way of application development and deployment. As a developer, we hated the decision, because it would involve too many people to just push out one service releases. We came up with an ide…

Red Hat JBoss xPaaS - When xPaaS meets DEVOPS - Part Four

This post is part of short session I spoke in Japan, strictly my opinion.

Automation plays an essential role in DEVOPS, the entire cycle will cripple without automation, the whole idea of DEVOPS is to speed up the process inside enterprise, and relief developer and operation from day to day repetitively meaningless routines. Automation meaning that anything the machine can do, make the machine do it. In the old day, due to technology limitation, politics or if it's just simply not having time to do it, there are many jobs that needs to have human involve. If you seriously want to introduce DEVOPS, You will find that you spend majority of time dealing with automations.

There are few aspect in Automation in the DEVOPS lifecycle, let's take a look at my real life experience, it's one of the most anti-automation case I have ever seen in many years of my consulting career. This happens in one of the SI company, where they were responsible for maintaining a banking solution for a …

Integration Project- Micro Services Migration Story with JBoss BPM Travel Agency - Part One

Part One - Introduction and Installation
While ago, Eric Schabell launched a project showing various interesting feature of JBoss BPM suite. It's based on a Travel agency story, Eric has made a series of video and blog to walkthrough the installation of both product and project and also shows the possible implementation of how to use rules and processes within BPM suite. This comprehensive demo covers a lot of functions, with  a bookings process for both flights and Hotel, with a payment process that included advanced features like compensation (rolling back bookings), integration of traditional web services in service tasks and a credit card fraud detection system.

We think this could be a great story to showcase how to migrate an existing project to a more modern enterprise architecture with micro-service framework, and JBoss Fuse is the perfect solution for this. As Camel has over 150 components to choose from, and webservice is one of them, and the OSGi container is so lightwei…

JBoss Fuse - Automating your environment with Fuse CLI

If you take a look at few of my startup script in my demo from "jbossdemocentral", you will see that I have automated the process of creating JBoss Fuse Fabric, deploying profiles into fabric, creating containers and install these profiles on top of the containers. 
In normal production environment, you will probably startup the JBoss fuse in the background. Under JBoss Fuse installation directory, under bin, you will find several executable scripts or batch, to start JBoss Fuse in the background, simply run the "start" or "start.bat" depending what  your operating system is. And to stop the background process, simply run the "stop" or "stop.bat".   To access the command line console when it's running in the background, we can run the "client" or "client.bat" in the bin folder. It'll will take you to the command line console, where you normally see when running fuse. 

To automate and managing JBoss Fuse usi…