xtuple/xtuple — pull request #1891 by shackbarth (2014-09-30 19:50:21+00:00)
Title: reflect models from discovery service

The idea is, calls to the following routes should return json data that's parseable into the brower using sails-backbone. There are three problems tho with the PR that @tjwebb should look at.

https://shackbarth-470-dev.localhost/demo_dev/backbone-models
https://shackbarth-470-dev.localhost/demo_dev/backbone-models/Honorific

Problems are:
1. https://github.com/tjwebb/google-discovery-backbone/issues/1
2. I'm seeing this error the second + time the route is accessed:
```
Possibly unhandled AdapterError: Connection is already registered
at Object.module.exports.adapter.registerConnection (/home/shackbarth/git/xtuple/node_modules/google-discovery-backbone/node_modules/sails-memory/lib/adapter.js:39:60)
at /home/shackbarth/git/xtuple/node_modules/google-discovery-backbone/node_modules/waterline/lib/waterline.js:202:29
at /home/shackbarth/git/xtuple/node_modules/google-discovery-backbone/node_modules/waterline/node_modules/async/lib/async.js:125:13
at Array.forEach (native)
at _each (/home/shackbarth/git/xtuple/node_modules/google-discovery-backbone/node_modules/waterline/node_modules/async/lib/async.js:46:24)
at Object.async.each (/home/shackbarth/git/xtuple/node_modules/google-discovery-backbone/node_modules/waterline/node_modules/async/lib/async.js:124:9)
at Array.async.auto.registerConnections (/home/shackbarth/git/xtuple/node_modules/google-discovery-backbone/node_modules/waterline/lib/waterline.js:175:13)
at /home/shackbarth/git/xtuple/node_modules/google-discovery-backbone/node_modules/waterline/node_modules/async/lib/async.js:487:38
at Array.forEach (native)
at _each (/home/shackbarth/git/xtuple/node_modules/google-discovery-backbone/node_modules/waterline/node_modules/async/lib/async.js:46:24)
```
3. The discovery code is returning some data here:
https://github.com/shackbarth/xtuple/compare/xtuple:react...shackbarth:model-route?expand=1#diff-4279a638fd8b791f7a689932f2bd4cecR23
but it's not being transformed correctly.
```
{
"models": [],
"version": "0.0.0"
}
```