Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

perform particular action after 5 minutes

By
Jothimani
on 5/31/14, 4:31 AM 844 views

Hello every one,

Here i want perform a particular action, after 5 minutes.

please let me know, is there any way to ahieve this?

and i tried this

import time

import datetime

print "Loop Started"

while
    time.sleep(5)
    print "loop is running"

 

Thanks in advance....

 

 

1

Nehal

--Nehal--
2090
| 5 2 8
Ahmadabad, India
--Nehal--
Nehal
On 5/31/14, 4:35 AM

Hi,

You can create scheduler(ir.cron) with Interval of 5 min to run particular action. You may refer Fetchmail Service cron which runs at every 5 minutes. 

1
Jothimani
On 5/31/14, 7:34 AM

Nehal @ Can you explain briefly please?

You can create method in your py file. and then create ir.cron from xml file. You can refer example from your_addons/fetchmail/fetchmail_data.xml file and _fetch_mails function of fetchmail.py file

Nehal
on 5/31/14, 9:23 AM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 5/31/14, 4:31 AM
Seen: 844 times
Last updated: 3/16/15, 8:10 AM