Permalink
Browse files

Fixed select/qlc scope (default: all); fixed dist eunit test; new rebar

gproc:select/1 now defaults to global+local scope (BW incompatible change)
Type specs have been updated to reflect that {Scope, Type} is a valid first
argument to select/2, first/1, next/2 et al.

The gproc_dist_tests module has been improved, and now works (most of the time,
although it can still time out occasionally).
  • Loading branch information...
1 parent fdc3283 commit 59365c4befa65648b7a7c7416ba19d2fecfd8bed Ulf Wiger committed Apr 18, 2011
Showing with 292 additions and 235 deletions.
  1. +2 −2 README.md
  2. +2 −2 doc/README.md
  3. +80 −63 doc/gproc.md
  4. +3 −3 doc/gproc_app.md
  5. +24 −24 doc/gproc_dist.md
  6. +2 −2 doc/gproc_init.md
  7. +2 −2 doc/gproc_sup.md
  8. BIN rebar
  9. +123 −112 src/gproc.erl
  10. +15 −25 test/gproc_dist_tests.erl
  11. +39 −0 test/gproc_tests.erl
View
@@ -47,11 +47,11 @@ An interesting application of gproc is building publish/subscribe patterns.
Example:
<pre>
-subscribe(EventType) -&gt;
+subscribe(EventType) ->
%% Gproc notation: {p, l, Name} means {(p)roperty, (l)ocal, Name}
gproc:reg({p, l, {?MODULE, EventType}}).
-notify(EventType, Msg) -&gt;
+notify(EventType, Msg) ->
Key = {?MODULE, EventType},
gproc:send({p, l, Key}, {self(), Key, Msg}).
</pre>
View
@@ -47,11 +47,11 @@ An interesting application of gproc is building publish/subscribe patterns.
Example:
<pre>
-subscribe(EventType) -&gt;
+subscribe(EventType) ->
%% Gproc notation: {p, l, Name} means {(p)roperty, (l)ocal, Name}
gproc:reg({p, l, {?MODULE, EventType}}).
-notify(EventType, Msg) -&gt;
+notify(EventType, Msg) ->
Key = {?MODULE, EventType},
gproc:send({p, l, Key}, {self(), Key, Msg}).
</pre>
Oops, something went wrong.

0 comments on commit 59365c4

Please sign in to comment.