Overview
Comment: | yada |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | v1.6584-nanomsg |
Files: | files | file ages | folders |
SHA1: |
3b6efca64a139214ce6e7f42a5e441f2 |
User & Date: | matt on 2021-10-21 15:08:13 |
Other Links: | branch diff | manifest | tags |
Context
2021-10-21
| ||
16:19 | Got crude nng transport implementation working/ check-in: 96b5fc4451 user: matt tags: v1.6584-nanomsg | |
15:08 | yada check-in: 3b6efca64a user: matt tags: v1.6584-nanomsg | |
2021-10-17
| ||
18:55 | Added initial file for nng testing check-in: e619f01971 user: matt tags: v1.6584-nanomsg | |
Changes
Added build-assist/ck5-eggs.list version [c1fba7745a].
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | address-info ansi-escape-sequences apropos base64 crypt csv-abnf directory-utils filepath fmt format http-client itemsmod json linenoise md5 message-digest nanomsg postgresql queues regex regex-case rfc3339 s11n sha1 slice sparse-vectors spiffy spiffy-directory-listing spiffy-request-vars sql-de-lite sqlite3 sql-null srfi-1 srfi-13 srfi-19 sxml-modifications sxml-serializer sxml-transforms system-information test typed-records uri-common z3 |
Added build-assist/debian-packages-needed version [c1a441be4e].
> > > > > | 1 2 3 4 5 | build-essential libnanomsg-dev libpq-dev libsqlite3-dev sqlite3 |
Added nng-trial/Makefile version [c83d590f9e].
> > > > > | 1 2 3 4 5 | nng-test : nng-test.scm csc nng-test.scm test : nng-test ./nng-test do-test |
Modified nng-trial/nng-test.scm from [d3eb85a993] to [3d0cf92ae9].
1 2 3 4 5 | (import (chicken io) (chicken string) miscmacros nng srfi-18 | > > | > > > > > > < < < < < < < < < < < < < < < < < < | | | < | | | < | | | > > > > > > > | > > > > > > > > > > > > > > > > | > > > > > > > > > > > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 | (import (chicken io) (chicken string) (chicken process-context) (chicken process-context posix) miscmacros nng srfi-18 test matchable typed-records) (define help "Usage: nng-test COMMAND where COMMAND is one of: dotest : run the basic req/rep test ") (define address-tcp-1 "tcp://localhost:5555") (define address-tcp-2 "tcp://localhost:6666") (define address-inproc-1 "inproc://local1") (define address-inproc-2 "inproc://local2") ;;; ;;; Req-Rep ;;; (define (make-listening-reply-socket address) (let ((socket (make-rep-socket))) (socket-set! socket 'nng/recvtimeo 2000) (nng-listen socket address) socket)) (define (make-dialed-request-socket address) (let ((socket (make-req-socket))) (socket-set! socket 'nng/recvtimeo 2000) (nng-dial socket address) socket)) (define (req-rep-test address) (let ((rep (make-listening-reply-socket address)) (req (make-dialed-request-socket address))) (nng-send req "message 1") (nng-recv rep) (nng-send rep "message") (begin0 (nng-recv req) (nng-close! rep)))) (define (do-test) (test-group "nng" (test "tcp req-rep" "message" (req-rep-test address-tcp-1)) (test "inproc req-rep" "message" (req-rep-test address-inproc-1))) (test-exit)) (defstruct srv myaddr remaddr req rep name) (define (server-setup myname myaddr remoteaddr) (let* ((srvdat (make-srv))) (srv-myaddr-set! srvdat myaddr) (srv-remaddr-set! srvdat remoteaddr) (srv-rep-set! srvdat (make-listening-reply-socket myaddr)) (srv-req-set! srvdat (make-dialed-request-socket myaddr)) (srv-name-set! srvdat myname) srvdat)) (define (send-n-messages n srvdat) (let* ((name (srv-name srvdat))) (let loop ((i 0)) (if (< i n) (begin (print "send: "(nng-send (srv-req srvdat) (conc name "-" i))) (print "receive: "(nng-recv (srv-rep srvdat))) (loop (+ i 1))))))) (define (close-srv srvdat) (nng-close! (srv-rep srvdat))) (match (command-line-arguments) (("do-test")(do-test)) (("send-n" n myaddr toaddr) (let ((n-num (string->number n)) (sdat (server-setup "just testing" myaddr toaddr))) (send-n-messages n-num sdat) (close-srv sdat))) ((cmd)(print "ERROR: command "cmd", not recognised.\n\n"help)) (else (print help))) |