Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Commits on May 27, 2014
  1. @antifuchs

    Extract the sentinel process running into its own method

    antifuchs authored
    Also, extract the chunk of code where we set the new master process's
    environment, for OAOOification.
Commits on May 26, 2014
  1. @antifuchs

    Adjust reload{,ing}_for_preload_upgrade names for the new reality

    antifuchs authored
    It's just reload_for_upgrade now that we always reload einhorn on
    upgrades (:
  2. @antifuchs
  3. @antifuchs
  4. @antifuchs
  5. @antifuchs
  6. @antifuchs
  7. @antifuchs

    Place dropped env variables on Einhorn::State

    antifuchs authored
    ...instead of deleting them from the startup environment. I
    misunderstood how the re-execing works, and thought the re-exec'd
    master process would get all the original command line arguments. Not
    so: You have to place all the things that you want to survive a reload
    onto State.
    
    This means that --drop-env-var now survives the second restart,
    too. Yay!
  8. @antifuchs

    Put the reexec_commandline on State

    antifuchs authored
    This was a misunderstanding of mine: Einhorn doesn't pass the entire
    command line through to its children; we have to keep it on State,
    otherwise it gets lost on the second reload.
  9. @antifuchs
  10. @antifuchs
  11. @antifuchs
  12. @antifuchs

    Rename Einhorn.sanity_check to dump_environment_info

    antifuchs authored
    ...which is what it actually does right now. Once it actually performs
    more involved sanity checks, this should probably be renamed back (:
  13. @antifuchs
  14. @antifuchs

    Make tests wait until they can reach the server port

    antifuchs authored
    This should eliminate the race conditions where the control socket
    exists but the server port isn't open yet.
  15. @antifuchs

    Try to make the tests compatible again with 1.8.7 and above

    antifuchs authored
    * Use File.open() { f.write } instead of File.write
    * Use require(File.expand_path(...)) instead of require_relative
  16. @antifuchs

    Add tests for --drop-env-var and its interaction with --reexec-as

    antifuchs authored
    This should pretty much cover all the changes we need to make einhorn
    resilient to bundler/rbenv ruby upgrades.
Commits on May 24, 2014
  1. @antifuchs
  2. @antifuchs

    Perform a reloading upgrade regardless of circumstance

    antifuchs authored
    Before, when einhorn wasn't running with preloading, it would not
    reload itself. I think this is inconsistent, especially when there's
    --reexec-as involved; so make it always re-exec.
  3. @antifuchs

    Add (failing) tests for commuting environments

    antifuchs authored
    This is pretty much the meat of this whole branch: When upgrading the
    einhorn master, we should correctly re-exec the running process (that
    is, with the given command line).
  4. @antifuchs

    Use plain Subprocess in startup tests

    antifuchs authored
    This is way more reliable/better than the einhorn helper (which is
    meant to provide support for the long-running form of einhorn).
  5. @antifuchs

    Disable the vestigial test rake task

    antifuchs authored
    It only runs a subset of duplicate tests from the actual test rake
    task, so it can really die.
Commits on May 23, 2014
  1. @antifuchs

    Clean up the restart test

    antifuchs authored
    * No more chunder on stdout and stderr
    * In fact, capture stdout and stderr of einhorn and return it from the
      helper.
    * Remove a silly debug print statement from the test
  2. @antifuchs

    Flip the behavior of the einhorn helper's :expected_exit_code

    antifuchs authored
    We're going to use the non-expecting version way more.
  3. @antifuchs

    Add an integration test for proper restarting

    antifuchs authored
    This is fairly ugly - but I think we can get this to look nicer.
  4. @antifuchs

    Add :re_exec_commandline to TransientState structure

    antifuchs authored
    We reference it in places, but didn't have it before. Oops.
  5. @antifuchs
  6. @antifuchs

    On startup, don't exec the upgrade commandline

    antifuchs authored
    This would launch einhorn's re-exec command instead of the worker,
    confusing EVERYTHING. Now, launch the worker properly again.
  7. @antifuchs
  8. @antifuchs
Commits on May 22, 2014
  1. @antifuchs

    Add a command line switch to drop env vars on upgrade

    antifuchs authored
    This should allow anyone who uses bundler or rbenv to un-poison the
    environment that gets passed on to the upgraded einhorn process, so it
    can pick up the correct & current version that's intended.
  2. @antifuchs

    When upgrading, start a sentinel to see if re-execing can work

    antifuchs authored
    The intention is to that instead of taking down the Einhorn
    master (like it would previously) and leaving its worker children
    orphaned, this will make the master scream if it can't safely re-exec.
  3. @antifuchs

    Allow customizing the upgrade command line... via the commandline

    antifuchs authored
    This allows replacing the einhorn command name (say,
    `/usr/local/bin/einhorn`) with a more intricate command
    line (e.g. `rbenv exec bundle exec einhorn`). That command line will
    be split using shellwords.
    
    To that end, introduce `Einhorn.upgrade_commandline`, a helper method
    that can construct the command line used when reloading code.
  4. @antifuchs

    Add an --upgrade-check switch

    antifuchs authored
    This can allow the reload function to test whether the upgrade is
    going to fail for a terrible reason, like the bundler gem changing out
    from under Einhorn.
Commits on May 21, 2014
  1. @antifuchs

    Add integration test scaffold

    antifuchs authored
    This is gonna be important in the commits to come (-:
Something went wrong with that request. Please try again.