Caching session on canvas?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Caching session on canvas?

Boris Popov, DeepCove Labs (SNN)
I've been thinking of removing the cost associated with lookup of a
current session by caching it on a canvas when its created in
WAPresenter>>renderWithContext: are there any gotchas I might be
missing?

Cheers!

-Boris

--
+1.604.689.0322
DeepCove Labs Ltd.
4th floor 595 Howe Street
Vancouver, Canada V6C 2T5

[hidden email]

CONFIDENTIALITY NOTICE

This email is intended only for the persons named in the message
header. Unless otherwise indicated, it contains information that is
private and confidential. If you have received it in error, please
notify the sender and delete the entire message including any
attachments.

Thank you.

_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Caching session on canvas?

Avi  Bryant

On Oct 25, 2006, at 1:57 PM, Boris Popov wrote:

> I've been thinking of removing the cost associated with lookup of a
> current session by caching it on a canvas when its created in
> WAPresenter>>renderWithContext: are there any gotchas I might be
> missing?

If you're going to cache it, you might as well do that at the  
RenderingContext level rather than on individual canvases (since a  
new canvas is created for each component).

Or you could cache it in each component - I (at least) tend to use  
"self session" on components most often.

I can't think of any gotchas with any of this.  None of these objects  
should ever be moving between sessions.

Avi
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

RE: Caching session on canvas?

Boris Popov, DeepCove Labs (SNN)
Thanks for the hint, I think I'll do a combination of two actually. Its
gotten to the point where using notification to find a session started
showing up in profiles of largish/complicatedish reports (~8
microseconds per call adds up).

Cheers,

-Boris

--
+1.604.689.0322
DeepCove Labs Ltd.
4th floor 595 Howe Street
Vancouver, Canada V6C 2T5

[hidden email]

CONFIDENTIALITY NOTICE

This email is intended only for the persons named in the message
header. Unless otherwise indicated, it contains information that is
private and confidential. If you have received it in error, please
notify the sender and delete the entire message including any
attachments.

Thank you.

-----Original Message-----
From: [hidden email]
[mailto:[hidden email]] On Behalf Of Avi
Bryant
Sent: Wednesday, October 25, 2006 2:08 PM
To: The Squeak Enterprise Aubergines Server - general discussion.
Subject: Re: [Seaside] Caching session on canvas?


On Oct 25, 2006, at 1:57 PM, Boris Popov wrote:

> I've been thinking of removing the cost associated with lookup of a
> current session by caching it on a canvas when its created in
> WAPresenter>>renderWithContext: are there any gotchas I might be
> missing?

If you're going to cache it, you might as well do that at the  
RenderingContext level rather than on individual canvases (since a  
new canvas is created for each component).

Or you could cache it in each component - I (at least) tend to use  
"self session" on components most often.

I can't think of any gotchas with any of this.  None of these objects  
should ever be moving between sessions.

Avi
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

RE: Caching session on canvas?

Boris Popov, DeepCove Labs (SNN)
In reply to this post by Avi Bryant
By the way, I'd just realized that session is cached on response
already, so storing it on the rendering context would be redundant, all
I needed to do is look first and ask later :)

Cheers!

-Boris

--
+1.604.689.0322
DeepCove Labs Ltd.
4th floor 595 Howe Street
Vancouver, Canada V6C 2T5

[hidden email]

CONFIDENTIALITY NOTICE

This email is intended only for the persons named in the message
header. Unless otherwise indicated, it contains information that is
private and confidential. If you have received it in error, please
notify the sender and delete the entire message including any
attachments.

Thank you.

-----Original Message-----
From: [hidden email]
[mailto:[hidden email]] On Behalf Of Avi
Bryant
Sent: Wednesday, October 25, 2006 2:08 PM
To: The Squeak Enterprise Aubergines Server - general discussion.
Subject: Re: [Seaside] Caching session on canvas?


On Oct 25, 2006, at 1:57 PM, Boris Popov wrote:

> I've been thinking of removing the cost associated with lookup of a
> current session by caching it on a canvas when its created in
> WAPresenter>>renderWithContext: are there any gotchas I might be
> missing?

If you're going to cache it, you might as well do that at the  
RenderingContext level rather than on individual canvases (since a  
new canvas is created for each component).

Or you could cache it in each component - I (at least) tend to use  
"self session" on components most often.

I can't think of any gotchas with any of this.  None of these objects  
should ever be moving between sessions.

Avi
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside