Re: Proposal: Let session support backends

2007-06-10 Thread Jacob Kaplan-Moss
On 6/10/07, John D'Agostino <[EMAIL PROTECTED]> wrote: > Would one of the core devs comment if this on the right track? Sounds about right to me; I'd love to see the code! Jacob --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Goo

Re: Proposal: Let session support backends

2007-06-10 Thread John D'Agostino
I started implementing this a few months ago. I've factored out SessionWrapper as SessionObject, as a base class and (re)implemented the database session store on top. I've also got a working implementation of a FileSession class. Summary of changes: Added a SESSION_ENGINE to settings.py Added

Performance-related fixes [was: Ping: Extend "for" tag to allow unpacking of lists]

2007-06-10 Thread Jacob Kaplan-Moss
On 6/10/07, Brian Harring <[EMAIL PROTECTED]> wrote: > Had a nice funny rant typed up related to the general lack of code > efficiency in template code (ticket 4523 is an example) [... snip] Just a heads-up to you and anyone else who notices stuff like this: Performance is near and dear to me, a

Re: signals

2007-06-10 Thread Jacob Kaplan-Moss
On 6/10/07, Jeremy Dunck <[EMAIL PROTECTED]> wrote: > Jellyroll does, too: > http://jellyroll.googlecode.com/svn/trunk/jellyroll/managers.py > > I really like that technique, and plan to do similar in future. Indeed; I (ab)use the hell out of signals, and would be sad without 'em. Nearly every tr

Re: signals

2007-06-10 Thread [EMAIL PROTECTED]
On Jun 10, 10:29 pm, "James Bennett" <[EMAIL PROTECTED]> wrote: > I'm working on something which will be leaning pretty heavily on the > pre_save and post_save signals; the code's not public yet, but will be > soon. I use these in django-multilingual to update translations when an instance of a

Re: signals

2007-06-10 Thread Jeremy Dunck
On 6/10/07, James Bennett <[EMAIL PROTECTED]> wrote: > > On 6/10/07, Brian Harring <[EMAIL PROTECTED]> wrote: > > Aside from that, would really help if I had a clue what folks are > > actually using dispatch for with django- which signals, common > > patterns for implementing their own signals (pr

Re: signals

2007-06-10 Thread James Bennett
On 6/10/07, Brian Harring <[EMAIL PROTECTED]> wrote: > Aside from that, would really help if I had a clue what folks are > actually using dispatch for with django- which signals, common > patterns for implementing their own signals (pre/post I'd assume?), > common signals they're listening to, etc

Re: Ping: Extend "for" tag to allow unpacking of lists

2007-06-10 Thread Brian Harring
On Fri, Jun 08, 2007 at 11:05:01PM -, SmileyChris wrote: > > On Jun 9, 9:32 am, Brian Harring <[EMAIL PROTECTED]> wrote: > > Realize it's hit trunk already, > No worries, we can always open another ticket :) Already watching enough tickets ;) > > but noticed an annoying potential > > gotcha

signals

2007-06-10 Thread Brian Harring
Curious, how many folks are actually using dispatch at all? For my personal usage, I'm actually not using any of the hooks- I suspect most folks aren't either. That said, I'm paying a fairly hefty price for them. With Model.__init__'s send left in for 53.3k record instantiation (just a walk o

Re: Event based caching

2007-06-10 Thread [EMAIL PROTECTED]
I've filed a ticket on this as well: http://code.djangoproject.com/ticket/4520 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@google

Re: Event based caching

2007-06-10 Thread [EMAIL PROTECTED]
Hi 黄毅, That is one way of doing it, but it would be even better if it was implicit. I'm not sure how one would implement this into django.core.cache. I guess Django must know the cache keys somewhere internally, but how do we automate the process of touching the cached object on POST? On Jun 10,

Re: Event based caching

2007-06-10 Thread Michael Trier
Henrik, I'm sure a lot of people would benefit from an event based caching system. So I know that I for one am eagerly looking forward to seeing your contribution. Michael On 6/10/07, 黄毅 <[EMAIL PROTECTED]> wrote: > If i understand what you are talking about, I think it's quite easy to > imple

Question about djangobook

2007-06-10 Thread kernel1983
Who manipulates the djangobook now? Or it's manipulated like a wiki? Is there any version in other languages planning? By the way, if there is a planning that django's official site in other language? --~--~-~--~~~---~--~~ You received this message because you

Re: Proposal: Let session support backends

2007-06-10 Thread kernel1983
I've write some code for a simple implement of the session middleware. But there are some problem that I was too busy to solve these days. It refers to the cache module's simple impl. Now it can be only used in debug mode. And the session id is fixed(of course it's for testing) I'm so glad that

Re: Event based caching

2007-06-10 Thread 黄毅
If i understand what you are talking about, I think it's quite easy to implement a event-based cache system using signals. It's something like this: def article_posted(article): touch the cached article touch some cached article list dispatcher.connect(article_posted, signal=your_signals.a

Event based caching

2007-06-10 Thread [EMAIL PROTECTED]
First of all, I have to say that the cache framework is golden. It's very good for e.g. news sites and that sort - but exceptions do occur. I would like to see event based caching implemented into Django. The current time based cache framework doesn't always do the trick. When you have a site with