tree: 76708f9958a2c7c940a8168e6fcff95c9a14815a [path history] [tgz]
  1. app/
  2. docs/
  3. test/
  4. .bowerrc
  5. .editorconfig
  6. .gitattributes
  7. .gitignore
  8. .jshintrc
  9. .travis.yml
  10. app.js
  11. bower.json
  12. config.js
  13. Gruntfile.js
  14. karma-e2e.conf.js
  15. karma.conf.js
  16. package.json
  17. prod.sh
  18. README.md
web/mrmonitor/README.md

Map Reduce Monitor

Map Reduce Monitor Web Application. Implemented with Node.js and AngularJS.

Map Reduce Monitor Web Application

Configuration

config.js has application configuration.

Minimum required configuration:

  • Hadoop ResourceManager

  • Haddop History Server

  • WebSocket URL (DataTorrent Gateway address)

Prerequisites

The following should be running:

Notes

It may take 10+ seconds to see data on the first load (Map Reduce Java application starts polling Hadoop REST API and then publishes it through DataTorrent Gateway WebSocket).

Running Application in Development Mode

Install dependencies:

   $ npm install

Install Bower dependencies:

   $ bower install

Start Node.js server:

   $ node app

Application will be available at http://localhost:3000

Building Application

Application is built with Grunt (it creates dist folder with optimized JavaScript/CSS).

   $ npm install -g grunt-cli
   $ grunt

Running Application in Production Mode

In this mode resources are served from dist folder.

  1. Install Node.js.

  2. Install npm dependencies

   $ npm install
  1. Install forever tool
   $ npm install -g forever
  1. Start Node.js Server (see prod.sh)
   $ NODE_ENV=production PORT=3000 forever start app.js

Tips

Running Node.js as a daemon with forever

   $ npm install forever -g
   $ forever start app.js
   $ forever list
   $ forever stop <uid>

Running Node.js on different port

   $ PORT=3001 node app

Links

Node.js Software platform built on JavaScript runtime

Express Node.js web framework

forever Node.js daemon/continuous running/fault tolerance

AngularJS JavaScript framework

Bower Package manager for the web

Grunt JavaScript Task Runner

Yeoman Webapp generator

Google Charts Charts by Google

License

Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.