Red Hat
Aug 19, 2013
by kborchers

We have been busy the last 6 weeks and this release is a big one. To help you navigate this post and get to the parts that most interest you, here is a list of the items covered.


SimplePush is a new specification and protocol coming out of the Mozilla camp that we are really excited about. In short, SimplePush gives Firefox OS and soon Firefox Desktop and Mobile browsers the ability to receive push notifications just like native mobile applications. The spec is much simpler than the current Push API draft specification being developed in that it is more like a basic ping to the client letting it know that something needs attention but then leaving it up to the client how to handle that notification. There is no message in the notification other than a simple version number which the client can use to verify that something has changed.

We believe that push messaging on the web will be an important part of web apps in the near future and with that in mind, we have created our SimplePushClient as part of the AeroGear JavaScript library, as well as our own SimplePush Server following the protocol as laid out by Mozilla. Our client will work just fine with Mozilla’s SimplePush server but we also wanted to provide another server option both for security (some companies would like more control over the push environment) and as a way to set up completely internal push networks. For example, a company with an internal app with a need for push notifications could deploy a SimplePush server on their internal network/VPN and have push messaging capability to their web apps without having to contact an outside server.

With these tools, our hope is to first help bring push messages to web apps in all browsers and second, to hopefully encourage developers to use these APIs, learn what they like and don’t like about them and then hopefully be the catalyst to encourage browsers to implement these features natively. Go grab the source from the links above or grab the SimplePushClient as part of the full AeroGear.js download or from Bower* and let us know what you think!

* To install via bower, after installing bower from the link above:

bower install aerogear


Along with our SimplePush offering, the team has been hard at work to create a quick and simple way of managing push messaging across multiple networks. To that end, today we are releasing our UnifiedPushClient which works with our also newly released UnifiedPush server as part of AeroGear.js 1.2.0.

The UnifiedPushClient provides and easy to use API for registering SimplePush endpoints registered through our SimplePushClient with a central service which will in turn manage sending push messages not only to our web apps but also iOS (APNS) and Android (GCM) applications as well. For a more thorough breakdown of UnifiedPush, see this blog post. To start using the JavaScript client, you can download AeroGear.js or use Bower.

Integration Testing and CI

A lot of work has been done to improve the testing of AeroGear.js. We have created a new integration test repo which contains QUnit tests for the pieces of the library that interact with other libraries and servers. There are also scripts there that will download or clone the servers and fire them up as needed and all of this is orchestrated by the amazing tool, Grunt.

Related to this effort, we have also set up a continuous integration strategy by way of Travis CI. Using commit hooks on Github, coupled with the environment provided by Travis, now every time a new commit is pushed to the master branch of AeroGear.js, a build is performed and all of the unit and integration tests are run to be sure anything added to the library doesn’t break anything else.

Documentation Updates

Outside of the usual documentation updates that come with releasing a new version, some effort has been made to give a bit more information about each component of the library. Specifically, a feature stability rating has been added to each part of AeroGear.js to give people an idea of how they can/should use it. There are 3 stability ratings as explained in this excerpt from the updated project README file:

  • Experimental – This feature is new and has not been thoroughly tested outside of development. This feature could be changed or removed at any time. Use of these features in a production environment is at your own risk.
  • Stable – This feature has existed for a full release cycle and has been thoroughly tested. These features are considered safe for use in production environments.
  • Deprecated – This feature is being removed or replaced. As with experimental features, these features could be removed at any time and their use in production environments is at your own risk. For features being replaced, it is recommended to update to the next version and begin using the new feature.

Change log / JIRA Resolutions

Now we get into the nitty-gritty of the release. Below you will find a list of commits from the git repo and a list of resolved JIRA tickets. This represents all of the changes to AeroGear.js in the 1.2.0 release.


  • Fixed typo in README
  • Build: Add missing integration test dev dependencies
  • Build: Add back missing qunit task
  • Build: Add integration tests for SimplePush
  • Add @status to all components for feature stability reporting
  • README: Add SimplePush and UnifiedPush documentation as well as feature stability definitions
  • Build: Remove hyphens from folder names and update build for consistency
  • updating JS doc to reflect the SimplePush specific ‘simplePushEndpoint’ URL attribute
  • Build: Remove failOnError causing false failures and remove quotes around stop parameter as they don’t help
  • Build: Add failOnError to grunt-shell commands
  • Build: Pass stop parameter as a string
  • Build: Don’t run integration on default build and don’t mix single and double quotes
  • Build: Remove test config and uncomment
  • Build: Break up integration tests by server type and control their execution from here
  • Build: Try reversing the server start order
  • Notifier Tests: Capitalization
  • Build: Fix shell task to kill java processes after the servers are no longer needed to allow grunt to continue processing
  • Build: Add dev dependency on grunt-contrib-connect for running integration tests
  • Notifier Tests: Add initial SimplePush tests
  • SimplePush: JSDoc tweaks
  • Notifier:SimplePush – Don’t store the pushEndpoint for security
  • SimplePush – Minor API changes for better polyfill behavior
  • SimplePush: Add documentation
  • Build: Remove old integration tests
  • Notifier:SimplePush – Add comments and updated JSDoc
  • Merge branch ‘master’ into Notifier
  • Pipeline: Add getAuthenticator method to retrieve the associated authenticator for a pipe. Fixes AGJS-63
  • SimplePush – Move navigator object modification into the connect callback to prevent accidental early use
  • SimplePush – Use options object instead of individual parameters and add a reconnect method for use when a connection is lost
  • Notifier:SimplePush – Add onClose callback to handle disconnection from SimplePush server and add a timeout to the triggering of registration success messages on previously registered channels
  • UnifiedPush: Use metadata object as argument in registerWithPushServer, more error checking and add JSDoc
  • adding http basic to the unregister()
  • SimplePush: Refactor to use a connect callback to simplify API and elliminate race conditions
  • SimplePush: Clean up hello channel registration and duplicate eventing
  • Fixes irc notifications
  • Build: Add condition to integration test folder removal
  • Build: Add command to remove the aerogear-js-integration folder to get a fresh clone on each run
  • Add the aerogear-js-integration folder to gitignore
  • Build: Add IRC notifications back to Travis config
  • Build: Update shell config to checkout aerogear/aerogear-js-integration master branch
  • Inclusion of missing tasks for travis
  • Initial task to trigger integration tests on Travis
  • Build: Remove integration test option as it will no longer work with the new Travis config for integration tests
  • SimplePush: Always send channelIDs on hello even if empty
  • make travis only build master branch
  • SimplePush: Change channels to channelIDs in hello message
  • Merge remote-tracking branch ‘abstractj/info’
  • Update outdated reference to JIRAs
  • Merge branch ‘master’ into Notifier
  • SimplePush: Refactor to properly handle reregistered channels
  • Build: Config push builds
  • Re-add external UUID lib
  • typo fix
  • Merge branch master into Notifier
  • Add external UUID library for ID generation in SimplePush
  • SimplePush – Remove unnecessary IIFE
  • Build: Fix failed rebase for simplePush concat
  • Build: Add btoa polyfill, base64.js
  • Add Notifier and SimplePush tasks to build
  • Notifier: Remove individual IIFEs which were causing errors by referencing libs that may not necessarily be needed or used at that time. Fixes AGJS-48
  • Remove unnecessary UUID library. Fixes AGJS-49
  • Build: Add Notifier vert.x integration tests
  • Notifier:vertx – Add send method. Fixes AGJS-50
  • Build: Add Notifier STOMPWS adapter integration tests to build and update custom tasks
  • Notifier:StompWS – Add protocol option to be able to specify a STOMP protocol
  • Build: Put integration tests behind a flag to prevent constant CI failures
  • SimplePush: Remove dependency on Unified Push as these should be independent. Fixes AGJS-44
  • Merge master into Notifier
  • Build: Add btoa polyfill, base64.js
  • Adding http_basic to device/channel registration
  • The alias key is no longer named ‘clientIdentifier’, the server is looking for the ‘alias’ key now
  • Removing unneeded check for ‘registered’; We now just perform straight POST, against common URL
  • Build: Add Notifier, SimplePush and Unified Push to Gruntfile
  • Notifier:SimplePush – Fix channel unregistration handling
  • Relax .jshintrc to allow callback creation in a loop
  • Notifier:SimplePush – Throw register and unregister errors
  • Add Notifier and SimplePush tasks to build
  • Merge branch ‘master’ into ‘Notifier’
  • UnifiedPush: Change registration error to a string
  • SimplePush: Add another todo about using native implementation
  • UnifiedPush: Add alias to device registration and require it for non-broadcast message types
  • UnifiedPush: Only use POST when registering or updating device registration
  • SimplePush: Rename pushNetworkURL to simplePushServerURL and add unifiedPushServerURL
  • SimplePush: Use http instead of ws for SockJS
  • Notifier:SimplePush – Convert to use SockJS instead of vanilla WebSockets to work across browsers
  • Adding the new header name for the ag-mobile-variant
  • Move unified push registration/unregistration to separate module. Fixes AGPUSH-8
  • Notifier:SimplePush – Add notification acknowledgments
  • SimplePush: Add ability to re-register endpoints with the unified push server. Fixes AGPUSH-5
  • SimplePush – Cleanup and use re-registration updates made in Notifier
  • Notifier:SimplePush – First pass at uaid reuse and channel re-registration
  • SimplePush: Move config off of AeroGear object to avoid reset and some other minor cleanup
  • Notifier:SimplePush – Build channel from message contents
  • SimplePush: Add unified push server registration
  • SimplePush: Update to use new SimplePush adapter for Notifier
  • Notifier: Add SimplePush adapter
  • SimplePush: Rework and add missing items to further match the SimplePush spec
  • SimplePush: Refactor to follow Mozilla’s API placing SimplePush on the navigator object to act as a proper pollyfill
  • SimplePush – Only store session ID and provide channel prefix
  • SimplePush – Add first draft of SimplePush API

JIRA Resolutions

Original Post