[Seaside] Very wierd IACache problems

Tim Rowledge seaside@lists.squeakfoundation.org
Wed, 17 Jul 2002 23:32:05 -0700


Avi Bryant <avi@beta4.com> is claimed by the authorities to have written:

> The numbers seem right - each application has an LRUCache of (by default) 10
> sessions, each of which have their own LRUCache of transactions... so 10
> apps would give 110 Caches (how many of the examples do you have
> running?).  Each transaction has an IACache of PageStates, so if most
> sessions had only one transaction, you'd see 100 IACaches.  If you clear
> out unused example applications, these numbers should go down.
OK, that sounds reasonable, though it might be nice to make it an
on-demand process of building them.
> 
> Except the eeeenormous tables full of keys bit.  These are LRUCaches with
> loads of weak references?  That doesn't sound so good.  Perhaps I'll have
> to do some pointer chasing.  Ugh.
Yeah, looks ugly. It appears to be several hundred at least (925 in
fact!). The only thing I noticed that might have anything to do with it
is that #remove: is a null method. 
> 
> As for the error... when does it happen?  When you start a new session?
> When you try to use a really old one?  All the time?  Can you give me a
> sample url that causes it, and one that doesn't, for example?
Now there's the interesting part. It only seems to happen with browsers
on OSX with seaside on OSX. I even tried IE (yuck - it has enough
problems with screwed up handling of dynamic content anyway) andit
immediately started having the same problem. Yet from my Acorn machine
I have no problems at all, exactly the same URL (with the obvious and
perhaps important difference of the machine name instead of 'localhost')
since it's the same aplication, same image.

Of possible interest is the fact that when it dies the URL in the
browser url field is ..mumble../act with no reference to the session etc
in there, unlike every other time I get to notice
it.http://gurgeh:8080/seaside/basicDemo/view?session=3F4EA0567E9D4002&tx
n=top&page=21 is more usual for example. The error brings with it a page
claimingto redirect me to
/seaside/basiceDemo/view?session=3E44990C7C893202&txn=current&page=curre
nt but it doesn't go anywhere since I get the notifier in the image.

The debug.log is:-
Error: No such page state: current
17 July 2002 11:24:18 pm

VM: Mac OS - Squeak3.2gamma of 15 January 2002 [latest update: #4857] Squeak VM 3.2.7b5
Image: Squeak3.2gamma [latest update: #4889]

IATransaction(Object)>>error:
	Receiver: an IATransaction
	Arguments and temporary variables: 
		aString: 	'No such page state: current'
	Receiver's instance variables: 
		parent: 	nil
		pageStates: 	an IACache
		callbacks: 	a Dictionary()
		id: 	'top'
		children: 	nil

IATransaction>>pageStateAt:
	Receiver: an IATransaction
	Arguments and temporary variables: 
		anID: 	'current'
	Receiver's instance variables: 
		parent: 	nil
		pageStates: 	an IACache
		callbacks: 	a Dictionary()
		id: 	'top'
		children: 	nil

IATransaction>>pageHasBeenAccessed:
	Receiver: an IATransaction
	Arguments and temporary variables: 
		pageID: 	'current'
	Receiver's instance variables: 
		parent: 	nil
		pageStates: 	an IACache
		callbacks: 	a Dictionary()
		id: 	'top'
		children: 	nil

IATransaction>>newViewContextAt:
	Receiver: an IATransaction
	Arguments and temporary variables: 
		anID: 	'current'
		state: 	nil
		page: 	nil
		nextID: 	'1'
		c: 	nil
	Receiver's instance variables: 
		parent: 	nil
		pageStates: 	an IACache
		callbacks: 	a Dictionary()
		id: 	'top'
		children: 	nil

--- The rest of the stack ---
OTDemoSession(IASession)>>viewPage:
OTDemoSession(IASession)>>handleView
[] in OTDemoSession(IASession)>>performAction:
BlockContext>>on:do:
OTDemoSession(IASession)>>performAction:
[] in OTDemoSession(IASession)>>performAction:withRequest:response:
OTDemoSession(IASession)>>inTransaction:do:
[] in OTDemoSession(IASession)>>performAction:withRequest:response:
[] in BlockContext>>newProcess

It's very odd indeed. I sort of imagined at first it was simply due to
runnign the image for so long and having had lots of bugs occur, leaving
pigeon droppings to be cleared out, but it works just fine from
another machine...

tim
-- 
Tim Rowledge, tim@sumeru.stanford.edu, http://sumeru.stanford.edu/tim
Useful random insult:- Diarrhea of the mouth; constipation of the ideas.