/assignment-1

Homework assignment for a job position.

Primary LanguageJavaScript

downloads dashboard

Welcome! :)

How to manually install

Prerequisites: Node, Yarn, Go.

  1. cd ~/<projects_folder>
  2. git clone https://github.com/stenowtf/dd.git
  3. cd dd/dd-client
  4. yarn install or npm install
  5. yarn start or npm start
  6. cd $GOPATH/src/github.com/stenowtf
  7. ln -s ~/<projects_folder>/dd/dd-server dd-server
  8. go get gopkg.in/gorethink/gorethink.v3 github.com/gorilla/websocket github.com/mitchellh/mapstructure
  9. cd dd-server && go run *.go
  10. brew update && brew install rethinkdb && rethinkdb
  11. Navigate to: http://localhost:8080/#dataexplorer and run this two commands:
    • r.dbCreate('dd');
    • r.db('dd').tableCreate('downloads');
  12. Finally open http://localhost:3000 and enjoy!

How to install using Docker

  1. cd ~/<projects_folder>
  2. git clone https://github.com/stenowtf/dd.git
  3. cd dd
  4. git checkout docker
  5. docker-compose up
  6. Open http://localhost:3000 and enjoy!

Description

Once you opened http://localhost:3000 you can see a map area and a section with the graphs:

On the map, you can click on it to simulate a download, but you can also use the linkon the upper right to generate more random data.

There are graphs that represent the total downloads by country, by time of the day, by operating system, and by version of the app.

Of course, you can open two different tabs and see real-time changes.

FAQs

Q. I get ReferenceError: google is not defined. What's going on?

A. Networking error, try to refresh the page.