Directly detect incoming connections in examples/chat-simplified-internals
This commit is contained in:
parent
024157103c
commit
ad9a78b4a4
|
@ -70,6 +70,13 @@
|
||||||
(observe (tcp-channel (?!) (?! (tcp-listener 5999)) ?))
|
(observe (tcp-channel (?!) (?! (tcp-listener 5999)) ?))
|
||||||
tcp-proxy-process)
|
tcp-proxy-process)
|
||||||
|
|
||||||
(spawn-demand-matcher (tcp-remote-open (?!))
|
(spawn (lambda (e s)
|
||||||
(tcp-local-open (?!))
|
(if (patch? e)
|
||||||
spawn-session)
|
(transition s
|
||||||
|
(for/list [(id (matcher-project/set/single
|
||||||
|
(patch-added e)
|
||||||
|
(compile-projection (tcp-remote-open (?!)))))]
|
||||||
|
(spawn-session id)))
|
||||||
|
#f))
|
||||||
|
(void)
|
||||||
|
(sub (tcp-remote-open ?)))
|
||||||
|
|
Loading…
Reference in New Issue