Browse files

renames otp-receive to otp-rpc-receive

This is done to denote the difference of receiving
messages into a mailbox from receiving RPC replies
  • Loading branch information...
1 parent 5cecd87 commit c807e75a646ad3888718fbd07522501e09309c52 @videlalvaro committed Aug 15, 2010
Showing with 9 additions and 7 deletions.
  1. +1 −1
  2. +8 −6 src/closerl/core.clj
@@ -32,7 +32,7 @@ Then we do a rpc_call to obtain the date on the remote node:
And we call receive to fetch the reply:
- (otp-receive conn)
+ (otp-rpc-receive conn)
For more details see introductory blogpost [here](
@@ -3,6 +3,7 @@
+ OtpConnection
;; Types
@@ -121,20 +122,21 @@
(defn otp-rpc-call
"Performs a RPC call to remote node"
- ([connection m f]
+ ([#^OtpConnection connection m f]
(.sendRPC connection m f (OtpErlangList.)))
- ([connection m f a]
+ ([#^OtpConnection connection m f a]
(.sendRPC connection m f a)))
-(defn otp-receive
- "Receive result from RPC call"
- [connection]
+(defn otp-rpc-receive
+ "Receive result from a RPC call.
+ The process will block while waiting."
+ [#^OtpConnection connection]
(.receiveRPC connection))
(defn otp-rpc-and-receive
"Send a RPC request, receive the message and returns it
converted as a Clojure type"
- [connection m f a]
+ [#^OtpConnection connection m f a]
(.sendRPC connection m f a)
(otp-value (.receiveRPC connection))))

0 comments on commit c807e75

Please sign in to comment.