fszmq


Weather Update Proxy

Weather proxy device which does network bridging

 1: 
 2: 
 3: 
 4: 
 5: 
 6: 
 7: 
 8: 
 9: 
10: 
11: 
12: 
13: 
14: 
15: 
16: 
17: 
18: 
19: 
#r "fszmq.dll"
open fszmq
open fszmq.Proxying

let main () =
  use context = new Context ()

  // this is where the weather server sits
  use frontend = Context.xsub context
  Socket.connect frontend "tcp://192.168.55.210:5556"

  // this is our public endpoint for subscribers
  use backend = Context.xpub context
  Socket.bind backend "tcp://10.1.1.0:8100"

  // run the proxy until the user interrupts us
  proxy frontend backend None

  0 // return code
module docs
module PATH

from docs
val hijack : unit -> unit

Full name: docs.PATH.hijack
namespace fszmq
module Proxying

from fszmq
val main : unit -> int

Full name: Wuproxy.main
val context : 'a
val frontend : fszmq.Socket
val backend : fszmq.Socket
val proxy : frontend:fszmq.Socket -> backend:fszmq.Socket -> capture:fszmq.Socket option -> unit

Full name: fszmq.Proxying.proxy
union case Option.None: Option<'T>
val release : unit -> unit

Full name: docs.PATH.release
Fork me on GitHub