Skip to content

Instantly share code, notes, and snippets.

curl -X POST -H "content-type: application/json" http://localhost:8098/mapred --data @-
{"inputs":"stats-Ev::AssetCreation", "query":[{"map": {"language":"javascript", "source":"function(v) {return [1];}"}}]}
@kevsmith
kevsmith / gist:61221
Created February 10, 2009 03:43 — forked from boorad/gist:61216
handle_call({insert, Value}, _From, State) ->
NextNode = node_manager:next_node(?METHOD),
NextDb = db_manager:next_db_node(NextNode),
db_node:insert_value(Value),
------
On the db_manager module:
next_db_node(DbManagerPid) ->
gen_server:call(DbManagerPid, {next_db, ?METHOD}).