Browse files

Upgrade to redgrid 1.0.3

Redgrid 1.0.3 adds tolerance for DNS disconnections and configuration
reloading.
  • Loading branch information...
1 parent a35010b commit f230a0c57ba518bb31e1efb37c2d12604c52bd0e @ferd ferd committed Aug 23, 2013
Showing with 14 additions and 3 deletions.
  1. +11 −0 bin/redgrid
  2. +1 −1 public.rebar.config
  3. +1 −1 rebar.config
  4. +1 −1 test.rebar.config
View
11 bin/redgrid
@@ -4,6 +4,8 @@
%% Only works on localhost, assumes the current hostname will fit the localhost
-define(NAME, filename:basename(escript:script_name())).
+main([Op]) -> main([Op, "logplex"]);
+
main(["nodes", Name]) ->
Node = connect(Name),
Res = rpc:call(Node, redgrid, nodes, []),
@@ -24,6 +26,13 @@ main(["resume", Name]) ->
io:format("ok.~n"),
disconnect(),
halt(0);
+main(["reload_config", Name]) ->
+ Node = connect(Name),
+ io:format("Reloading redgrid conf... "),
+ Res = rpc:call(Node, redgrid, reload_config, []),
+ io:format("Result: ~p.~n", [Res]),
+ disconnect(),
+ halt(0);
main(["status", Name]) ->
Node = connect(Name),
Res = rpc:call(Node, sys, get_status, [redgrid]),
@@ -37,6 +46,8 @@ main(_) -> %% HELP
"\tDeregister <Node> from redgrid and suspend the update process.~n"
"resume <Node>~n"
"\tRegister <Node> back into redgrid and resume regular activities.~n"
+ "reload_config <Node>~n"
+ "\tReload <Node>'s configuration from the app env or OS if not defined.~n"
"status <Node>~n"
"\tFetches the process status for redgrid on node <Node>.~n"),
halt(0).
View
2 public.rebar.config
@@ -4,7 +4,7 @@
[{redis, "", {git, "git://github.com/JacobVorreuter/redis_pool.git", "master"}}
,{mochiweb, "", {git, "git://github.com/heroku/mochiweb.git", "R16B01"}}
,{pagerduty, "", {git, "git://github.com/JacobVorreuter/pagerduty.git", "master"}}
- ,{redgrid, "", {git, "git://github.com/JacobVorreuter/redgrid.git", {tag, "v1.0.2"}}}
+ ,{redgrid, "", {git, "git://github.com/JacobVorreuter/redgrid.git", {tag, "v1.0.3"}}}
,{redo, "^1.1", {git, "git://github.com/JacobVorreuter/redo.git", "7c7eaef4cd65271e2fc4ea88587e848407cf0762"}}
,{nsync, "", {git, "git://github.com/JacobVorreuter/nsync.git", "cb76900cd7443b845f9ea38c7712f603debfc844"}}
,{cowboy, "", {git, "git://github.com/heroku/cowboy.git", "91c0828bd28e718cc871cb268fb841cc2d010f2c"}}
View
2 rebar.config
@@ -4,7 +4,7 @@
[{redis, "", {git, "git@git.herokai.com:erlang_redis_pool.git", "master"}}
,{mochiweb, "", {git, "git@git.herokai.com:mochiweb.git", "R16B01"}}
,{pagerduty, "", {git, "git@git.herokai.com:erlang_pagerduty.git", "master"}}
- ,{redgrid, "", {git, "git@git.herokai.com:redgrid.git", {tag, "v1.0.2"}}}
+ ,{redgrid, "", {git, "git@git.herokai.com:redgrid.git", {tag, "v1.0.3"}}}
,{redo, "^1.1", {git, "git@git.herokai.com:redo.git", "7c7eaef4cd65271e2fc4ea88587e848407cf0762"}}
,{nsync, "", {git, "git@git.herokai.com:nsync.git", "cb76900cd7443b845f9ea38c7712f603debfc844"}}
,{cowboy, "", {git, "git@git.herokai.com:cowboy.git", "91c0828bd28e718cc871cb268fb841cc2d010f2c"}}
View
2 test.rebar.config
@@ -4,7 +4,7 @@
[{redis, "", {git, "git://github.com/JacobVorreuter/redis_pool.git", "master"}}
,{mochiweb, "", {git, "git://github.com/heroku/mochiweb.git", "R16B01"}}
,{pagerduty, "", {git, "git://github.com/JacobVorreuter/pagerduty.git", "master"}}
- ,{redgrid, "", {git, "git@git.herokai.com:redgrid.git", {tag, "v1.0.2"}}}
+ ,{redgrid, "", {git, "git@git.herokai.com:redgrid.git", {tag, "v1.0.3"}}}
,{redo, "^1.1", {git, "git://github.com/JacobVorreuter/redo.git", "7c7eaef4cd65271e2fc4ea88587e848407cf0762"}}
,{nsync, "", {git, "git://github.com/JacobVorreuter/nsync.git", "cb76900cd7443b845f9ea38c7712f603debfc844"}}
,{cowboy, "", {git, "git://github.com/heroku/cowboy.git", "91c0828bd28e718cc871cb268fb841cc2d010f2c"}}

0 comments on commit f230a0c

Please sign in to comment.