Google Groups Home
Help | Sign in
django admin + apache + mod_python => breakage
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  1 message - Collapse all
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
Bram - Smartelectronix  
View profile
 More options Jul 28 2007, 8:45 am
From: Bram - Smartelectronix <b...@smartelectronix.com>
Date: Sat, 28 Jul 2007 14:45:45 +0200
Local: Sat, Jul 28 2007 8:45 am
Subject: django admin + apache + mod_python => breakage
hello everyone,

I have a rather "well connected" model like this ( used here:
http://www.splicemusic.com/contests/ ):

class Contest(models.Model):
     [ snip of regular fields ]

     # the sounds people HAVE to use to enter the contest
     required_sounds = models.ManyToManyField(Sound, null=True,
                       blank=True)

     # the soungs people HAVE to use to enter the contest
     required_songs = models.ManyToManyField(Song, null=True, blank=True)

     # how they should tag theior sounds to enter the competition
     sound_tag = models.ForeignKey('Tag',
                 related_name=u'contest_sound_set')

     # how they should tag their song to enter the competition
     song_tag = models.ForeignKey('Tag',
                related_name=u'contest_song_set')

     # the winners of the contes if it's already finished
     winners = models.ManyToManyField(Profile, null=True, blank=True)

     # a forum thread w/ more explanations
     forum_thread = models.ForeignKey(Thread, null=True, blank=True)

As you can see, quite a lot of many-to-many and foreign keys in there
(and they all point to tables with over 30K entries, so the admin page
takes about 10 minutes to load). Now, when we try to edit this model in
the admin the apache instance goes nuts and starts eating ALL the memory
on the machine: it almost immediately jumps to 1.5GB of RAM and then
just keeps consuming until the kernell kills the process.

Does anyone have an idea why this could be?? No other models in our
application show this behaviour (then again, no other model has this
many connections to the rest of the models)

Editing the model via manage.py shell works just fine.

  - bram


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2008 Google