Giter VIP home page Giter VIP logo

longshoreman's Introduction

Longshoreman

An exercise in writing real-world Go applications

  • Phase 1 - In which we set up a working HTTP REST API.
  • Phase 2 - In which we use goroutines for concurrency.
  • Phase 3 - In which we mitigate DoS via a worker pool.

HINTS are included for the stuck.

Getting Started

Before you can start hacking, you'll need to spin up the Longshoreman development environment, a Vagrant box.

You'll need Vagrant installed.

brew cask install virtualbox
brew cask install vagrant

Then, spin up the Vagrant machine (from this directory)

vagrant up

That may take a few minutes, as it installs a bunch of stuff you'll need. Oncce it's up, you can SSH into it:

vagrant ssh

This will drop you into a shell as the vagrant user. In your home directory, you'll see a go/ directory (your $GOPATH), and multiple phaseN directories, one for each phase of this exercise.

Finally, you'll need to install the following libraries, which are dependencies of the project (just how this is done is part of your training!):

Running the Demo

To see a complete implementation of Longshoreman in action, run phase3's demo script:

./phase3/demo

then go visit http://localhost:8184 on your laptop.

Working Through The Exercises

Each phase of the exercise is self-contained inside of it's directory, including the static assets for the front-end web interface. Inside each phase directory, you'll also find a README.md file that contains instructions for the phase, and a HINTS file for when you get stuck.

Happy Hacking!

longshoreman's People

Contributors

jhunt avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.