You could use SimpleXMLRPCServer to create a client in your view.py
with a function to call the server side, and pass the information over
when done.

See: http://docs.python.org/library/simplexmlrpcserver.html

You'd need to have the server side running the whole time in the
background, if you loose the connection, then it would need to be
restarted otherwise you'll get a 'connection refused'.

Martyn

On Oct 20, 6:38 am, Ken <xie.kenn...@gmail.com> wrote:
> Hello all
>     I'm new to django and I have a question.
>
>     I want to find a way to run some code periodicly in the background.
> Because I have a fax device which will put incoming call data in the
> database, I scan the database each 3 minutes for new incomings.
>
>     In tomcat when I can make a servlet load on startup. I add
> "<load-on-startup>0</load-on-startup>"  in the web.xml file. This servlet
> will be autoloaded when tomcat started and I then started the 3-min rountine
> repeatly.
>
>     I wonder how do I do the same in django framework. Or there is some
> other way to run some background code periodicly?
>
>     Thank you in advance.
>
>                                                         Ken

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to