Hyper-V FLR UI

UI / Node / Build / Packaging

Covering

  • Overview of UI and and Node components and related tech
  • Build and packaging
  • Description of different git repos
  • Trace a call to GET /hypervisors

The UI

The UI Server (node.js)

  • node (Javascript) version 0.10.29
  • express - http server.  Serves static files and REST endpoints
  • Grunt for task automation 
  • Makes REST calls to Scala layer (messaging service) to fulfill client requests
  • Git repo is emc-rest-hypervflr

Important git repos

  • well documented on wiki

  • emc-hypervflr-gui - .html, .css, .js, and dependencies

    • final build artifact is a .tgz , gets published to Ivy

  • emc-rest-hypervflr - (.js) the node server

    • final build artifact is a .tgz, gets published to Ivy

    • uses Grunt for most build tasks, Gradle to publish

​​...

Important git repos (cont.)

  • raven-node-service - pulls the UI and Node artifacts together

    • ​written in scala
    • builds with Gradle

    • final artifact is a .jar

    • when service runs, starts node (exec)

  • raven-launcher - the final mega .jar that contains everything

    • main method is here

    • starts all services

Overview of Jenkins Build

Chain of Builds

  1. raven-emc-rest-hypervflr OR raven-hypervflr-gui
  2. raven-node-service
  3. raven-launcher
  4. integration test and deploy tasks

Tracing GET /hypervisors

  • Let's trace a GET /hypervisors through the UI and node layers
  • In repo emc-hyperflr-gui...
  • app/scripts/controllers/guiHyperVServersCtrl.js
    • has an init() method that calls loadServers()
    • which calls ...
  • app/scripts/services/hypervisorService.js
    • getHypervisors() 
    • which makes a REST call GET /hypervisors

...

Tracing GET /hypervisors (cont.)

  • in repo emc-rest-hypervflr
  • lib/hypervisors/hypervisors.js 
    • REST handler for /hypervisors
    • makes a call to the flrService (scala) GET /hypervisors

Other Misc Tips

  • Get familiar with the system by:
    • examining REST calls made by UI with browser tools
    • search emc-rest-hypervflr lib/ for REST endpoints

Questions?

HyperV FLR

By Christian Parker