[Pharo-project] Swazoo keeping HTTPConnections open

Nicolas Petton petton.nicolas at gmail.com
Wed Jun 22 06:21:05 EDT 2011


Hi Bernat,

I have a patch that may solve your problem that will be integrated
mainstream. In the meantime:

HTTPConnection>>close
	self stream notNil ifTrue: [self stream close. stream := nil].
	self server notNil ifTrue: [self server removeConnection: self].
	self loop notNil ifTrue: [
		| process | 
		process := loop. loop := nil. 
		process terminate]


HTH,
Nicolas

Le mercredi 22 juin 2011 à 11:36 +0200, Bernat Romagosa a écrit :
> Hi list, I don't know where should I address this issue, so please
> excuse me if this mail is a bit off-topic.
> 
> 
> I've been running an Iliad app in Pharo for a couple of months, and
> just today I realised the image was behaving quite sluggish, so I
> checked the process browser and discovered thousands (literally) of
> Delay >> wait instances going on. Inspecting them, I found out they
> had all been spawned by Swazoo's HTTPConnection >> interact.
> 
> 
> So what I did is HTTPConnection allInstancesDo: [:c | c close], which
> took quite a while to conclude, and the problem was solved, but these
> processes keep on spawning every time a user logs in, and they never
> seem to die unless I tell them to.
> 
> 
> Also, killing these processes seems to have no effect on the
> application behaviour at all, all sessions stay where they should and
> everything is alright, so I'm even considering using a scheduler that
> kills'em'all every hour or so (how elegant could this be!)
> 
> 
> Has anybody ran into a similar issue before?
> 
> 
> Thanks!
> 
> -- 
> Bernat Romagosa.
> 

-- 
Nicolas Petton
http://www.nicolas-petton.fr





More information about the Pharo-dev mailing list