Java REST Options

REST with or without a Web Container

CXF2 or RESTLet or RESTEasy or JAX-RS (Jersey) or DropWizard or Spring Boot or …  There have been an number of options for a while.   Spring Boot and Drop Wizards

are very cool because of the simple deploy and lack of need for a cumbersome EAR or WAR deploy to a JEE server.  DropWizard also

has a ton of features and built-in metrics.  Resthub is very cool too, but not well supported.  JAX-RS works nice if you use Glassfish +

NetBeans 7.4 + JEE 7.  Since that lets you create REST client and server and the client can be HTML5 and is mostly generated for you.  It

will also build REST services for you from existing entities or relational tables.  I wish it had a wizard to do that easily from NoSQL

entities.   NodeJS has a nice REST client.   Also you can try your hand at developing REST in NodeJS or Cujo REST.   A REST client from JavaScript is easy, here is

a nice article on RestJS with Spring.


Spring Boot


mvn archetype:generate -DarchetypeGroupId=org.resthub -DarchetypeArtifactId=resthub-jpa-backbonejs-archetype -DarchetypeVersion=2.1.4

mvn jetty:run


Other Links



Links of the Day 09-OCT-2013

Lambas / Java 8


Feature Toggle

Testing Async JavaScript


Web Page Testing


SonarQube – CASS


Vert.x + Yoke (Polyglot Answer to Node.js + Express) + WebSockets on many clouds

Vert.x 2.0 Developing Vert.x with Maven · vert-x/vert.x Wiki

Yoke a middleware framework for Vert.x: Java-Tutorial

zznate/nodej · GitHub

Edge Framework –

Vert.x takes first step towards Eclipse Foundation

cloudfoundry-samples/vertx-vtoons · GitHub

The WebSocket API

Nodyn: Node.JS for the JVM

Vert.x Installation Guide

zznate/intravert-ug · GitHub

Netty: Home

Yoke a middleware framework for Vert.x: Benchmark

Vert.x 2.0 Developing Vert.x with Maven · vert-x/vert.x Wiki

Getting Started With vertx ( – an Alternative to node.js | Web Builder Zone

zznate/edge · GitHub

CloudBees-community/vertx-clickstack · GitHub


Vert.x – the Node.js for Java in the Cloud | OpenShift by Red Hat

Deploying vert.x Applications to Cloud Foundry | Blog

Fun with Scala and Vert.x | Javalobby

sockjs/sockjs-client · GitHub

Reactor pattern – Wikipedia, the free encyclopedia

Vert X Vs Node Js – Latest Technology News | ::

openshift-quickstart/vertx-openshift-quickstart · GitHub

purplefox/openshift-vertx · GitHub

Running a Java Vert.x app on Heroku

Using web workers – Web developer guide | MDN

Asynchronous concurrency with vert.x – part 1 | synyx – Blog

Asynchronous concurrency with vert.x – Part 2 | synyx – Blog

yoke/example/persona at master · pmlopes/yoke · GitHub

yoke/example/kitcms at master · pmlopes/yoke · GitHub


Spring MVC + Modern HTML5

Tobacco tries it’s best to always include the latest release versions of most popular client libraries.

Latest Tobacco 1.0.12 charges you with Spring 3.2.2, Twitter Bootstrap 2.3.1, jQuery 1.9.1 and Backbone.js 1.0.0

Tobacco Maven Architype for building a project


Cool Links of the Day – Build Your First Mobile App with PhoneGap Build

Nullzzz – FRP, Bacon.js and stuff: Bacon.js Tutorial Part I : Hacking With jQuery

raimohanska/bacon.js · GitHub – Synchronising Multithreaded Integration Tests revisited – Task.js Asynchronous Tasks In JavaScript

Understanding Java Garbage Collection and what you can do about it – YouTube – Algorithm of the Week: Shortest Path with Djikstra

MongoDB – Updating Records – CodeProject – Sencha Touch 2 Stores – Editing Model Instances and Reverting Changes – String Utility Classes in Java – 5 Talks To Learn More About Node.js – JPA/JPQL: Intermediate Queries with @NamedQuery – How RESTful Is Your REST?

Native Win32 ports of some GNU utilities

UnxUtils | Free software downloads at


Node.js for Production

Coding Guides

HP Anywhere (Java + JavaScript)

HP Anywhere

Review by Timothy Spann

Basic Usage

1.1           IDE




1.2           NOTE

  • Fix required:  HP Anywhere added to maven.bat


  • Only runs on Windows.  Windows Only Server
  • Only for developing single page applications (SPA) with Java back-end and JS/HTML5/CSS front-end.


1.3           Technology List

  • Eclipse juno
  • jdk 1.7
  • maven
  • tomcat
  • H2
  • jersey
  • enyo js
  • slf4j
  • apache commons
  • xerces
  • json
  • sencha
  • jax-ws
  • ant
  • curl
  • spring 3.0.5
  • jersey
  • junit 4.8
  • JEE
  • JAXB
  • DOM4J
  • Lucene
  • JSTL
  • PhoneGap
  • POI
  • Velocity
  • STAX
  • Xalan
  • Joda Time
  • Hibernate
  • GraniteDS
  • Jackson
  • JTDS
  • JQuery
  • JDOM
  • Sencha Touch
  • Cassandra
  • MS SQL Server

1.4           Links

HP Anywhere: Mobile Apps for the Enterprise


1.5           HP Anywhere Architecture for Developers








Book Review: Testable JavaScript

 Testable JavaScript Book Review

Testable JavaScript

By Mark Ethan Trostler
Publisher: O’Reilly Media
Released: January 2013
Pages: 274


Chapter 1 Testable JavaScript
Chapter 2 Complexity
Chapter 3 Event-Based Architectures
Chapter 4 Unit Tests
Chapter 5 Code Coverage
Chapter 6 Integration, Performance, and Load Testing
Chapter 7 Debugging
Chapter 8 Automation
First off, I want to say this is one of my favorite books. It is a great work on developing with TDD and agile with a focus on JavaScript. I am considering buying a print copy
to keep next to my computer with the GoF, Growing Object Oriented… and Release It! I am big believer in the main aim of the book to keep javascript code simple and
loosely coupled. This is not a book for those who don’t know JavaScript or have some background in Test Driven Development.

The book starts with a nice section on agile, TDD, BDD , the why’s, what’s and how’s of all the best practices for modern development. There is a very thorugh discussion of a
number of great development tools including: JSLInt, JSmeter, JSCheckStyle, YUIDoc and JSDoc. This book is great for Java developers wishing to start doing enterprise level
JavaScript on the client and server and in-between (Meteor / Derby).

I like this book also for it’s thorough coverage of best modern development practices: Code Reuse, Coupling, Metrics, Dependency Injection, auto documenation (think javadoc),
formalized softwtare inspections, coder coverage, fan-out/fan-in nd more agile practices.

One of the other strong topics in the book is Event-Based Architectures / programming. Event-based programming is great for decoupling objects. There is also great information on using and Event-Hub and as well.

Testing Topics from the Book

  • vows
  • isolation
  • scope
  • mock objects
  • positive and negative testing
  • PhantomJS for testing
  • stubs
  • spies
  • asynchronous testing
  • running tests on the client and server side

Cool Tools from the Book

Links from the Book



Today’s Links

Links of the Day

Node.JS Links


OpenShift Spring WebApp / Tomcat

OpenShift Express / Node.js




Mongodb on OpenShift
HibernateOGM / Mongodb On Openshift
Redmine (Ruby on Rails implementation) – project management SAAS
Android REST Client



Spring Tutorials – Links






New Node.JS, JavaScript, HTML5, NoSQL Links

My favorite new resource is DailyJS, always a ton of great links, libraries, tutorials, documents and more.  This is really a site that I have to visit daily.



Continuum / Analytics.js

New Streaming API for Node, Components Tutorial, Holler, GruntStart

HTML5: Server-sent events with Angular.js, Node.js and Express.js | 



Backbone.js Tutorial: Backbone.sync


JavaScript MUSIC

Substack’s Musical Node Modules – this is really cool stuff.



Using MongoDB, Redis, Node.js, and Spring MVC in a single Cloud Foundry Application

Java to Node.JSNode.js Application Development with RabbitMQ Service

Node.js on CloudFoundry

Backbone and Node.JS App


I have posted a bunch of great tech links on my Google+, check them out.





Linked List

Graphic Display of Nodes in a linked list (with bacon data)


Linked List in UML


Linked List in Pseudo Code


Linked List in Node.js (Javascript)

An implementation in Javascript.  A linked list of buffers in Node.js.  A great set of implementations for Javascript.  A computer science implementation of JavaScript.  Also a nice insertion sort in Javascript.


Linked List in Java

Java has built in Lists.  An implementation of the Singly Linked List.


Linked List in Scala

Scala has built in Lists.  A Scala list from scratch.


Linked List in Groovy

Groovy has built in Linked Lists and other Collections.

RosettaCode, An awesome site listing implementations in many languages, this is a link to linked list.




Test Driven Node.JS Development

What would a language and framework be with unit testing, BDD, and other testing methods, frameworks and systems?

So once you get beyond casual Node.JS development, you will need to start unit testing.  Node.js has a surprisingly robust and mature set of testing tools and options.  Out of the box, Node.js has Built In Assert which will let you do some basic XUnit style tests.   A step beyond that is NodeUnit, which is pretty easy to use for XUnit oriented people.  For me, it’s easy to pick up coming from doing a lot of JUnit tests.  This article is great for Using NodeUnit for Testing.  Node.js is great because so many people have developed tools, frameworks and utilities for it.  The only issue I have it some are not very mature and the options are so fragmented.  There’s no Spring framework or hibernate that garners massive usage.  So many variations and options, I wish they could work together to put together a killer Rails or Spring type group of mature, tested, interconnected tools and utilities.  Full Testing Suite – Mocha is installable via NPM and works with a CI server.  This one is pretty cool.

The source for everything testing/bdd/mocking for Node.JS is Joyent’s Testing Wiki.
There’s a number of behavior driven development tools including the polyglot tool Cucumber -> BDD Testing Tool – Cucumber.JS.  Another option is Asynchronous BDD Testing Tool – Vow.
For mocking,  Mockito Style Mock Objects – Mary Jane, looks great.   I will hope that maybe Mockito will officially support this one.
For JQuery fans, someone has ported QUnit to Node.JS [Node-Qunit]
This is just a sampling of test options.  Obviously tools like Selenium and Firebug will help you and so would JMeter and and SOAPUI.  A lot of general web testing tools are available that can do full system testing or integration testing for your Node.JS web apps.
I will be adding some examples in a future post with a github link.

Node.js and JavaScript Links

OAuth for Node.jS
Backbone hackers guide
Realtime multiplayer game in html5
Cloud Control Hosting
Deploy Node.JS to Staging
Mod Player
Node.JS Stack Trace
JavaScript Terminal
JavaScript Test Runner

Nodester Node.JS + Express + Mongo App Part 1 – Nodester

The Running Node.JS Application on a Nodester


I am still working on putting up a full application for the tutorial.  Also I will try the same application on Nodejitsu, CloudFoundry and Heroku.

The following are the basic steps for working with Nodester. It is very similiar to all the other command-line PaaS interfaces. I am running this on
Windows, but it will work in most environments.


npm install nodester-cli -g
nodester user setup <username> <password>
nodester user setkey
nodester app create <appname>
nodester app init <appname>
nodester npm install express
nodester npm install mongoose
nodester npm install

git add .
git commit -am "Ready to deploy"
git push nodester master

nodester app info
nodester app stop|start|restart
nodester app logs

For nodester they push to master for Nodester to get a new build.

Log into your Application List Page on the Administration Site for Nodester and you will see your newly added Application. Nodester has a good help system that will be useful to you while learning. The git commands are standard GIT which makes using all the cloud systems pretty similiar.

After uploading, I check the logs for errors:

nodester app logs
nodester info Showing logs for: rollerderby
New PID: 18884
Spawing /app/server.js
Running node v-0.8.1
:: nodester ::

App listening on port 19885

nodester info ok!

nodester deployed


I used there out of the box example and added a connection to my test mongo db database at MongoLab.


Link Section:

The final deployed application from this tutorial

Restify with Mongodb and Mongoose (src)

Backbone.js Boilerplate

Node.JS Mongodb Native Driver

Mongoose Driver

Mongoose Tutorial

Node.JS and Mongodb Video Tutorial

Node.JS / Mongodb / Mongoose Tutorial

Finding Documents in MongoDB with Mongoose

Node.js Tutorial

Restful API with Node.js and Mongodb + Expresss & Mongoose

Backbone.js Fundamentals

Mongoose Model Definition


HTML5 Deep Dive Canvas

Canvas Scene Graph

HTML5 Template Engine for Java/Spring

Creating 3D Games with HTML5

HTML5 Canvas Game Engine

Vector Drawing Tool

2D Games and Graphics Engine

Online HTML5 Sketch Pad

HTML5 Drawing Tool

HTML5 Game

HTML5 JS Library

HTML5 JS Animation Library

JS Library for Sound

JS Processing Language

Keyframing API for HTML5 

SVG Parser and Renderer

JS Library and Editor

MEMSQL – World’s Fastest DB

HTML5 Audio Control (Tape Player UI)

HTML5 Weekly Week #22

HTML5 Application Cache Manifest (facebook)

Modernizr Library (JS, CSS, HTML5)

MS Office Apps with HTML5

Insane HTML5 Game and Source <- Kick ass maze game

HTML5 Audio Editor

HTML5 Canvas Demo

Ninja Authoring Tool for HTML5


HTML5 Features to Use

HTML5 Canvas and Processing.JS









No, Not Python, It’s the Holy Grails…

I’ve been evaluating a few different technologies for doing some rapid web development work and recently I have been looking at the bounty of available tools, libraries, frameworks and associates of Spring.  Spring ROO and Groovy/Grails are the big two RAD tools from SpringSource and they look pretty amazing.  I don’t think I’ve found the Holy Grail of Web App development, but these two tools are really helpful in rapidly developing apps.  I am hoping someone combines Roo or Grails with Vert.x to make a really awesome alternative to Node.JS.  I like Node.JS and have been doing JavaScript for a decade, but I prefer the languages of the JVM and Vert.x’s support for multiple languages is pretty awesome.  Hmmm, Vert.x in Grails.

With the excellent STS inside Eclipse, this gives Groovy and Java a great IDE for development, testing and debugging.  And that is something that is lacking for Node.JS.  Node.JS has a few tools out there, but nothing open source, free, full of awesome mature plugins (PMD, Checkstyle, GIT, Maven, JUnit, FindBugs, …) and just plain easy to use.  Eclipse also has plugins for working with CloudFoundry, Heroku, OpenShift and other Cloud environments.

Between Grails and Roo, I really like the fact that I can remove Roo at anytime and still have a fully functionally application setup that utilizes standard Spring tools.  It’s also easier to add other cool Spring projects like Spring Social, Spring Mobile, Spring Data and more.

Both Grails and Roo support MongoDB very well and that’s great too see.  I have a few Mongo DB instances on MongoLab, MongoHQ and OpenShift.  These services all have great free developer services that are great for learning, prototyping and for tutorials.  I am really loving Heroku and OpenShift.  It’s hard to pick one, so I didn’t.  I use them both.

Vert.x + Groovy is really cool, but again not much IDE support, tools or extra libraries.  It should grow start building support now, but competition with Node.JS is pretty fierce.

Interesting, Roo vs Grails Jobs.



But if you look at just Spring (which Roo is just a tool to help with a Spring project):



There’s also some great documentation, tutorials and books on Groovy/Grails since it’s been out for a while: On the other hand, Roo is newer, but since it generates standard Spring + Java, you are really just getting a good head start on your project.

Heroku has a nice article on using both with their awesome platform:  and

I will post a Github repository of some samples soon.


More Android Information

MIT App Inventor

Using Google App Engine


Interesting Side Topic:  Android Scripting SL4A (Scripting Layer For Android)

You can use JavaScript, which makes for an interesting environment to call against at Node.JS server.

Installing the ASE (Android Scripting Environment) on the PC Emulator

Android Menus

Add a View that Display Web Pages using WebKit and Enable JavaScript

<uses-permission android:name=”android.permission.INTERNET” />

 Uri uri = Uri.parse("");
 Intent intent = new Intent(Intent.ACTION_VIEW, uri);



HTML5 Demos, Examples, RSS Readers

JavaScript API for Reading ATOM/RSS 

Code Playground 

Quick Starts for HTML5 Projects
HTML5 Boiler Plate


I am preparing to give a Brown Bag session on Node.js.

Here are some notes:

Main WebSite


Node.JS on OpenShift

Getting Started with Node.JS on OpenShift

On Windows 7, OpenShift requires CygWin and you must run from that CLI.

rhc app create –a NodeJSBrownBag –t nodejs-0.6
rhc app cartridge add –a NodeJSBrownBag –c mongodb-2.0
rhc app cartridge list
git commit –a –m “Added some source code”
git push

My existing NodeJS demo app in progress.

OpenShift / Red Hat Cloud Notes:

Add Cartridges for NodeJS, Mongo, … from the openshift website

Web Dev Framework for Node.JS

Node Debugger

Node Inspector / Web Debugger for NodeJS

BDD for Node (Vows)

Expresso TDD for Node

Unit Test Runner


Tracking NodeJS Modules

Node.JS and MongoDB for Beginners
Heroku + Node.js + MongoDB (not for free heroku)

Getting Started with MongoDB and Node.JS

Getting Started with Node.js on Heroku

Free Guide to Node.JS

Node.JS Tutorial

Node.JS Docs



Node Manual

From Java to NodeJS

Planet NodeJS

Nide Node.js IDE for CLI

VJET IDE for Eclipse

Install in Your Eclipse Using:

TypeLibs for VJET

node.js News

node.js Patterns

JavaScript Checker

JAKE Build Tool for Node.JS

Node.JS Video

Node Guide

Master Node.JS Book

3rd Party Modules

HighKick Test Runner

Async Spell Checker

Node Podcast


Stack for Linux and VMWare

Node.Js Everywhere

Web Services 2.0 on Node

There’s a CoffeeScript module.

Yahoo Mojito Ontop of NodeJs

NodeJS News


Twitter Client

JQuery for the Server