Re: New egg: nng

2021-11-07 Thread Mario Domenech Goulart
Hi Ariela,

On Fri, 05 Nov 2021 09:31:54 -0300 Ariela Wenner  wrote:

> Welp... that's a bummer. I was sure it was a timing issue with the tests.
>
> I'll keep poking at it on different machines to see what I'm missing.
>
> Thanks for giving it a try! Cheers!

Thank you for your efforts and for investigating the issue!  It's nice
that you actually have tests and they seem to be catching issues
(assuming the problem is not in the tests themselves).

All the best.
Mario
-- 
http://parenteses.org/mario



Re: New egg: nng

2021-11-05 Thread Ariela Wenner
Hi Mario!

Welp... that's a bummer. I was sure it was a timing issue with the tests.

I'll keep poking at it on different machines to see what I'm missing.

Thanks for giving it a try! Cheers!

El 4 de noviembre de 2021 4:16:46 p. m. GMT-03:00, Mario Domenech Goulart 
 escribió:
>Hi Ariela,
>
>On Sun, 31 Oct 2021 17:18:45 -0300 Ariela Wenner  wrote:
>
>> So, here's a followup
>>
>> I linked pthreads and added the things you suggested to the wiki.
>>
>> As for the hangs, I hate to say this but it seems like the test was the 
>> problem.
>> More precisely, it seems like the topic for the subscriber socket wasn't set
>> fast enough, so when the publisher socket sent a message, the subscriber 
>> wasn't
>> ready for it. Hang.
>>
>> I added some coordination in the test itself and ran the tests over 100 times
>> just to be sure. No hang. Maybe I'm just being extremely unlucky though, so 
>> as
>> always feedback is appreciated.
>>
>> Just pushed a new tag with the changes, fingers crossed.
>
>Thanks.
>
>I'm sad to report, though, that tests of 0.2.1 still hang here.
>
>I'm testing it with the following command:
>
>  $ test-new-egg nng 
> https://gitlab.com/ariSun/chicken-nng/-/raw/main/nng.release-info
>
>I executed the command above three times and tests hanged consistently.
>
>I'm using strace to verify that the test process is not actually doing
>anything:
>
>$ strace -p 14836
>strace: Process 14836 attached
>restart_syscall(<... resuming interrupted poll ...>
>
>All the best.
>Mario
>-- 
>http://parenteses.org/mario

-- 
Ariela Wenner

Re: New egg: nng

2021-11-04 Thread Mario Domenech Goulart
Hi Ariela,

On Sun, 31 Oct 2021 17:18:45 -0300 Ariela Wenner  wrote:

> So, here's a followup
>
> I linked pthreads and added the things you suggested to the wiki.
>
> As for the hangs, I hate to say this but it seems like the test was the 
> problem.
> More precisely, it seems like the topic for the subscriber socket wasn't set
> fast enough, so when the publisher socket sent a message, the subscriber 
> wasn't
> ready for it. Hang.
>
> I added some coordination in the test itself and ran the tests over 100 times
> just to be sure. No hang. Maybe I'm just being extremely unlucky though, so as
> always feedback is appreciated.
>
> Just pushed a new tag with the changes, fingers crossed.

Thanks.

I'm sad to report, though, that tests of 0.2.1 still hang here.

I'm testing it with the following command:

  $ test-new-egg nng 
https://gitlab.com/ariSun/chicken-nng/-/raw/main/nng.release-info

I executed the command above three times and tests hanged consistently.

I'm using strace to verify that the test process is not actually doing
anything:

$ strace -p 14836
strace: Process 14836 attached
restart_syscall(<... resuming interrupted poll ...>

All the best.
Mario
-- 
http://parenteses.org/mario



Re: New egg: nng

2021-11-01 Thread Arnaud Bailly
Thanks a lot!
I have started using zmq (from Haskell) to implement some networking for a
protocol and I was quite pleased with experience so far. Did not implement
any form of authent or security though, as we don't really plan to use zmq
as is in production. I was wondering whether or not it would make to port
what I have to nng given it seems to have more traction nowadays.
Having TLS support is indeed interesting.

Regards,
-- 
Arnaud Bailly - @dr_c0d3


On Mon, Nov 1, 2021 at 5:28 PM Ariela Wenner  wrote:

> Honestly, for my usecase, they are about the same.
>
> My main work with nng/zmq is implementing the actor model (I have two
> implementations, one for CHICKEN with nng, and a port for Common Lisp with
> zmq), so rep/req (and inproc pair for some sync when spawning an actor),
> nothing terribly complex.
>
> The main benefit and the reason that I personally like zmq more, is
> CurveZMQ, which saves me having to implement encryption with tweetnacl, for
> example. Sure, I have the tls transport with nng but that's a bit of a main
> imo.
>
> El 1 de noviembre de 2021 4:09:06 a. m. GMT-03:00, Arnaud Bailly <
> arnaud.oq...@gmail.com> escribió:
> >
> >I am currently using 0MQ (not in chicken though) and have been looking at
> >nng for a while, but unsure how mature it is.
> >What's your feedback using it? What are you using it for?
> >
> >Just curious :)
> >
> >
>
> --
> Ariela Wenner
>


Re: New egg: nng

2021-11-01 Thread Ariela Wenner
Honestly, for my usecase, they are about the same.

My main work with nng/zmq is implementing the actor model (I have two 
implementations, one for CHICKEN with nng, and a port for Common Lisp with 
zmq), so rep/req (and inproc pair for some sync when spawning an actor), 
nothing terribly complex.

The main benefit and the reason that I personally like zmq more, is CurveZMQ, 
which saves me having to implement encryption with tweetnacl, for example. 
Sure, I have the tls transport with nng but that's a bit of a main imo.

El 1 de noviembre de 2021 4:09:06 a. m. GMT-03:00, Arnaud Bailly 
 escribió:
>
>I am currently using 0MQ (not in chicken though) and have been looking at
>nng for a while, but unsure how mature it is.
>What's your feedback using it? What are you using it for?
>
>Just curious :)
>
>

-- 
Ariela Wenner



Re: New egg: nng

2021-11-01 Thread Arnaud Bailly

I am currently using 0MQ (not in chicken though) and have been looking at
nng for a while, but unsure how mature it is.
What's your feedback using it? What are you using it for?

Just curious :)


-- 
Arnaud Bailly - @dr_c0d3


On Sun, Oct 31, 2021 at 9:19 PM Ariela Wenner  wrote:

>
> So, here's a followup
>
> I linked pthreads and added the things you suggested to the wiki.
>
> As for the hangs, I hate to say this but it seems like the test was the
> problem.
> More precisely, it seems like the topic for the subscriber socket wasn't
> set
> fast enough, so when the publisher socket sent a message, the subscriber
> wasn't
> ready for it. Hang.
>
> I added some coordination in the test itself and ran the tests over 100
> times
> just to be sure. No hang. Maybe I'm just being extremely unlucky though,
> so as
> always feedback is appreciated.
>
> Just pushed a new tag with the changes, fingers crossed.
>
> On Sun, 31 Oct 2021 09:59:37 -0300
> Ariela Wenner  wrote:
>
> > Hi Mario!
> >
> > Thanks for the feedback! I'll be fixing the minor issues when I have
> time.
> >
> > As for the hang... yeah, damn. That's a bug I THOUGHT I had fixed but
> apparently not. It's weird that it only happens with pub-sub, and only
> sometimes. If anyone knows what might be going on hmu, help is immensely
> appreciated.
> >
> > I'll try re-submitting again after the issues are fixed.
> >
> > Thanks again! Cheers.
> >
> >
> > El 31 de octubre de 2021 7:03:20 a. m. GMT-03:00, Mario Domenech Goulart
>  escribió:
> > >Hi Ariela,
> > >
> > >On Fri, 29 Oct 2021 13:35:52 -0300 Ariela Wenner 
> wrote:
> > >
> > >> Hi all! I'd like to add my nng egg to the coop. Went through
> test-new-egg and everything seems fine.
> > >>
> > >> Release info is at
> https://gitlab.com/ariSun/chicken-nng/-/raw/main/nng.release-info
> > >>
> > >> Wiki page is http://wiki.call-cc.org/eggref/5/nng
> > >>
> > >> This is the first time I publish an egg so please let me know if
> something's wrong.
> > >
> > >Thanks!  That looks very interesting.
> > >
> > >I've tried to test your egg as part of the setup procedure of our test
> > >machines and stumbled upon a couple of issues.  I'm using the following
> > >environment:
> > >
> > >* Debian 10.11
> > >* GCC 8.3.0
> > >* x86 system (32bit)
> > >* CHICKEN 5.2.0
> > >* nng version 1.5.2
> > >
> > >I'm able to compile and install the egg, but when I run tests I get
> > >
> > >  csi: symbol lookup error: .../lib/chicken/11/nng.so: undefined
> symbol: pthread_mutexattr_init
> > >
> > >I can work around that by using
> > >
> > >diff --git a/nng.egg b/nng.egg
> > >index 782ce6c..f5b4f9a 100644
> > >--- a/nng.egg
> > >+++ b/nng.egg
> > >@@ -5,6 +5,6 @@
> > >  (test-dependencies test uuid)
> > >  (dependencies foreigners srfi-18 srfi-69)
> > >  (components (extension nng
> > >-(csc-options "-L" "-lnng")
> > >+(csc-options "-L" "-lnng" "-L" "-lpthread")
> > > (source "src/nng.scm")))
> > >  (version 0.2.0))
> > >
> > >
> > >But then tests apparently hang in "tcp pub-sub":
> > >
> > >-- testing nng
> ---
> > >non-blocking .
> [ PASS]
> > >tcp req-rep ..
> [ PASS]
> > >inproc req-rep ...
> [ PASS]
> > >tcp push-pull 
> [ PASS]
> > >inproc push-pull .
> [ PASS]
> > >tcp pair .
> [ PASS]
> > >inproc pair ..
> [ PASS]
> > >tcp pub-sub ..
> > >
> > >strace doesn't help much:
> > >
> > >$ strace -p 19841
> > >strace: Process 19841 attached
> > >restart_syscall(<... resuming interrupted poll ...>
> > >
> > >Would you know what can be wrong?
> > >
> > >Regarding the documentation, a few notes:
> > >
> > >* Please use the actual egg name as main heading (s/chicken-nng/nng/)
> > >
> > >* It would be nice to mention which versions of nng the egg is supposed
> > >  to be compatible with.  At least the versions it is known to work
> with.
> > >
> > >* Please add the following sections to the documentation:
> > >  * a "Repository" section with a link to the source repository
> > >  * a "License" section mentioning the license of the egg (should match
> > >what's specified in the .egg file
> > >
> > >All the best.
> > >Mario
> > >--
> > >http://parenteses.org/mario
> > >
> >
> > --
> > Ariela Wenner
>
>


Re: New egg: nng

2021-10-31 Thread Ariela Wenner


So, here's a followup

I linked pthreads and added the things you suggested to the wiki.

As for the hangs, I hate to say this but it seems like the test was the problem.
More precisely, it seems like the topic for the subscriber socket wasn't set
fast enough, so when the publisher socket sent a message, the subscriber wasn't
ready for it. Hang.

I added some coordination in the test itself and ran the tests over 100 times
just to be sure. No hang. Maybe I'm just being extremely unlucky though, so as
always feedback is appreciated.

Just pushed a new tag with the changes, fingers crossed.

On Sun, 31 Oct 2021 09:59:37 -0300
Ariela Wenner  wrote:

> Hi Mario!
> 
> Thanks for the feedback! I'll be fixing the minor issues when I have time.
> 
> As for the hang... yeah, damn. That's a bug I THOUGHT I had fixed but 
> apparently not. It's weird that it only happens with pub-sub, and only 
> sometimes. If anyone knows what might be going on hmu, help is immensely 
> appreciated.
> 
> I'll try re-submitting again after the issues are fixed.
> 
> Thanks again! Cheers.
> 
> 
> El 31 de octubre de 2021 7:03:20 a. m. GMT-03:00, Mario Domenech Goulart 
>  escribió:
> >Hi Ariela,
> >
> >On Fri, 29 Oct 2021 13:35:52 -0300 Ariela Wenner  wrote:
> >
> >> Hi all! I'd like to add my nng egg to the coop. Went through test-new-egg 
> >> and everything seems fine.
> >>
> >> Release info is at 
> >> https://gitlab.com/ariSun/chicken-nng/-/raw/main/nng.release-info
> >>
> >> Wiki page is http://wiki.call-cc.org/eggref/5/nng
> >>
> >> This is the first time I publish an egg so please let me know if 
> >> something's wrong.
> >
> >Thanks!  That looks very interesting.
> >
> >I've tried to test your egg as part of the setup procedure of our test
> >machines and stumbled upon a couple of issues.  I'm using the following
> >environment:
> >
> >* Debian 10.11
> >* GCC 8.3.0
> >* x86 system (32bit)
> >* CHICKEN 5.2.0
> >* nng version 1.5.2
> >
> >I'm able to compile and install the egg, but when I run tests I get
> >
> >  csi: symbol lookup error: .../lib/chicken/11/nng.so: undefined symbol: 
> > pthread_mutexattr_init
> >
> >I can work around that by using
> >
> >diff --git a/nng.egg b/nng.egg
> >index 782ce6c..f5b4f9a 100644
> >--- a/nng.egg
> >+++ b/nng.egg
> >@@ -5,6 +5,6 @@
> >  (test-dependencies test uuid)
> >  (dependencies foreigners srfi-18 srfi-69)
> >  (components (extension nng
> >-(csc-options "-L" "-lnng")
> >+(csc-options "-L" "-lnng" "-L" "-lpthread")
> > (source "src/nng.scm")))
> >  (version 0.2.0))
> >
> >
> >But then tests apparently hang in "tcp pub-sub":
> >
> >-- testing nng 
> >---
> >non-blocking . [ 
> >PASS]
> >tcp req-rep .. [ 
> >PASS]
> >inproc req-rep ... [ 
> >PASS]
> >tcp push-pull  [ 
> >PASS]
> >inproc push-pull . [ 
> >PASS]
> >tcp pair . [ 
> >PASS]
> >inproc pair .. [ 
> >PASS]
> >tcp pub-sub .. 
> >
> >strace doesn't help much:
> >
> >$ strace -p 19841
> >strace: Process 19841 attached
> >restart_syscall(<... resuming interrupted poll ...>
> >
> >Would you know what can be wrong?
> >
> >Regarding the documentation, a few notes:
> >
> >* Please use the actual egg name as main heading (s/chicken-nng/nng/)
> >
> >* It would be nice to mention which versions of nng the egg is supposed
> >  to be compatible with.  At least the versions it is known to work with.
> >
> >* Please add the following sections to the documentation:
> >  * a "Repository" section with a link to the source repository
> >  * a "License" section mentioning the license of the egg (should match
> >what's specified in the .egg file
> >
> >All the best.
> >Mario
> >-- 
> >http://parenteses.org/mario
> >
> 
> -- 
> Ariela Wenner



Re: New egg: nng

2021-10-31 Thread Ariela Wenner
Hi Mario!

Thanks for the feedback! I'll be fixing the minor issues when I have time.

As for the hang... yeah, damn. That's a bug I THOUGHT I had fixed but 
apparently not. It's weird that it only happens with pub-sub, and only 
sometimes. If anyone knows what might be going on hmu, help is immensely 
appreciated.

I'll try re-submitting again after the issues are fixed.

Thanks again! Cheers.


El 31 de octubre de 2021 7:03:20 a. m. GMT-03:00, Mario Domenech Goulart 
 escribió:
>Hi Ariela,
>
>On Fri, 29 Oct 2021 13:35:52 -0300 Ariela Wenner  wrote:
>
>> Hi all! I'd like to add my nng egg to the coop. Went through test-new-egg 
>> and everything seems fine.
>>
>> Release info is at 
>> https://gitlab.com/ariSun/chicken-nng/-/raw/main/nng.release-info
>>
>> Wiki page is http://wiki.call-cc.org/eggref/5/nng
>>
>> This is the first time I publish an egg so please let me know if something's 
>> wrong.
>
>Thanks!  That looks very interesting.
>
>I've tried to test your egg as part of the setup procedure of our test
>machines and stumbled upon a couple of issues.  I'm using the following
>environment:
>
>* Debian 10.11
>* GCC 8.3.0
>* x86 system (32bit)
>* CHICKEN 5.2.0
>* nng version 1.5.2
>
>I'm able to compile and install the egg, but when I run tests I get
>
>  csi: symbol lookup error: .../lib/chicken/11/nng.so: undefined symbol: 
> pthread_mutexattr_init
>
>I can work around that by using
>
>diff --git a/nng.egg b/nng.egg
>index 782ce6c..f5b4f9a 100644
>--- a/nng.egg
>+++ b/nng.egg
>@@ -5,6 +5,6 @@
>  (test-dependencies test uuid)
>  (dependencies foreigners srfi-18 srfi-69)
>  (components (extension nng
>-(csc-options "-L" "-lnng")
>+(csc-options "-L" "-lnng" "-L" "-lpthread")
> (source "src/nng.scm")))
>  (version 0.2.0))
>
>
>But then tests apparently hang in "tcp pub-sub":
>
>-- testing nng ---
>non-blocking . [ PASS]
>tcp req-rep .. [ PASS]
>inproc req-rep ... [ PASS]
>tcp push-pull  [ PASS]
>inproc push-pull . [ PASS]
>tcp pair . [ PASS]
>inproc pair .. [ PASS]
>tcp pub-sub .. 
>
>strace doesn't help much:
>
>$ strace -p 19841
>strace: Process 19841 attached
>restart_syscall(<... resuming interrupted poll ...>
>
>Would you know what can be wrong?
>
>Regarding the documentation, a few notes:
>
>* Please use the actual egg name as main heading (s/chicken-nng/nng/)
>
>* It would be nice to mention which versions of nng the egg is supposed
>  to be compatible with.  At least the versions it is known to work with.
>
>* Please add the following sections to the documentation:
>  * a "Repository" section with a link to the source repository
>  * a "License" section mentioning the license of the egg (should match
>what's specified in the .egg file
>
>All the best.
>Mario
>-- 
>http://parenteses.org/mario
>

-- 
Ariela Wenner

Re: New egg: nng

2021-10-31 Thread Mario Domenech Goulart
Hi Ariela,

On Fri, 29 Oct 2021 13:35:52 -0300 Ariela Wenner  wrote:

> Hi all! I'd like to add my nng egg to the coop. Went through test-new-egg and 
> everything seems fine.
>
> Release info is at 
> https://gitlab.com/ariSun/chicken-nng/-/raw/main/nng.release-info
>
> Wiki page is http://wiki.call-cc.org/eggref/5/nng
>
> This is the first time I publish an egg so please let me know if something's 
> wrong.

Thanks!  That looks very interesting.

I've tried to test your egg as part of the setup procedure of our test
machines and stumbled upon a couple of issues.  I'm using the following
environment:

* Debian 10.11
* GCC 8.3.0
* x86 system (32bit)
* CHICKEN 5.2.0
* nng version 1.5.2

I'm able to compile and install the egg, but when I run tests I get

  csi: symbol lookup error: .../lib/chicken/11/nng.so: undefined symbol: 
pthread_mutexattr_init

I can work around that by using

diff --git a/nng.egg b/nng.egg
index 782ce6c..f5b4f9a 100644
--- a/nng.egg
+++ b/nng.egg
@@ -5,6 +5,6 @@
  (test-dependencies test uuid)
  (dependencies foreigners srfi-18 srfi-69)
  (components (extension nng
-(csc-options "-L" "-lnng")
+(csc-options "-L" "-lnng" "-L" "-lpthread")
 (source "src/nng.scm")))
  (version 0.2.0))


But then tests apparently hang in "tcp pub-sub":

-- testing nng ---
non-blocking . [ PASS]
tcp req-rep .. [ PASS]
inproc req-rep ... [ PASS]
tcp push-pull  [ PASS]
inproc push-pull . [ PASS]
tcp pair . [ PASS]
inproc pair .. [ PASS]
tcp pub-sub .. 

strace doesn't help much:

$ strace -p 19841
strace: Process 19841 attached
restart_syscall(<... resuming interrupted poll ...>

Would you know what can be wrong?

Regarding the documentation, a few notes:

* Please use the actual egg name as main heading (s/chicken-nng/nng/)

* It would be nice to mention which versions of nng the egg is supposed
  to be compatible with.  At least the versions it is known to work with.

* Please add the following sections to the documentation:
  * a "Repository" section with a link to the source repository
  * a "License" section mentioning the license of the egg (should match
what's specified in the .egg file

All the best.
Mario
-- 
http://parenteses.org/mario



New egg: nng

2021-10-29 Thread Ariela Wenner


Hi all! I'd like to add my nng egg to the coop. Went through test-new-egg and 
everything seems fine.

Release info is at 
https://gitlab.com/ariSun/chicken-nng/-/raw/main/nng.release-info

Wiki page is http://wiki.call-cc.org/eggref/5/nng

This is the first time I publish an egg so please let me know if something's 
wrong.

Cheers!