[Pharo-users] ZnClient>>#close & socket semaphores

Paul DeBruicker pdebruic at gmail.com
Fri Jun 1 13:02:36 EDT 2012


Sven - Sorry for the delay in getting back to you about this and I know Igor
has submitted a new method for automatically expanding the semaphore table
so the issue may be moot but I thought I'd respond below anyway.  



Sven Van Caekenberghe wrote
> 
> On 15 May 2012, at 22:48, Paul DeBruicker wrote:
> 
>> Sven Van Caekenberghe wrote
>>> 
>>> Paul,
>>> 
>>> On 15 May 2012, at 20:50, Paul DeBruicker wrote:
>>> 
>>>> I ran into an out-of-external semaphores error when testing the Tropo
>>>> API. It uses ZnEasy to post data to their api servers.
>>> 
>>> Any idea at what rate you are posting, just a ballpark figure ?
>> 
>> Maybe 50 POSTs in half an hour.  Just messing with sending and receiving
>> SMS
>> messages.  
> 
> That is not fast enough to cause trouble I would think, maybe something
> else prevents the sockets from closing.
> 
> 

I was also using the ZnStaticFileServerDelegate so there were also instances
of FileStream about.  In fact at this time I'm guessing that that may be the
culprit because it happened again yesterday while not using any of the
ZnClient functionality. When the error was raised I did inspect the
ExternalSemaphoreTable unprotectedExternalObjects and a significant portion
of the slots in the array were nil.   Maybe I'm looking at the wrong thing.  


Sven Van Caekenberghe wrote
> 
> 
> Stripe is interesting, I want to hear how it goes.
> 

The package works fine and I added the ability to receive and log events
from them using their WebHooks functionality all using Zinc/Zodiac +
SSLPlugin. So I think it implements most of their  API.   Also can run it
behind nginx as needed.  


Sven Van Caekenberghe wrote
> 
>> Sven Van Caekenberghe wrote
>>> 
>>> If you are talking about regular HTTP, then you must have loaded the
>>> somewhat older/experimental ZdcNetworkingUtils, and are not using
>>> regular
>>> SocketStreams but ZdcOptimizedSocketStreams. Which is brave since this
>>> is
>>> something I am not doing myself ;-)
>> 
>> I have these versions loaded: Zodiac-Core-SvenVanCaekenberghe.17 &
>> Zinc-HTTP-SvenVanCaekenberghe.275
>> 
>> As far as I know I've done nothing to actively choose anything other than
>> the defaults.  
> 
> What does ZnNetworkingUtils default socketStreamClass return ?
> 

 ZdcSocketStream


Thanks again and I really should just make the external table bigger than
what it is now so this issue doesn't come up as often.  

Paul

--
View this message in context: http://forum.world.st/ZnClient-close-socket-semaphores-tp4630357p4632804.html
Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.




More information about the Pharo-users mailing list