Technical mailing list archives

Re: How to get a new cursor on new api on Thread

Suzanne Jean-Sébastien
- 09/25/2014 01:34:59

2014-09-25 6:17 GMT+02:00 Maxim Litnitskiy <>:
Hi all!
Thanks Jean-Sébastien.
I will post feedback on your adise a bit later.
Still exprerimenting.
I have a small question.
Is it correct at all to start a few threads on button click?

In my mind, they are any interest to use a thread. if you want execute your code in back task, you should use an ir.cron
I have a button with type action which runs a model method.
So from this method I spawn 2 threads.
Is it ok at all?
Because now I am beating a strange situations.
My model hangs!
I can F5 and go other parts of Odoo (Messages, Sales, etc).
But when I try to  open my model OpenERP hangs.

Sorry I don't understand
Please advise!

Post to:

Jean-Sébastien SUZANNE
06 51 35 50 50