On Mon, 20 Sep 2010, Schwab,Wilhelm K wrote:
Levente,
If they worked correctly, they would, at least under naive client conditions - a connection attempt should try until it is told (#terminate) to stop. Severs that listen for a limited time are broken by design. ConnectionQueue polls as a result - it's pretty bad.
I guess you're using Socket>>#connectTo:port: which uses Socket class>>#standardTimeout as timeout (45 seconds). If you don't want the default timeout, use #connectTo:port:waitForConnectionFor: or implement your own low level method which waits on semaphore until it's signaled. If you want to terminate the connection attempt, just signal the semaphore yourself, like here: s := Socket newTCP. s connectNonBlockingTo: #[127 0 0 1] port: 19327. "Random port which is not open." [ 500 milliSeconds asDelay wait. s semaphore signal ] fork. "This process will stop the connection attempt." s semaphore waitTimeoutMSecs: 1000. s statusString. "This will simply print the socket status. You can terminate the process here if the socket is connected, etc." And for ConnectionQueue, simply don't use it if you don't like it. It doesn't have to poll at all, AFAIK it's just implemented that way. Since Sockets use Semaphores which are signaled by the SocketPlugin, they don't block the image at all. But correct me if I'm wrong. Levente
Bill
________________________________________ From: pharo-project-bounces@lists.gforge.inria.fr [pharo-project-bounces@lists.gforge.inria.fr] On Behalf Of Levente Uzonyi [leves@elte.hu] Sent: Monday, September 20, 2010 7:01 PM To: Pharo-project@lists.gforge.inria.fr Subject: Re: [Pharo-project] we need to find a way to declare that an action is UIless
On Mon, 20 Sep 2010, Schwab,Wilhelm K wrote:
Guillermo,
One has to be careful with assuming that something affects only part of the image. Much of Squeak's networking trouble comes from the fact that it was designed to block the image for a limited time when it should have been blocking only one Process *indefinitely*. But, the remedy for working while blocking operations happen in the background is threading, and most of the image is deliberately not thread safe.
When does a Socket block the image?
Levente
Bill
________________________________________ From: pharo-project-bounces@lists.gforge.inria.fr [pharo-project-bounces@lists.gforge.inria.fr] On Behalf Of Guillermo Polito [guillermopolito@gmail.com] Sent: Sunday, September 19, 2010 10:56 PM To: Pharo-project@lists.gforge.inria.fr Subject: Re: [Pharo-project] we need to find a way to declare that an action is UIless
+1 to Bill's. If we can't have a feedback from the system while doing silent actions, we can think it just freezed :S.
And it's something already dicussed, but I don't like actions that affect only a part of the system blocking my whole image.
Guille
On Sun, Sep 19, 2010 at 10:40 PM, Igor Stasenko <siguctua@gmail.com<mailto:siguctua@gmail.com>> wrote: On 20 September 2010 03:09, Schwab,Wilhelm K <bschwab@anest.ufl.edu<mailto:bschwab@anest.ufl.edu>> wrote:
Slow access can be a big problem. Any such change should be made based on measurements so we know what benefit we get at what cost.
Yeah, it would be much easier to deal that line in Self or JavaScript, where you can add any properties to object on the fly, without need of adding a methods or declaring additional instance variable in class...
________________________________________ From: pharo-project-bounces@lists.gforge.inria.fr<mailto:pharo-project-bounces@lists.gforge.inria.fr> [pharo-project-bounces@lists.gforge.inria.fr<mailto:pharo-project-bounces@lists.gforge.inria.fr>] On Behalf Of Igor Stasenko [siguctua@gmail.com<mailto:siguctua@gmail.com>] Sent: Sunday, September 19, 2010 7:56 PM To: Pharo-project@lists.gforge.inria.fr<mailto:Pharo-project@lists.gforge.inria.fr> Subject: Re: [Pharo-project] we need to find a way to declare that an action is UIless
On 19 September 2010 13:12, Stéphane Ducasse <stephane.ducasse@inria.fr<mailto:stephane.ducasse@inria.fr>> wrote:
hi guys
I tried to add borderStyle to BorderedMorph and the progressbar showing the progress blow up. So we should really have a way to specify silent ui action. Does anybody have an idea how I could do that?
[BorderedMorph addInstVarNamed: 'borderStyle'] silent would be cool.
use morph propertyAt: #borderStyle so you don't have to break your head with it :)
BorderedMorph having an enormous number of subclasses, while some of them even don't using any kind of borders. That's makes me wonder if anything like color, border style etc should belong to root classes in hierarchy, like Morph or BorderedMorph. I think that dynamic set of properties (which is currently sits in morphic extensions are more appropriate storage for them). The only problem is that accessing them is much slower than ivars.
Stef _______________________________________________ Pharo-project mailing list Pharo-project@lists.gforge.inria.fr<mailto:Pharo-project@lists.gforge.inria.fr> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
-- Best regards, Igor Stasenko AKA sig.
_______________________________________________ Pharo-project mailing list Pharo-project@lists.gforge.inria.fr<mailto:Pharo-project@lists.gforge.inria.fr> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
_______________________________________________ Pharo-project mailing list Pharo-project@lists.gforge.inria.fr<mailto:Pharo-project@lists.gforge.inria.fr> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
-- Best regards, Igor Stasenko AKA sig.
_______________________________________________ Pharo-project mailing list Pharo-project@lists.gforge.inria.fr<mailto:Pharo-project@lists.gforge.inria.fr> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
_______________________________________________ Pharo-project mailing list Pharo-project@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
_______________________________________________ Pharo-project mailing list Pharo-project@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project