![]() rq enqueue path.to.func -> queue.enqueue(path.to.func, open('path/to/file', 'r').read()).rq enqueue path.to.func abc=def -> queue.enqueue(path.to.func, abc='def').rq enqueue path.to.func abc -> queue.enqueue(path.to.func, 'abc').If the first character of is the subsequent path will be read. Where is the keyword and is the value which is parsed with the corresponding Because it is technicallyĪn import _name_ = '_main_' will not work. Execute a python file: dot-separated pathname of the file.Execute a function: dot-separated string of package, module and function (Just like.-schedule-at Schedule job to be enqueued at a certain time formatted.-schedule-in Delay until the function is enqueued (e.g.-retry-interval Interval between retries in seconds.-at-front Will place the job at the front of the queue, instead. ![]() -depends-on Specifies another job id that must complete before this.-description Additional description of the job.-failure-ttl Specifies how long failed jobs are kept.-ttl Specifies the maximum queued time of the job before.-result-ttl Specifies how long successful jobs and their results.-timeout Specifies the maximum runtime of the job before it is.To your job and not to RQ’s enqueue function, this is what you do: In the last case, if you want to pass description and ttl keyword arguments This is useful if your function happens to haveĬonflicting argument names with RQ, for example description or ttl. args and kwargs: use these to explicitly pass arguments and keyword to the.on_stopped allows you to run a function after a job is stopped.on_failure allows you to run a function after a job fails.on_success allows you to run a function after a job completes successfully. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |