Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Development

Notices

Reply
 
Thread Tools Search this Thread
Old 03-17-2023, 07:01 AM   #1
Mikowmer
Member
Mikowmer began at the beginning.
 
Posts: 18
Karma: 10
Join Date: Aug 2022
Location: Australia
Device: reMarkable 2
Question Question about API for Workers and Jobs

I'm trying to create a plugin to download ebooks from a source. While at the moment I only want to download one at a time so that I have a minimum viable product I can work from and improve, I would eventually like to allow for multiple downloads to occur in sequence. As such, I would like to know more about how workers and jobs work so that I have an implementation of them to start with and so I don't have to butcher half my code further down the track.

However, I'm struggling to find any documentation on them. Would there be somewhere I could go to that would have documentation in a similar manner to the Plugin and DB API pages?
Mikowmer is offline   Reply With Quote
Old 03-17-2023, 12:02 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,001
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
You dont need to use the API at all, just run your jobs in threads in the background and when they are completed, emit a Qt signal connected to your plugin to handle the results. If you do want to use the calibre jobs system, then there is no API documentation as such, best way to learn it is look at another user interface action plugin that uses jobs. I think count pages or quality check would do.
kovidgoyal is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
more workers to speed up autoadd? jeffery Library Management 3 10-16-2016 03:07 PM
Hard Workers Kate JR Self-Promotions by Authors and Publishers 0 10-11-2016 05:00 PM
Can we move jobs up when running many news fetch jobs ? mixedbag Recipes 3 03-18-2016 12:26 AM


All times are GMT -4. The time now is 11:04 PM.


MobileRead.com is a privately owned, operated and funded community.