ANN: remote-json, a JSON RPC library, released

Previous Topic Next Topic
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

ANN: remote-json, a JSON RPC library, released

Andy Gill-3
Announcing a new Haskell JSON RPC library, remote-json, that uses the remote monad to bundle remote procedure calls, amortizing the cost of remote execution. There are thee bundling strategies provided: 

 * weak (calls done one at a time), 
 * strong (calls bundled until a reply is needed, where possible), and 
 * applicative (an applicative functor is sent to the remote JSON RPC server).

Example of use:

say :: Text -> RPC ()
say msg = notification "say" (List [String msg])

temperature :: RPC Int
temperature = method "temperature" None

main :: IO ()
main = do
  let s = strongSession $ clientSendAPI ""
  t <- send s $ do
                say "Hello, "
                say "World!"
  print t

Haskell mailing list
[hidden email]