Review: "Java EE 7 Performance Tuning and Optimization" by Osama Oransa

Latest Packt Publishing Java EE 7 books are all around performance and tuning. I had the pleasure to review another book, the  "Java EE 7 Performance Tuning and Optimization" by Osama Oransa.

Abstract
With the expansion of online enterprise services, the performance of an enterprise application has become a critical issue. Even the smallest change to service availability can severely impact customer satisfaction, which can cause the enterprise to incur huge losses. Performance tuning is a challenging topic that focuses on resolving tough performance issues.
In this book, you will explore the art of performance tuning from all perspectives using a variety of common tools, while studying many examples.
This book covers performance tuning in Java enterprise applications and their optimization in a simple, step-by-step manner. Beginning with the essential concepts of Java, the book covers performance tuning as an art. It then gives you an overview of performance testing and different monitoring tools. It also includes examples of using plenty of tools, both free and paid.

Book: "Java EE 7 Performance Tuning and Optimization"
Language : English
Paperback: 478 pages
Release Date: June 23, 2014
ISBN-10: 178217642X
ISBN-13: 978-1782176428

About the Author
Osama Oransa (blog) is an IT solution architect with more than 12 years of technical experience in Java EE. He is a certified Java enterprise architect and an SME in web services technology. He is currently working with the Vodafone Group as a solution architect. He has a diploma in IT from the Information Technology Institute (ITI) and a diploma in CS from the Arab Academy for Science, Technology and Maritime Transport (AASTM). He is currently working towards a Master's degree in CS. In 2010, one of his projects in Pulse Corp, "Health Intact", won Oracle Duke's Choice Award. He is the founder of more than 12 open source projects hosted on SourceForge.

The Content
Chapter 1, Getting Started with Performance Tuning, takes you through the art of performance tuning with its different components and shows you how to think when we face any performance issue. It focuses on preparing you to deal with the world of performance tuning and defining the handling tactics.
Chapter 2, Understanding Java Fundamentals, lays the foundation of required knowledge of the new features in Java Enterprise Edition 7 and different important Java concepts, including the JVM memory structure and Java concurrency. It also focuses on the different Java Enterprise Edition concurrency capabilities.
Chapter 3, Getting Familiar with Performance Testing, discusses performance testing with its different components, defines useful terminologies that you need to be aware of, and then gives hands-on information about using Apache JMeter to create your performance test plans for different components and get the results.
Chapter 4, Monitoring Java Applications, dissects the different monitoring tools that will be used in performance tuning, starting from the operating system tools, different IDE tools, JDK tools, and standalone tools. It covers JProfiler as an advanced profiling tool with its offline profiling capabilities.
Chapter 5, Recognizing Common Performance Issues, discusses the most common performance issues, classifies them, describes the symptoms, and analyzes the possible root causes.
Chapter 6, CPU Time Profiling, focuses on the details of getting the CPU and time profiling results, ways to interpret the results, and ways to handle such issues. It discusses the application logic performance and ways to evaluate different application logics. It provides the initial performance fixing strategy.
Chapter 7, Thread Profiling, discusses thread profiling with details on how to read and interpret thread profiling results and how to handle threading issues. It also highlights the ways to get, use, and read the thread dumps.
Chapter 8, Memory Profiling, discusses how to perform memory profiling, how to read and interpret the results, and how to identify and handle possible issues. It also shows how to read and query memory heap dumps and analyze the different out of memory root causes. The chapter finishes your draft performance fixing strategy.
Chapter 9, Tuning an Application's Environment, focuses on tuning the application environment, starting from the JVM and passing through other elements such as the application servers, web servers, and OS. We will focus on selected examples for each layer and discuss the best practices for tuning them.
Chapter 10, Designing High-performance Enterprise Applications, discusses design and architecture decisions and the performance impact. This includes SOA, REST, cloud, and data caching. It also discusses the performance anti-patterns.
Chapter 11, Performance Tuning Tips, highlights the performance considerations when using the Agile or Test-driven Development methodologies. This chapter also discusses some performance tuning tips that are essential during the designing and development stages of the Java EE applications, including database interaction, logging, exception handling, dealing with Java collections, and others. The chapter also discusses the javap tool that will help you to understand the compiled code in a better way.
Chapter 12, Tuning a Sample Application, includes hands-on, step-by-step tuning of a sample application that has some performance issues. We will measure the application performance and tune the application issues, and re-evaluate the application performance.

Writing and Style
The language is clear and easy to follow. Illustrations and tables makes understanding of the written word easier. Even a non native speaker can follow easily.

Conclusion and Recommendation
80 percent of the book cover general performance tuning, monitoring and profiling. Only the last three chapters cover additional information for enterprisy applications. The sample application walk through is kind of helpful and gives beginners a decent idea at what to look if you have never done that kind of things before. The title is highly confusing and I would have picked a more general name. This book is not intended to cover Java EE features; it simply highlights some essential fundamentals we should be aware of while dealing with Java performance tuning and applies more general to Java SE based applications.

Exploring the SwitchYard 2.0.0.Alpha2 Quickstarts

In one of my last posts I explained how you get started with SwitchYard on WildFly 8.1. In the meantime the project was busy and released another Alpha2. A very good opportunity to explore the quickstarts here and refresh your memory about it. Beside the version change, you can still use the earlier blog to setup you local WildFly 8 server with latest Switchyard. As with all frameworks there is plenty of stuff to explore and a prerequisite for doing this is to have a working development environment to make this easier.

Setting up JBoss Developer Studio
First things first. Download a copy of the latest JBoss Developer Studio (JBDS) 7.1.1.GA for your operating system and install it. You should already have a JDK in place so a simple

java -jar jbdevstudio-product-eap-universal-7.1.1.GA-v20140314-2145-B688.jar

will work. A simply 9 step installer will guide you through the steps necessary. Make sure to select the suitable JDK installation. JBDS works and has been tested with Java SE 6.x and 7.x. If you like to, install the complete EAP but it's not a requirement for this little how-to. A basic setup without EAP requires roughly 400 MB disc space and shouldn't take longer than a couple of minutes. If you're done with that part launch the IDE and go on and configure the tooling. We need the JBoss Tools Integration Stack (JBTIS). Configure them by visiting "Help -> Install New Software" and add a new Update Site with the "Add" button. Call it SY-Development and point it to: "http://download.jboss.org/jbosstools/updates/development/kepler/integration-stack/"
Wait for the list to refresh and expand the JBoss Integration and SOA Development and select all three SwitchYard entries. Click your way through the wizards and you're ready for a re-start.

SY Tooling 2.0.0
Please make sure to disable Honour all XML schema locations in preferences, XML→XML Files→Validation after installation.  This will prevent erroneous XML validation errors from appearing on switchyard.xml files.

Preventing erroneous XML validation
That's it for sure. Go ahead and import the bean-service example from the earlier blog-post (Import -> Maven -> Existing Maven Projects)

General Information about SwitchYard Projects
Lets find out more about the general SwitchYard project layout before we dive into the bean-service example.  A SwitchYard project is a Maven based project with the following characteristics:
  • a switchyard.xml file in the project's META-INF folder
  • one or more SwitchYard runtime dependencies declared in the pom.xml file
  • org.switchyard:switchyard-plugin mojo configured in the pom.xml file
Generally, a SwitchYard project may also contain a variety of other resources used to implement the application, for example: Java, BPMN2, DRL, BPEL, WSDL, XSD, and XML files. The tooling supports you with creating, changing and developing your SY projects. You can also add SY capabilities to existing Maven projects. More details can be found in the documentation for the Eclipse tooling.

Exploring the Bean-Service Example
The Bean-Service example is one of the more simpler ones to get a first impression about SY. All of the example applications in the Quickstarts repository are included in quickstarts/ directory of your installation and also available on GitHub. The bean-service quickstart demonstrates the usage of the bean component. The scenario is easy: An OrderService, which is provided through the OrderServiceBean, and an InventoryService which is provided through the InventoryServiceBean implementation take care of orders. Orders are submitted through the OrderService.submitOrder, and the OrderService then looks up items in the InventoryService to see if they are in stock and the order can be processed. Up to here it is basically a simple CDI based Java EE application. In this application the simple process is invoked through a SOAP gateway binding (Which is indicated by the little envelope).
Bean Service Quickstart Overview
Let's dive into the implementation a bit. Looking at the OrderServiceBean reveals some more details. It is the implementation of the OrderService interface which defines the operations. The OrderServiceBean is just a bean class few extra CDI annotations. Most notably is the
@org.switchyard.component.bean.Service(OrderService.class)
The @Service annotation allows the SwitchYard CDI Extension to discover your bean at runtime and register it as a service. Every bean service must have an @Service annotation with a value identifying the service interface for the service. In addition to providing a service in SwitchYard, beans can also consume other services. Those references need to be injected. In this example the InventoryService is injected
 @Inject
@org.switchyard.component.bean.Reference
private InventoryService _inventory;
Finally, all you need is the switchyard.xml configuration file where your Service, Components, Types and implementations are described.
<composite name="orders" >
<component name="OrderService">
<implementation.bean class="org.switchyard.quickstarts.bean.service.OrderServiceBean"/>
<service name="OrderService">
<interface.java interface="org.switchyard.quickstarts.bean.service.OrderService"/>
</service>
</component>
</composite>

That was a very quick rundown. We've not touched the webservice endpoints, the WSDL and the Transformer configuration and implementation. Have a look at the SwitchYard tutorial which was published by mastertheboss and take the chance to read more about SY at the following links:



Developer Interview (#DI 5) Jeff Genender (@jgenender) about Apache, Karaf, Data and Integration

In my evening hours I had the chance to talk to Jeff Genender (@jgenender) which resulted in a new episode of my developer interviews. We talked about all things Apache and integration and also a bit about Java EE and microservices and what today's customers want from a modern architecture.

Jeff Genender is a Java Champion, Apache Member, and Java Open Source consultant specializing in SOA and enterprise service implementation. Jeff has over 23 years of software architecture, team lead, and development experience in multiple industries. He is a frequent speaker at such events as TheServerSide Symposium, JavaZone, Java In Action, JavaOne, JFokus, and numerous Java User Groups on topics pertaining to Enterprise Service Bus (ESBs), Service Oriented Architectures (SOA), and application servers.
Jeff is an active committer and Project Management Committee (PMC) member for Apache ServiceMix, CXF, Geronimo, a comitter on OpenEJB and Mina, and author of several very popular Mojo (Maven plugins). He is the author of Enterprise Java Servlets (Addison Wesley Longman, 2001), co – author of Professional Apache Geronimo (2006, Wiley), and co-author of Professional Apache Tomcat (2007, Wiley). Jeff also serves as a member of the Java Community Process (JCP) expert group for JSR-342 (Java Platform, Enterprise Edition 7 (Java EE 7) Specification) as a representative of the Apache Software Foundation.

As usual, time to grab a coffee+++ and lean back while listening! Thank you Jeff, for taking the time..

 

Red Hat to Acquire FeedHenry – It takes a Village to raise an app

Red Hat, Inc.today announced that it has signed a definitive agreement to acquire FeedHenry, a leading enterprise mobile application platform provider. This will expand Red Hat’s portfolio of application development, integration, and Platform-as-a-Service (PaaS) solutions and support our customers with mobile application development in public and private environments.
A warm welcome to the FeedHenry Team at Red Hat!

What is FeedHenry?
It is a cloud-based mobile application platform to design, develop, deploy and mobile applications. The platform provides specific services for security, notification and data synchronization. You can build hybrid apps not only for iOS, Android, Blackberry and Windows Phone mobile devices but
also as web apps accessible from any browser. On top it enables developer to build access to corporate data and applications into those applications and build backend logic that supports their mobile applications.

What are the technical components?
The open and extensible architecture is based on Node.js for client and server side mobile app development. It supports a wide variety of popular toolkits including native SDKs, hybrid Apache Cordova, HTML5 and Titanium, as well as frameworks such as Xamarin, Sencha Touch, and other JavaScript frameworks. Out-of-the-box Node.js plugins are a set of best-in-class Node.js modules that have been tested and curated, ready for developers to cut and paste into their app projects. Those exist for things like Dropbox, Facebook, Google APIs, EC2, Remote Databases, SaaS Connectors,

Why and where does it fit in?
Feedhenry is going to be alligned with the open hybrid cloud strategy and will enable enterprises to accelerate mobile app development and backend integration via private clouds, public clouds, and on-premises. So this is an important addition to Red Hat’s JBoss xPaaS for OpenShift strategy. Learn more about xPaaS in a recent blog-entry. Mobile application services are a key part of that vision and FeedHenry provides the security, policy management, synchronization, and integration features to support mobile applications.


Join the Webcast
Craig Muzilla, senior vice president, Application Platform Business, Red Hat, and Cathal McGloin, chief executive officer, FeedHenry, will host a webcast to discuss this announcement tomorrow, Sept. 19, 2014, at 11 a.m. EDT. Following remarks, press and analysts are invited to participate in a live question and answer session. Join the webcast or view the replay after the event.

Further Readings
FAQ – Red Hat acquisition of FeedHenry
Read the complete press-release on the official Red Hat website.
@feedhenry
Announcement on the Feedhenry website.
Some real-life demos and tutorials on vimeo
Blog-POst from Craig Muzilla

WildFly 9 – Don’t cha wish your console was hawt like this!

Everybody heard the news probably. The first WildFly 9.0.0.Alpha1 release came out Monday. You can download it from the wildfly.org website The biggest changes are that it is built by a new feature provisioning tool which is layered on the now separate core distribution and also contains a new Servlet Distribution (only a 25 MB ZIP) which is based on it. It is called "web lite" until there'll be a better name.
The architecture now supports server suspend mode which is also known as graceful shutdown. For now only Undertow and EJB3 use this so far. Additional subsystems still need to be updated. The management APIs also got notification support. Overall 256 fixes and improvements were included in this release. But let's put all the awesomeness aside for a second and talk about what this post should be about.

Administration Console
WildFly 9 got a brushed up admin console. After you downloaded, unzipped and started the server you only need to add a user (bin/add-user.sh/.bat) and point your browser to http://localhost:9990/ to see it.

With some minor UI tweaks this is looking pretty hot already. BUT there's another console out there called hawtio! And what is extremely hot is, that it already has some very first support for WildFly and EAP and here are the steps to make it work.

Get Hawtio!
You can use hawtio from a Chrome Extension or in many different containers - or outside a container in a stand alone executable jar. If you want to deploy hawtio as a console on WildFly make sure to look at the complete how-to written by Christian Posta. The easiest way is to just download latest executable 1.4.19 jar and start it on the command line:
java -jar hawtio-app-1.4.19.jar --port 8090
The port parameter lets you specify on which port you want the console to run. As I'm going to use it with WildFly which also uses the hawtio default port this is just directly using another free port.
Next thing to do is to install the JMX to JSON bridge, on which hawtio relies to connect to remote processes. Instead of directly using JMX which is blocked on most networks anyway the Jolokia project bridges JMX MBeans to JSON and hawtio operates on them. Download latest Jolokia WAR agent and deploy it to WildFly. Now you're almost ready to go. Point your browser to the hawtio console (http://localhost:8090/hawtio/) and switch to the connect tab. Enter the following settings:
And press the "Connect to remote server" button below. Until today there is not much to see here. Beside a very basic server information you have the deployment overview and the connector status page.
But the good news is: Hawtio is open source and you can fork it from GitHub and add some more features to it. The WildFly/EAP console is in a hawtio-web subproject. Make sure to check out the contributor guidelines.

JBoss Fuse Component Details and Versions

JBoss Fuse combines several technologies like core Enterprise Service Bus capabilities (based on Apache Camel, Apache CXF, Apache ActiveMQ), Apache Karaf and Fabric8 in a single integrated distribution. The best part is, that no matter what your skill level is, contributing to JBoss Fuse can be very rewarding and a great learning experience. You’ll meet lots of smart, passionate developers who are all driven to create the best middleware possible in open source! A good way to start is to look at the individual technologies and versions which contribute to JBoss Fuse. Here's a short list about the most important ones:

Component
FuseSource 7.1JBoss Fuse 6.0JBoss Fuse 6.1
Apache Camel
2.10.02.10.22.12.3
Apache ActiveMQ
5.7.05.8.05.9.0
Apache CXF
2.6.02.6.02.7.0
Apache Karaf
2.3.02.3.02.3.0
Fuse Fabric
7.1.07.2.0
Fabric8
1.0.0
Spring Framework
3.0.73.1.33.2.4
Fuse IDE
7.1.606.0 with latest updates

If you want to see a bit more about what Fuse can do for you, here's a short little introduction to it:

API Management in WildFly 8.1 with Overlord

I gave a brief introduction about the Overlord project family yesterday. Today it's time to test-drive a bit. The API Management sub-project released a 1.0.0.Alpha1 two days ago and introduces the first set of features according to the 18-Month roadmap.

What is APIMan exactly?
It is an API management system which can either be embedded with existing frameworks or applications or even run as a separate system. So far, so good. But what is API Management and why should you care about it? Fact is, that today's applications grow in size and complexity and get distributed more widely. Add more consumers to the mix like mobile devices, TVs or the whole bunch of upcoming IoT devices and think about how you would implement access control or usage consistently over a whole bunch of applications. A nightmare candidate. But don't worry too much. This is where API Management comes in. APIMan provides a flexible, policy-based runtime governance for your APIs. It allows API providers to offers the same API through multiple plans, allowing different levels of service to different API consumers. Sounds complicated still? Let's give it a try.

The Library REST-Service
Imagine that a public library has a nice RESTful service which lists books. It's running somewhere and usually is not really access restricted. Now someone came up with the idea to build an amazing mobile app which can find out if a book is in the library or not. A next step should be to add the option to reserve a book for a couple of hours, which the old system really can't do for now. Instead of heavily tweaking the older version of the library applications we're going to use APIMan to provide a consistent API to the mobile application and let it manage the authentication for now. The API I'm using here is a simple resteasy example. You can use whatever web-service endpoint you have to play around with.

Getting Started on WildFly 8.1
The project can be built and deployed on a variety of runtime platforms, but if you want to see it in action as quickly as possible you just need to fork and clone the APIMan GitHub repository and simply build it with Maven 3.x. If you use the "run-all-wildfly8" profile, you're ready to instantly test drive it, because it does not only build the project, but also downloads and configures latest WildFly 8.1 and finally starts it for you. It takes a while to build and then start up, so you'd better bring some patience.
So, all you have to do to explore it is to fire up the admin console at http://localhost:8080/apiman-dt-ui/ and use one of the following users to log-in (the "!" is part of the password, btw):
  • admin/admin123!
  • bwayne/bwayne123!
  • ckent/ckent123!
  • dprince/dprince123!

Test-Driving The Quickstart
The documentation is a bit weak for now so I will give you a short walk through the console.
Open the console and log-in with the admin user. Now you can "Create a new Organisation" let's call it "Public Library" for now. The newly created organization shows you some tabs (Applications, Services, Plans, Members). Switch to the services tab and click on the button "New Service". Enter "BookListing" as a name, leave the 1.0 as Version and you might give it a description for informational purpose.
After you click the "Create Service" button you are redirected to the overview page. Switch to the "Implementation" and fill in the final API Endpoint. In my case this would be:http://localhost:9080/jaxb-json/resteasy/library/books/badger (note: it is deployed on a different WildFly instance) Click "Save" when you're done.

If you switch back to the overview page, you see, that the service is in status "Created" and the Publish button is still grayed out. In order to reach this goal, we need to add some more information to APIMan. The next step is to add a so called Plan to the Organisation. Switch back to it and select the Plan tab and click the "New Plan" button. Plans basically allow to group individual policies and assign them to services. Call it "InternetBlackList" and create it by clicking the accompanying button. From the "Plan" overview select "Policies" and "Add Policy" by clicking the button. Define an "IP Blacklist Policy" and enter a potentially malicious IP address you don't want the service to be accessed by.


To be able to publish our service, we need to link the newly created Plan to the BookListing service. Navigate back there and select the Plans tab. Select the "InternetBlackList" plan and click "Save". Reviewing the "Overview" page on the Service now finally shows the "Ready" state and let's us publish it.


Now that it is published, we can actually use it. But we'll take one additional step here and link the service to an application via a contract. Creating a Contract allows you to connect an Application to a Service via a particular Plan offered by the Service. You would want to do this so that your Application can invoke the Service successfully.
Create an application by navigating back to the Public Library Organization and clicking the "New App" button. Call it "Munich", leave the 1.0 as a version and enter a description if you like to; Click "Create Application". The one step left to do is to link the service and the application. This is done via a contract. Select the "Contracts" page and create a "New Contract" with the button. Enter "book" in the "Find a Service" field and search for our BookListing service. Select it. Now you can create the Contract.


The last step is to register the newly created application in the "Overview" page.

That was it. We now have a published service and a registered application. If you navigate to the API page of the application you can see the managed endpoints for the application. If you hover over the service, you get a "copy" button which let's you copy the URL of the managed endpoint funneled through the APIMan gateway.


If you try to access the service through the specified BlackListed IP address, you will now get an error. If not, you get proxied to the service by the gateway.

Notice the apikey query-string? This is the key with which the gateway locates your service and proxies your call to the managed endpoint. If you don't want to sent it as part of the query string you can also use a custom HTTP header called X-API-Key.

What's Next?
That was a very quick and incomplete walk through. But you hopefully got an idea about the basic concepts behind it. APIMan and the other Overlord sub-projects are evolving quickly. They are happy to receive contributions and if you like what you've seen or have other feedback, don't hesitate to get in touch with the project. If you want to see the more API like approach you can also watch and listen to the following screencast. It is a bit outdated, but still helpful.

Overlord – The One Place To Rule And Manage your APIs

We're living in a more and more distributed world today. Instead of having individual, departmental projects running on some hardware below a random desk, today's computer systems run at large scale, centralized or even distributed. The needs for monitoring and managing never changed but got far more complex over time. If you'd put all those cross functional features into a bucket it would most likely be called "Governance". This can happen on many levels. People, processes and of course infrastructure components.

What is Overlord?
Overlord is a a set of sub-projects which deal with different aspects of system governance. All four sub-projects are so called "upstream" projects for JBoss Fuse Service Works. But Service Works is even more, so let's just focus on the four for now.

SRAMP
Overlord S-RAMP is a full-featured artifact repository comprised of a common data model, powerful query language, multiple rich interfaces, flexible integration, and useful tools. It aims to provide a full implementation of the OASIS S-RAMP specification.

Developer Links:

DTGov
This component provides the capability to manage the lifecycle of systems from inception through deployment through subsequent change management. A flexible workflow driven approach is used to enable organizations to customize governance to fit the way they work.

Developer Links:

Runtime Government (RTGov)
This component provides the infrastructure to capture service activity information and then correlate, analyse and finally present the information in a form that can be used by a business to police Business/Service Level Agreements, and optimize their business.

Developer Links:

API Management
If you want to centralize the governance of your APIs, this is the project for you! The API Management project provides a rich management layer used to configure the governance policies you want applied to your APIs. Once configured, the API Management runtime Policy Engine can run as part of a standard Gateway or embedded in any application.

Developer Links:

What's going on lately?
Overlord just got a brand new website up and running. Have a look at it and don't forget to give feedback or work on it, as it is also open source you are free to fork it an send a pull request. Make sure to look at the contributor guidelines before.

Developer Interviews (#DI 4) Stan Lewis (@gashcrumb) about #hawtio

Already the fourth edition of my pod- and screencast crossover. Today it was Red Hatter Stan Lewis (@gashcrumb) who took some time to talk about his work and about the hot web-console which is the new front-end for all things JBoss Fabric8/Fuse. He is a Principal Software Engineer at Red Hat and came on board with the Fusesource acquisition end of 2012. As one of the primary developers on the hawtio web console, an AngularJS web application written in Typescript for managing JVMs; he also work closely with the Fabric8 project to develop a poly-container deployment and management platform.

Time to grep a coffee+++ and watch the roughly 20 minute recording. Thank you Stan for taking the time!



If you can't get enough and want to know more, take a look at the recording from this year's DevNation conference, where Stan gave a complete overview about how to extend hawtio.

Inside JBoss Data Virtualization – iPaaS Demystified (Part 1)

This is another blog the ongoing series about the Red Hat xPaaS solutions, where I am trying to demystify the acronyms a bit and give you more information about the projects and products composed around it. After the initial overview this post focuses on the first aspect of the iPaaS solution: JBoss Data Virtualization.

What is Data Virtualization and why should I care?
Think of Data Virtualization as of a distinct layer between your business applications and your data-sources. It can also be described as an integration layer for data. So, instead of pulling different datasources into your business application and following a polyglot persistence approach you take advantage of not only the data-access aspects but also get a consistent view on your distributed data-models. All perspectives are encapsulated: data abstraction, federation, integration, transformation, and delivery capabilities to combine data from one or multiple sources into reusable and unified logical data models.



To successfully implement such an approach, you need to follow a three step approach:
  • Connect: Access Data From Multiple Data Sources
  • Compose: Create a Business Friendly Virtual Data Model
  • Consume: Make the Data Model Available to Consumers
Sounds complicated - How Do I Get Started?
There are a couple of different ways to get some first experiences. In no particular order:
The Community Projects
Behind the supported Red Hat solution are:
A short seven minute video introduction by Blaine Mincey:

Web Based SSH Access your OpenShift Applications

I recently came across KeyBox. This is a Apache licensed SSH console for applications in an OpenShift Domain. The cool thing is, that it is completely web-based. And by far cooler: The client is completely written in JavaScript (using term.js) connecting to JSch (Java implementation of SSH2) running as a web-application on the JBoss Enterprise Web Server (EWS 2.0).
This is a quick and easy way to get hand on your machine, if you can't use a native ssh client. And it is a great tool in your xPaaS developer toolbox.

Prerequisites
There's not a hell lot to get started: But you obviously need a free OpenShift account first. After that, install the OpenShift client tools (aka rhc). They require Ruby 1.8.7 or higher. If you want to get the most out of it, make sure to install Git for your system, too.

Installing
Installing is just a one-liner in the terminal:
rhc app create keybox jbossews-2.0 --from-code git://github.com/skavanagh/KeyBox-OpenShift.git
It might take a while, but after the command finished, you can access KeyBox via:
https://keybox-<namespace>.rhcloud.com
All members of the domain can login with their OpenShift account.

Now you can open a SSH session for every application in your domain. KeyBox generates an SSH key pair and associate the public key with the user account for every login.



Make sure to follow Sean Kavanagh on Twitter (@spkavanagh6) and star the KeyBox-OpenShift repository if you like it!

Start your xPaaS Journey with OpenShift.

After you've hopefully read the short little introduction to xPaaS you're excited to try out all the new features and just want to get started without further reading? That is easy. The only true prerequisite for everything you do around xPaaS is an OpenShift account. And believe it or not, it is free. Like in free. If you don't believe me, follow a few simple steps to get yours today.


First and Only Step
is to visit http://www.openshift.com. You're presented with three choices. "Online", "Enterprise" and "Origin". Feel free to look around, what OpenShift has to offer, but what you are looking for is the "Online" version, which is Red Hat's public cloud application development and hosting platform.

Click the red "Signup for Free" button and simply enter your email-address, a 6 character password including the validation of it and the number/word from the captcha. When you're done, click "Signup".

What's next?
Check your inbox for an email confirming your account. You must click the link in the email to complete the registration process. If you do not receive an email within a few minutes, check your Spam folder to ensure it was not incorrectly moved. If you still run into problems you might consult the FaQ, send an email to the openshift team or see them on IRC (freenode/#openshift).
The link in the email sends you to a website, where you have to validate and accept the terms and conditions. Now you're all set. No credit-card, no mailing-address, no nothing. You have your own Openshift account ready.


Getting Started with OpenShift Online
You basically have three ways to continue your journey. Via the web-based console, via the command-line tools or via Eclipse/JBoss Developer Studio. Whatever way you decide to go, the Quickstarts are a very good thing to start with. You will be overwhelmed with the polyglot nature and the variety you can find there.

As next steps you might want to find out about:

Bootstrapping Apache Camel in Java EE7 with WildFly 8

Since Camel version 2.10 there is support for CDI (JSR-299) and DI (JSR-330). This offers new opportunities to develop and deploy Apache Camel projects in Java EE  containers but also in standalone Java SE or CDI containers. Time to try it out and get familiar with it.

What exactly is Camel?
Camel is an integration framework. Some like to call it ESB-lite. But in the end, it is a very developer and component focused way of being successful at integration projects. You have more than 80 pre-build components to pick from and with that it basically contains a complete coverage of the Enterprise Integration Pattern which are well known and state of the art to use. With all that in mind, it is not easy to come up with a single answer. If you need one, it could be something like this: It is messaging technology glue with routing. It joins together messaging start and end points allowing the transference of messages from different sources to different destinations.

Why Do I Care?
I'm obviously excited about enterprise grade software. But always been a fan of more pragmatic solutions. There's been some good blog posts, about when to use Apache Camel and with the growing need to integrate different systems over very heterogeneous platforms it is always handy to have a mature solutions at hand. Most of the samples out there start with bootstrapping the complete Camel magic, including the XML based Spring DSL and with it the mandatory dependencies. That blows everything up to a extend I don't want to accept. Knowing that there has to be a lightweight way of doing it (Camel-Core is 2.5 MB at Version 12.13.2) I was looking into how to bootstrap it myself. And use some of it's CDI magic.

The Place to Look for Ideas first
Is obviously the Java EE samples project on GitHub. Some restless community members collected an awesome amount of examples for you to get started with. The ultimate goal here is to be a reference for how to use the different specifications within the Java EE umbrella. But even some first extra bits have been included and showcase an example from different areas like NoSQL, Twitter, Quartz Scheduling and last but not least Camel integration. If you run it as it is in latest WildFly 8.1 it is not working. The cdi extension of Camel makes it a bit tricky to do it, but as mentioned in the corresponding issue, there is a way to get rid of the ambiguous CDI dependency by just creating a custom veto extension. The issue is filed with Camel and I heard, that they are looking into improving the situation. If you want to to try out the example, go to my GitHub repository and look for the CamelEE7 project.

How Did I Do It?
The Bootstrap.java is a @Singleton EJB which is loaded on application startup (remember, there are different ways to start up things in Java EE) and by @Inject ing an org.apache.camel.cdi.CdiCamelContext you get access to Camel. The tiny example uses another HelloCamel bean to show how to work with payload in the CDI integration.
Make sure to look at the CamelCdiVetoExtension.java and how it is configured in the META-INF folder. Now you're ready to go. Happy Coding.

And The Best For Last
Camel 12.14 is on the horizon already, scheduled to be released in September. If you have issues or wishes you want to see in it, now is the time to speak up!
Excerpt of the awesome new features, that are upcoming:


Time to get excited!

Everything Developers Need To Know About xPaaS

I've been reading a lot about Red Hat products lately and being interested in cloud and such since some years now, it's pretty obvious for me to look into the cloud offerings from Red Hat in more detail. Arun did a great overview about JBoss xPaaS back in April this year and I thought it might be time to not only give you an overview but also point you to all the relevant information that interested developers need to know about. If I missed something, or your stuck somewhere, don't forget to reach out to me and let me know!

xPaaS= aPaaS, iPaaS, bpmPaaS, dvPaaS, mPaaS + OpenShift
A very tiny little overview to get you up to speed. To make it simple, JBoss xPaaS services is another name for having all the powerful capabilities of JBoss Middleware available as a cloud based services, ready for use on OpenShift. A main differentiator to others is, that it is not just a bunch of services with little to know integration. It is a complete set of pre-build and ready to use integrated services.


For those interested why it is called xPaaS: Gartner uses the term xPaaS to describe the whole spectrum of specialized middleware services that can be offered as PaaS. Red Hat has the complete implementation.

More basic information:
Time to dig deeper into the individual pieces. The idea here is to just breakup the streamlined names a bit and break them down to the individual products and upstream projects used in it. 

Note: Some features on OpenShift are in Alpha release state. Designed and provided for developers to experiment with and explore. And for the i and bpm-PaaS offerings which can be deployed in the free OpenShift Online gears, it is recommend to use medium or large gears for optimum performance.

aPaaS = JBoss Application Hosting + OpenShift
The app-container services of OpenShift for Java EE 6 with Red Hat JBoss EAP/JBoss AS and Java EE 7 with WildFly is there for more than 2 years already. This is the foundation of everything in the xPaaS familiy. To keep it DRY, I put everything which is OpenShift related in this section. 

More basic information:
The integration services consist of two separate offerings at the moment. One is The JBoss Fuse enterprise service bus and the other is JBoss Data Virtualization. 

More basic information:
OpenShift Quickstarts and Cartridges:
Blogs to follow:

bpmPaaS = JBoss BPM Suite + OpenShift
Business Process Management (BPM) and Business Rules Management (BRM) are the most important parts of this 

More basic information:
OpenShift Quickstarts and Cartridges:
Blogs to follow:
Various Developer Links:
The AeroGear UnifiedPush Server allows for sending native push messages to different mobile operation systems. This initial community version of the server supports Apple’s Push Notification Service (APNs), Google Cloud Messaging (GCM) and Mozilla’s SimplePush.

More basic information:
OpenShift Quickstarts and Cartridges:
Blogs to follow:
Various Developer Links:

That's it for a first overview. Let me know if you're missing something. I am committed to close the gap and make working and developing with xPaaS a fun and productive experience.

Developer Interviews (#DI 3) Christian Posta (@christianposta) on fabric8

Time flies and here is the third edition of the new podcast/screencast cross-over series "Developer Interviews". I had the chance to talk to Christian Posta (@christianposta) last week. He is a Principal Middleware Specialist/Architect at Red Hat and well known for being an open-source enthusiast and committer on Apache ActiveMQ and Apache Camel. But he is actually interested in all kinds of middleware technologies and has a comparably extensible coverage on his own blog.

We've been talking about his job, his history and interests and his latest favorite project which is fabric8. So, go and grep a coffee and watch the interview.

Developer Interviews (#DI 2) Claus Ibsen (@davsclaus) About All Things Camel

In the second edition of my developer interview series I had a chance to talk to Claus Ibsen (@davsclaus). He works for Red Hat on open source integration software such as JBoss Fuse and is Apache Camel committer. You may also know him for his book "Camel in Action".
We talked about his history in integration technologies and looked at the latest developments which are upcoming for the Camel 2.14 release which might get released in the September time-frame. Beside that he also showcased how to quickly run a demo with Maven and Eclipse and introduced us to the Camel module in hawtio.
40 minutes is just about right for a coffee and your lunch break! Go, watch it!

All the RedHat Engineers at JavaOne

With only a few more weeks until JavaOne, I am still on the hunt for some good content recommendations. After I've looked at all the sessions from the Java Champions it is time to see what Red Hat is going to offer this year.  Beside the fact, that it is going to be a ton of interesting content you will also get a chance to meet all of them there and interact. If possible, I added a link to both the twitter profile and the blog of the speaker to make it easy for you to follow them. I hope, I haven't forgotten anybody.
And as usual at conferences; Come up to us and speak with us. We want to know what you think about the technologies we're talking about!

Lincoln Baxter III (@lincolnthree ocpsoft.org/)
Fast-Developing CRUD-like Applications with Java EE 7 [BOF2695]
Tools worth sharing: Take back your IDE with Forge [CON2675]

Emmanuel Bernard (@emmanuelbernard , emmanuelbernard.com)
MythBusters: ORMs and NoSQL—Good or Bad? [CON5186]

Sébastien Blanc (@sebi2706sblanc.org)
The Rise of Mobile Enterprise Software  [BOF7164]
How to Build Enterprise Mobile Apps That Integrate with Your Java EE Back End [TUT6006]

Markus Eisele (@myfear, blog.eisele.net)
JavaScript in the Enterprise [CON1747]
Free Java Tools for Maven and Java EE [UGF8872]

Thomas Enebo (@tom_eneboblog.enebo.com)
Modding Minecraft with a Dash of Ruby [BOF6279]

Stephane Epardaud (@UnFroMageceylon-lang.org/blog/)
The Emerging Languages Bowl: The Big League Challenge [CON4388]
Ceylon from Here to Infinity: The Big Picture and What’s Coming [CON3078]

Christine Flood
Shenandoah: An Open Source Garbage Collector (JEP 189) with an Ultralow Pause Time [CON5216]

Tim Fox (@timfoxvertxproject.wordpress.com/)
Writing Highly Concurrent Polyglot Applications with Vert.x [CON7902]

Jonathan Fuerth (@jfuerthjonathan.fuerth.ca/)
The Large-Scale Web Application Development BOF [BOF2260]
Rich HTML5 Web Apps: Typesafe Edition 2 [CON2188]

George Gastaldi (@gegastaldigastaldi.wordpress.com/)
Tools worth sharing: Take back your IDE with Forge [CON2675]
Fast-Developing CRUD-like Applications with Java EE 7 [BOF2695]

Shekhar Gulati (@shekhargulatiwhyjava.wordpress.com/)
So Many Mapping Choices—So Much Fun! [BOF1693]

Arun Gupta (@ArunGupta, blog.arungupta.me)
Lessons Learned from Real-World Deployments of Java EE 7 [CON2450]
Java EE 7 Soup to Nuts [TUT1952]
Devoxx4Kids for Parents [TUT1878]

Mark Little (@nmcl, community.jboss.org/blogs/mark.little)
Java EE 8 Community Update and Panel [CON2131]
Transactions Returning to NoSQL [CON2129]

Omair Majid
Diagnosing Performance Issues with Thermostat [CON2662]

Charles Nutter (@headiusblog.headius.com)
Going Native: Bringing FFI to the JVM [CON3979]
The Emerging Languages Bowl: The Big League Challenge [CON4388]
Script Bowl 2014: The Battle Rages On [CON2939]

Bruno Oliveira (@abstractjblog.abstractj.org)
Mobile Security B-Sides, or the Pitfalls of Application Development [BOF4495]

Steven Pousty (@TheSteve0thesteve0.wordpress.com)
Vert.x + WebSocket + Cloud = Awesome Map Tracking [CON1695]
So Many Mapping Choices—So Much Fun! [BOF1693]

Antoine Sabot-Durand (@antoine_sdwww.next-presso.com)
The Path to CDI 2.0 [CON4294]
Introducing Contexts and Dependency Injection  [CON5004]
CDI 2.0 BOF [BOF5639]
Going Farther with CDI 1.2 [CON5585]

Christian Sadilek (@csadilekerrai-blog.blogspot.de)
The Large-Scale Web Application Development BOF [BOF2260]
Rich HTML5 Web Apps: Typesafe Edition 2 [CON2188]

William Siqueira (@william_antonio, fxapps.blogspot.com)
Using Java 8 to Process Government Open Data [BOF6697]

Mario Torre (@neugensjroller.com/neugens)
OpenJDK Adoption: Learn How You and Your JUG Can Contribute to Java’s Future [BOF4884]
Diagnosing Performance Issues with Thermostat [CON2662]

Developer Interviews (#DI 1) @ehsavoie about #WildFly and #NetBeans

I'm proud to introduce a new series on my blog. Today I'm going to publish the first interview I did with one of the amazing community members out there. I want to know more about the many amazing people that work on all kinds of JBoss and Middleware related stuff.

Emmanuel Hugonnet (@ehsavoie) is the maintainer of the WildFly Plugin for NetBeans. It's not a big secret, that I like that IDE very much and not having an official plugin available made my heart bleed. With the upcoming NetBeans 8.0.1 which is already available as a nightly build, you finally get it included right away. But let's look at the interview and hear from Emmanuel first hand what it took to make it happen and how it can be used.


Java Champions at JavaOne 2014

Isn't it that time of the year again? Booking hotels and travels. Most of my fellow Java Champions (and former ACE Director fellows) are doing some kind of preparation for JavaOne and Oracle OpenWorld these days. Only a few more weeks to go and the content catalog is published. So I thought I might also spend an hour to look at good content. Let's start with talks given by Java Champions.

The Java Champions are an exclusive group of passionate Java technology and community leaders who are community-nominated and selected under a project sponsored by Oracle. Java Champions get the opportunity to provide feedback, ideas, and direction that will help Oracle grow the Java Platform. This interchange may be in the form of technical discussions and/or community-building activities with Oracle's Java Development and Developer Program teams.

Adam Bien
Enterprise Nashorn [CON2266]
Productive JavaFX 8 [CON2265]
Unorthodox Enterprise Practices [CON2301]
Java EE 8 Community Update and Panel [CON2131]
Free Java Tools for Maven and Java EE [UGF8872]
 
Anton  Epple
DukeScript: How to Put the Java into JavaScript [CON6091]
How to Program JavaScript in Java [TUT4890]
Smart UIs for Mobile and Embedded in JavaFX [BOF3453]
Get Productive with Free Java Tools [UGF8846]

Ben Evans
Understanding JIT Compilation with JITWatch [TUT3419]
Java Performance Is a Social Activity [CON3420]
Lightning Talks: Even More Productivity with Free Java Tools [UGF8906]

Trisha Gee
HTML5/AngularJS/Groovy/Java and MongoDB Together: What Could Possibly Go Wrong? [CON1703]

Simon Maple
How to Make Your JUG and Java More Awesome [BOF4004]
Community First: Bringing Java to the Community  [BOF1704]
Do You Really Get Class Loaders? [CON1700]
Development Horror Stories [BOF4223]

Andres Almiray
Functional Programmning the Groovy Way [CON3538]
Gradle: Harder, Better, Stronger, Faster [CON3531]
Build, Test, and Deploy JavaFX Applications with Ease [CON3553]
RIA Technologies and Frameworks Panel [CON2600]

Geert Bevin
Programmers Are Way Cooler Than Musicians [CON1706]
Ten Reasons Why Java Now Rocks More Than Ever [CON1725]

Regina ten Bruggencate
Duchess Meet and Greet [BOF2604]

Markus Eisele
JavaScript in the Enterprise [CON1747]
Free Java Tools for Maven and Java EE [UGF8872]

Bert Ertman
What’s Up with Modularity? [TUT1816]

Fabrizio Gianneschi
Controlling Robots with Java and ROS [UGF9651]

Frank Greco
Lambdas and Laughs [UGF9672]

Gerrit Grunwald 
Sensor Networks with Java SE Embedded and Java(FX) [CON1690]
From a Certain Point of View: Eye Tracking with Java(FX) [CON1753]
JavaFX Everywhere [BOF1578]
Catch Me If You Can: Java on Wearables [CON1835]
RIA Technologies and Frameworks Panel [CON2600]
Smart UIs for Mobile and Embedded in JavaFX [BOF3453]
Pi on Wheels: DIY Robot for Teaching Java in the Context of the Internet of Things [CON5199]
JavaFX Coding Playground (JavaFX-Based Live Editor Tool) [BOF2730]

Arun Gupta
Lessons Learned from Real-World Deployments of Java EE 7 [CON2450]
Java EE 7 Soup to Nuts [TUT1952]
Devoxx4Kids for Parents [TUT1878]

Jason Hunter
What You Need to No About NoSQL in the Cloud [BOF5296]

Michael Hüttermann
Mastering Continuous Delivery and DevOps [CON1844]

Stephan Janssen
When Basketball Meets Raspberry Pi and Android Devices and TomEE [CON1814]
Devoxx4Kids for Parents [TUT1878]

Mattias Karlsson
Java Champions and JUG Leaders Meet Oracle Executives [CON5898]
Create an Agile Learning Organization for Developers [CON5889]

Werner Keil
Java and Digital Currencies, Friend or Foe? [BOF6297]

Michael Kölling
Teaching Java with New Greenfoot Language Interactions [BOF6825]

Jessica Man
Banking on OpenJDK: How Goldman Sachs Is Using and Contributing to OpenJDK [CON5177]

Fabiane Nardon
Big Data and Java: Ask the Experts [UGF9650]

Kevin Nilson
RIA Technologies and Frameworks Panel [CON2600]

Kirk Pepperdine
Do Your GC Logs Speak to You? The G1GC Edition [CON1874]
Toward Low-Latency Java Applications [CON1873]
Lightning Talks: Even More Productivity with Free Java Tools [UGF8906]

JP Petines
JEDI and JEDI4KiDS: Planting the Seeds for the Future [BOF1687]
JEDI + Devoxx4Kids = JEDI4KiDS: A Partnership That’s Changing Lives, One Child at a Time [BOF1773]

Peter Pilgrim
Developing Java EE 7 Applications with Scala [BOF2644]

Chris Richardson 
Map, Flatmap, and Reduce Are Your New Best Friends [CON1914]

Zoran Sevarac
JavaFX 3D: Advanced Application Development [CON1993]
Creating Smart Raspberry PI Applications with Neural Networks [BOF2817]
Teaching Java with Free Java Tools  [UGF8873]
Meet the NetBeans Community, with Boeing, Jelastic, JRebel, Vaadin, and More [UGF8871]

Venkat Subramaniam
Programming with Streams in Java 8 [CON1771]
Programming with Lambda Expressions in Java [CON1770]
Applying Groovy Closures for Fun and Productivity [CON1769]
Exploring Groovy Metaprogramming [CON1768]
Transforming Code to Java 8 [CON1772]
Thinking in Functional Style [CON1767]

Martijn Verburg
Adopting Java: Create Java’s Future. Now. [UGF9754]
Habits of Highly Effective Technical Teams  [CON3409]
Free Java Tools for Maven and Java EE [UGF8872]
OpenJDK Adoption: Learn How You and Your JUG Can Contribute to Java’s Future [BOF4884]

Johan Vos
DataFX: From External Data to a UI Flow and Back [CON3640]
Running JavaFX Applications on Android [CON1804]

NetBeans Nightly Now Includes The WildFly Plugin

Good news out there. The recent nightly builds of NetBeans (apparently upcoming 8.0.1) already contain the latest WildFly Plugin. So you don't need to add it manually and can start working with your favorite application server right away.
Try it out and grep the latest nightly build. Please keep in mind, that the nightly builds are developer builds and shouldn't be expected to be stable.

Some first steps to get started:
  • Download WildFly 8.1.0.Final
  • Install by simply unzipping into your favorite location
  • Download NetBeans Nightly for your platform
  • Install into a location of your choice
  • File > New Project > [Java Web | Maven] > Web Application
  • Give it a Name and Location and finally
  • Add a Server and select "WildFly Application Server"



If you find something make sure to file a bug.Don't forget to follow Emmanuel Hugonnet (@ehsavoie, G+, blog) who is the creator of the plugin.