Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run ProgrammingEvaluation in service #2308

Merged

Commits on Jun 28, 2017

  1. Add Docker API gem.

    Provides abstractions to work with Docker containers.
    fonglh committed Jun 28, 2017
    Configuration menu
    Copy the full SHA
    09ef736 View commit details
    Browse the repository at this point in the history
  2. Evaluate packages directly in ProgrammingEvaluationService.

    Previously, the ProgrammingEvaluationService created evaluations and
    waited for external evaluators to run the evaluation and update its
    state.
    
    To elimimate the polling time of these external evaluators, move actual
    evaluation using docker containers into the service so the worker can
    run it immediately.
    
    No longer create ProgrammingEvaluation objects.
    Use Ruby's timeout on the execute method instead of the old method of
    using the custom AR extension for the ProgrammingEvaluation object.
    fonglh committed Jun 28, 2017
    Configuration menu
    Copy the full SHA
    317cbd9 View commit details
    Browse the repository at this point in the history
  3. Stub out evaluate_in_container.

    Return the expected array of values during testing instead of spinning
    up a Docker container for actual evaluation.
    Add a short sleep to facilitate timeout testing.
    
    Remove `wait_for_evaluation` stub.
    
    Fix ProgrammingEvaluationService specs.
    Use a non-zero timeout as Ruby timeout treats 0 as infinite.
    Remove create_evaluation tests.
    fonglh committed Jun 28, 2017
    Configuration menu
    Copy the full SHA
    1e1ca61 View commit details
    Browse the repository at this point in the history
  4. Add specs for create_container in ProgrammingEvaluationService.

    Adapted from corresponding specs in evaluator-slave.
    fonglh committed Jun 28, 2017
    Configuration menu
    Copy the full SHA
    0c44d58 View commit details
    Browse the repository at this point in the history
  5. Add specs for CoursemologyDockerContainer.

    Adapted from corresponding specs in evaluator-slave.
    
    Specify use of Docker to Travis.
    Install nodejs 6 as VM based trusty uses an old incompatible version.
    fonglh committed Jun 28, 2017
    Configuration menu
    Copy the full SHA
    5989741 View commit details
    Browse the repository at this point in the history
  6. Only use the component that can be disabled to test

    * The first component can be random depends on the order of the loading
    allenwq authored and fonglh committed Jun 28, 2017
    Configuration menu
    Copy the full SHA
    cd37f09 View commit details
    Browse the repository at this point in the history