"Since Cloud Expo is running the week of June 10, we thought it'd be a great idea to schedule our Meetup this week. That way, if you have colleagues, friends, or family in town that week for the Expo, you can invite them to join you!" With those words, the OpenStack New York Meetup Group's organizer's launched a landing page this week where anyone interested can register for the June 12 evening event.| By Craig Conover | Article Rating: |
|
| October 25, 2012 09:00 AM EDT | Reads: |
4,827 |
WaveMaker, acquired by VMware in March 2011, is a free, open source rapid application development environment for building, maintaining and modernizing business-critical Web 2.0 applications.
PubNub, a privately held company, is a fast real-time Infrastructure-as-a-Service for building real-time web and mobile apps.
Cloud Foundry is an open Platform-as-a-Service, providing a choice of clouds, developer frameworks and application services. Initiated by VMware, with broad industry support, Cloud Foundry makes it faster and easier to build, test, deploy and scale applications. It is an open source project and is available through a variety of private cloud distributions and public cloud instances, including CloudFoundry.com.
Introduction
I've been using WaveMaker since I started working at the startup in 2008 and it has been a great IDE for quickly creating robust enterprise AJAX Web applications integrating SQL databases, and SOAP/REST Web Services. Along came Cloud Foundry and deploying those applications on a scalable platform became just as quick and easy as WaveMaker made it to build them. Add PubNub to the equation and you get the power of real time messaging in an instant. No complicated servers to configure and no expertise required to start using the service - just a few lines of code to start sending and receiving messages.
In this tutorial I will walk you through how to build and deploy a basic chat room application in under 15 minutes using PubNub, WaveMaker, and Cloud Foundry. You can deploy to whatever application server platform you like, however, in this tutorial, we are going full-cloud so there will be no installation required. WaveMaker Studio runs in Cloud Foundry, PubNub's messaging service is cloud-hosted, and we'll be deploying to Cloud Foundry, so no need to install an app server either.
Here is what you will need:
A Free Cloud Foundry account: https://my.cloudfoundry.com/signup
At the link above, you can request a new Cloud Foundry account and confirmation email is sent. Remember your account login because you will need it when you deploy your app to Cloud Foundry from WaveMaker.
WaveMaker 6.5 Installed: http://wavemaker.com/downloads/
The latest version of WaveMaker installer is available at the the above link.
A Free PubNub account: http://www.pubnub.com/
Note: you actually don't need this because we will just be using the demo keys, but you will want one by the time you finish this tutorial.
Let's get started - hit the start button on your stopwatch...
Project Setup
1. Create a new project in WaveMaker named quickchat

2. In a text editor, open the index.html file of your project
(look in <wavemaker_install_dir>/projects/quickchat/webapproot)
and add the following div and script elements immediately following the the script tag containing "project.a.js" (if you use your own keys, just replace demo with your "pub" and "sub" keys provided to you):
<div pub-key="demo" sub-key="demo" ssl="off" origin="pubsub.pubnub.com" id="pubnub"></div>
<script src="http://pubnub.s3.amazonaws.com/pubnub-3.3.min.js"></script>
3. Save the file and close.
Create the User Interface
Back in WaveMaker, add UI widgets (DnD from the palette to the canvas) to your Main page and configure as follows (expand the "Editors" node on the palette):
1. Text Area
name: taChat
caption: Chat Messages
readonly: checked
2. Text
name: tfMessage
caption: Message
3. Button (top of the palette)
name: btSend
caption: Send

Feel free to make this UI as pretty as you like, but hit the pause button on your stop watch - this is not part of the "get 'er done in under 15 minutes" promise I made. The focus is on a basic chat app - nothing fancy.
Add a Dash of PubNub
Now it's time to write a little code - and I mean a little.
- Select the btSend button
- Open the "Events" section of the property panel
- To send (publish) messages to a channel, we need to add the PUBNUB.publish method in the btSelect button's onclick event. Select "JavaScript Event" for the "onclick" event:

... this will open the page's source editor with the cursor ready to add some code in the btSendClick event. Now add the following code:
PUBNUB.publish({
channel: "quickchat",
message: main.tfMessage.getDataValue()
});
4. To receive messages (yours and other subscribers), we need to subscribe to messages on the channel those message are being published to. Just above that click event you just added code to, there is a "start" function. Add the following code in there:
PUBNUB.subscribe({
channel: "quickchat",
callback: function(message) {
var data = main.taChat.getDataValue();
main.taChat.setDataValue(
message + (data ? "<br>" +data : ""));
}
});

Quick Test Run
Before deploying to Cloud Foundry, let's do a quick test run locally to see if all in in working order. As long as you can hit www.PubNub.com from your system, then it should work. From WaveMaker:
- Click the Run (or Test) button - if no errors, the app will be loaded in another browser window or tab.
- Once launched, enter some text in the Message text field and click the Send button - you should see the message quickly appear in the Chat Messages text area.
- Send a few more messages - the new messages should be inserted at the top of the Chat Messages text area.
- Open another browser window (preferably another brand of browser to demonstrate separate/unique client access to the app) and copy/paste the URL from your first test run window to the new browser window and launch a second instance of the app. Now send some new messages from there - you should see the messages appear in both browser windows relatively at the same time.

Note: Now remember that you are sending (publishing) messages to the PubNub server (somewhere in the cloud) using your PubNub account on the "quickchat" channel and those messages are being sent to all subscribers on that channel in your account (back to the the two browsers you have open on your system).
Deploy to Cloud Foundry
If the test run went well, then it is time to deploy the app to Cloud Foundry.
- Select WaveMaker menu option: File > Deploy Project > New Deployment
- The Deployment Type dialog is displayed: select the Cloud Foundry option and click OK
- The Cloud Foundry Account Info dialog is displayed: enter your CF username and password and click OK.
- The Settings form is displayed: change the Application Name to something that will be unique across all of the Cloud Foundry (quickchat is already taken by me). Try using your initials as a prefix to the app name: cvcquickchat, for example. Or use the Generate URL button to create a random URL that should be unique.

5. Click the Deploy Now button and wait for it to finish.
NOTE: This will take a few minutes, especially the first time you deploy because it has to generate the WAR file with all the jar files (minimal size around 25 MB) and then upload, stage and start the app in your Cloud Foundry account. Fortunately, many of the jar files in your app already exist in Cloud Foundry which maintains a repository of all these resources (from all apps in all CF accounts) so the entire app doesn't have be uploaded with every deployment.
6. When WaveMaker finishes deploying to Cloud Foundry, it will display a dialog with the URL to your app. Click it and test it as before, but this time, invite someone else from somewhere else (or a few others if you like) to join your chat room. They will probably tell you it is the biggest POS chat room they've ever seen, but just tell them it took you less than 15 minutes to create it - then send them a message with your POS chat room app telling them how you really feel about their feedback ;)
Summary
Who would have thought that creating a scalable, real time messaging Web app could be that simple.
- Web Apps made easy - by WaveMaker
- Real-Time Messaging made easy - by PubNub
- Deployment made easy - by Cloud Foundry
Stay tuned to here for new installments of this series where I will provide details on how to make this chat room app more robust with a cleaner, more robust UI, using more features of the PubNub messaging service and the WaveMaker Studio as well as developing your WaveMaker apps directly in Cloud Foundry (WaveMaker Studio hosted in Cloud Foundry).
Published October 25, 2012 Reads 4,827
Copyright © 2012 SYS-CON Media, Inc. — All Rights Reserved.
Syndicated stories and blog feeds, all rights reserved by the author.
More Stories By Craig Conover
Craig Conover is a Senior Tech Labs Apps Engineer at VMware, Inc. working as a lead developer on enterprise applications integrating WaveMaker with backend systems like vCenter Orchestrator and Active Directory, deployed in a private Cloud Foundry platform.
While at WaveMaker Software, acquired by VMware in 2011, he was a sales engineer and delivered online and onsite courses. He also helped start the professional services department as lead developer and application architect on many large scale enterprise applications using WaveMaker as the key technology integrating with various backend technologies for companies such as Pioneer Natural Resources, Macy’s, ProLogic, Best Western, Nationwide and SAIC.
Craig has been in the software industry since 1992. He worked for NetDynamics, which pioneered the application server, and was acquired by Sun Microsystems. While at NetDynamics Craig produced course materials as an education consultant and instructor certifier. Craig then continue his career with Sun advancing his Java career for 10 years as a NetDynamics sustaining engineer and NetBeans tools engineer in the Web Application Framework and UML modules.
"Since Cloud Expo is running the week of June 10, we thought it'd be a great idea to schedule our Meetup this week. That way, if you have colleagues, friends, or family in town that week for the Expo, you can invite them to join you!" With those words, the OpenStack New York Meetup Group's organizer's launched a landing page this week where anyone interested can register for the June 12 evening event.May. 22, 2013 01:45 PM EDT Reads: 767 |
By Elizabeth White May. 22, 2013 01:00 PM EDT Reads: 969 |
By Pat Romanski “Open source has always provided a number of benefits, including easing adoption costs, propagating a better understanding of the technology, and allowing for faster evolution and commercialization of products and services based on it,” noted Terry Woloszyn, Founder & CEO, Leeward Security Ltd., in this exclusive Q&A with Cloud Expo Conference Chair Jeremy Geelan. “This is clearly evident with the OpenStack and CloudStack,” Woloszyn continued, “and others that have been quickly commercialized as...May. 22, 2013 11:00 AM EDT Reads: 1,185 |
By Liz McMillan SYS-CON Events announced today that OpenStack will exhibit at SYS-CON's 12th International Cloud Expo, which will take place on June 10–13, 2013, at the Javits Center in New York City, New York. OpenStack software controls large pools of compute, storage, and networking resources throughout a datacenter, all managed by a dashboard that gives administrators control while empowering their users to provision resources through a web interface.
OpenStack powers some of the most widely-used SaaS app...May. 22, 2013 11:00 AM EDT Reads: 886 |
By Elizabeth White SYS-CON Events announced today that BUMI (Backup My Info!), the premium provider of managed online backup and recovery solutions for small to mid-sized businesses, will exhibit at SYS-CON's 12th International Cloud Expo, which will take place on June 10–13, 2013, at the Javits Center in New York City, New York.
Manhattan-based BUMI (Backup My Info!) is a premium managed service provider specializing in online data backup and recovery. Founded in 2002, the company's data backup and recovery serv...May. 22, 2013 10:59 AM EDT Reads: 533 |
By Pat Romanski SYS-CON Events announced today that nfina Technologies, a provider of highly reliable cloud server products, will exhibit at SYS-CON's 12th International Cloud Expo, which will take place on June 10–13, 2013, at the Javits Center in New York City, New York.
nfina Technologies develops, manufactures, and markets highly reliable cloud server products, designed to solve the most demanding data center requirements in mission-critical cloud applications. Nfina’s staff has decades of experience in co...May. 22, 2013 10:00 AM EDT Reads: 877 |
By Pat Romanski In his session at the 12th International Cloud Expo, Dave Eichorn, Global Data Center Practice Head at Zensar, will share a case study describing how a utility services company handled the migration of its Microsoft platform to the cloud. Challenged with the time-consuming task of opening operations out of temporary offices, this company struggled with the need to simultaneously access data that was accumulated from a vast amount of data-intensive jobs. Zensar migrated the company’s application ...May. 22, 2013 09:54 AM EDT Reads: 598 |
By Liz McMillan “Social, mobile, analytics and cloud can’t be looked at as distinct technology trends; they are facets of the same movement and an everyday reality for consumers and businesses alike,” said Craig Sowell, IBM VP of SmartCloud Marketing, in this exclusive Q&A with Cloud Expo Conference Chair Jeremy Geelan. “This means that businesses need to start looking at trends as one: cloud is the delivery, analytics is the unique insight, social is a shareable service, and mobile is the ubiquitous access.”
...May. 22, 2013 09:16 AM EDT Reads: 770 |
By Liz McMillan Organizations across the world are increasingly starting to see the benefits of moving more and more services to the cloud. The focus on the cost-saving potential of cloud is rapidly shifting to completely transforming the business with cloud. As organizations are investing enormous sums on technology they are starting to realize that in order to maximize the return on investment and accelerate the business transformation process the first area of focus should be people. By ensuring the organiza...May. 22, 2013 09:00 AM EDT Reads: 754 |
By Elizabeth White SYS-CON Events announced today that Wowrack will exhibit at SYS-CON's 12th International Cloud Expo, which will take place on June 10–13, 2013, at the Javits Center in New York City, New York.
Wowrack’s core expertise lies in high-availability Private and Public Cloud IaaS Hosting Solutions. Wowrack provides a true Hybrid service – where business release all IT management and hardware provisioning – taking the data center and server system administrative headaches off our customer’s shoulders. ...May. 22, 2013 08:45 AM EDT Reads: 890 |
- Cloud People: A Who's Who of Cloud Computing
- Cloud Expo New York Speaker Profile: Dave Linthicum – Cloud Technology Partners
- Cloud Expo New York: Cloud Is Changing the Economics of Business
- Windows Azure IaaS Reaches General Availability
- Cloud Expo New York Speaker Profile: Nicos Vekiarides – TwinStrata
- AMD and Adobe Collaborate on Upcoming Version of Adobe Premiere Pro Software to Enable Breakthrough Video Editing Performance Through Open Standards
- State and Local Governments Adopt Microsoft Dynamics CRM to Improve Citizen Service Delivery
- Enterasys Spotlights SDN's Impact on Traditional Networking in Upcoming Webinar
- New Relic Q1 2013 Blazes Past Growth Targets and Reaches 40,000 Active Customer Accounts
- Best CIO Practices Shared from SHI’s Customers
- Cloud Expo New York: Deploying Hybrid Cloud for Performance and Uptime
- Cloud Expo New York: Delivering Digital Marketing on the Cloud
- Cloud People: A Who's Who of Cloud Computing
- Cloud Expo New York: Best CIO Practices Shared from SHI’s Customers
- Cloud Expo New York Speaker Profile: Dave Linthicum – Cloud Technology Partners
- Cloud Expo New York: Cloud Is Changing the Economics of Business
- Cloud Expo New York: How to Use Google Apps Script
- Windows Azure IaaS Reaches General Availability
- Cloud Expo New York Speaker Profile: Nicos Vekiarides – TwinStrata
- AMD and Adobe Collaborate on Upcoming Version of Adobe Premiere Pro Software to Enable Breakthrough Video Editing Performance Through Open Standards
- Cloud Computing Bootcamp at Cloud Expo New York
- State and Local Governments Adopt Microsoft Dynamics CRM to Improve Citizen Service Delivery
- Enterasys Spotlights SDN's Impact on Traditional Networking in Upcoming Webinar
- New Relic Q1 2013 Blazes Past Growth Targets and Reaches 40,000 Active Customer Accounts
- The Top 150 Players in Cloud Computing
- What is Cloud Computing?
- Six Benefits of Cloud Computing
- The Top 250 Players in the Cloud Computing Ecosystem
- Twenty-One Experts Define Cloud Computing
- What's the Difference Between Cloud Computing and SaaS?
- Virtualization Conference Keynote Webcast Live on SYS-CON.TV
- The Future of Cloud Computing
- A Brief History of Cloud Computing: Is the Cloud There Yet?
- GDS International: Global Warming Scam?
- Cloud Expo Europe 2009 in Prague: Themes & Topics
- Cloud Computing Expo 2009 West: Call for Papers Now Closed








“Open source has always provided a number of benefits, including easing adoption costs, propagating a better understanding of the technology, and allowing for faster evolution and commercialization of products and services based on it,” noted Terry Woloszyn, Founder & CEO, Leeward Security Ltd., in this exclusive Q&A with Cloud Expo Conference Chair Jeremy Geelan. “This is clearly evident with the OpenStack and CloudStack,” Woloszyn continued, “and others that have been quickly commercialized as...
SYS-CON Events announced today that OpenStack will exhibit at SYS-CON's 12th International Cloud Expo, which will take place on June 10–13, 2013, at the Javits Center in New York City, New York. OpenStack software controls large pools of compute, storage, and networking resources throughout a datacenter, all managed by a dashboard that gives administrators control while empowering their users to provision resources through a web interface.
OpenStack powers some of the most widely-used SaaS app...
SYS-CON Events announced today that BUMI (Backup My Info!), the premium provider of managed online backup and recovery solutions for small to mid-sized businesses, will exhibit at SYS-CON's 12th International Cloud Expo, which will take place on June 10–13, 2013, at the Javits Center in New York City, New York.
Manhattan-based BUMI (Backup My Info!) is a premium managed service provider specializing in online data backup and recovery. Founded in 2002, the company's data backup and recovery serv...
SYS-CON Events announced today that nfina Technologies, a provider of highly reliable cloud server products, will exhibit at SYS-CON's 12th International Cloud Expo, which will take place on June 10–13, 2013, at the Javits Center in New York City, New York.
nfina Technologies develops, manufactures, and markets highly reliable cloud server products, designed to solve the most demanding data center requirements in mission-critical cloud applications. Nfina’s staff has decades of experience in co...
In his session at the 12th International Cloud Expo, Dave Eichorn, Global Data Center Practice Head at Zensar, will share a case study describing how a utility services company handled the migration of its Microsoft platform to the cloud. Challenged with the time-consuming task of opening operations out of temporary offices, this company struggled with the need to simultaneously access data that was accumulated from a vast amount of data-intensive jobs. Zensar migrated the company’s application ...
“Social, mobile, analytics and cloud can’t be looked at as distinct technology trends; they are facets of the same movement and an everyday reality for consumers and businesses alike,” said Craig Sowell, IBM VP of SmartCloud Marketing, in this exclusive Q&A with Cloud Expo Conference Chair Jeremy Geelan. “This means that businesses need to start looking at trends as one: cloud is the delivery, analytics is the unique insight, social is a shareable service, and mobile is the ubiquitous access.”
...
Organizations across the world are increasingly starting to see the benefits of moving more and more services to the cloud. The focus on the cost-saving potential of cloud is rapidly shifting to completely transforming the business with cloud. As organizations are investing enormous sums on technology they are starting to realize that in order to maximize the return on investment and accelerate the business transformation process the first area of focus should be people. By ensuring the organiza...
SYS-CON Events announced today that Wowrack will exhibit at SYS-CON's 12th International Cloud Expo, which will take place on June 10–13, 2013, at the Javits Center in New York City, New York.
Wowrack’s core expertise lies in high-availability Private and Public Cloud IaaS Hosting Solutions. Wowrack provides a true Hybrid service – where business release all IT management and hardware provisioning – taking the data center and server system administrative headaches off our customer’s shoulders. ...
“The last time I checked, people do not change their social security numbers very often...”
While in constant debate over data encryption and ease of access, I encountered a train of thought that made my jaw drop. A tradeshow attendee suggested encrypting everything, but just use a weak algorithm; ...
Don and I have four children, all of whom have had the fortune to take piano lessons (I'm not sure if the youngest would agree he's fortunate at this point in his life but at five, he's not really able to answer the question with any degree of wisdom, anyway. Come to think of it, not sure the other ...
Our prior post, A Roadmap to High-Value Cloud Infrastructure: Disaster Recovery and Data Protection, discussed both the benefits and limitations of a cloud-based disaster recovery (DR) strategy. As we highlighted last week, traditional disaster recovery options leave open a huge hole: At one extreme...
Online collaboration has evolved during the last decade, delivering even greater value -- thanks to a new generation of business technology applications. Forbes Insights released "Collaborating in the Cloud," a Cisco-sponsored study examining the ways business leaders increasingly look at cloud coll...
New technologies allow schools, colleges and universities to analyze absolutely everything that happens. From student behavior, testing results, career development of students as well as educational needs based on changing societies. A lot of this data has already been stored and is used for statist...
A recent Gartner study states that the function of the modern CIO is in flux and that his or her future focus must incorporate digital assets (aka cloud-based data and applications) to remain relevant. Towards the goal of riding the sea change a compiler of stacks to a broker of business needs, secu...
In the coming years, big data will change the way organisations and societies are operated and managed. Big data however, is not the only trend that will impact significantly how organisations operate. Another major trend at the moment is gamification. Gamification will change the way organisations ...
We all talk about cloud differently, but is there a way we should be speaking about this tech?
Cloud computing is now a widely reported, if not accepted, IT movement that, depending on who you talk to, has changed or is changing the way businesses utilize infrastructure.
The age of data center automation is upon us. Whether it's cloud or SDN or devops in general, automation as a means to achieve efficiency and, one hopes, free up resources that can be then redirected to focus on innovation.
As is always the case when we begin to move further upwards, abstracting ...












