Job Queue Batch

queue_job_batch
REPOSITORY
REPOSITORYOCA/queue
GIT
GIThttps://github.com/OCA/queue.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/queue/tree/19.0/queue_job_batch
VERSION
VERSION 1.0.0
CATEGORY
CATEGORYGeneric Modules
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Creu Blanca
MAINTAINERS
MAINTAINERSOdoo Community Association (OCA), Creu Blanca
COMMITTERS
COMMITTERSStéphane Bidoul
WEBSITE
WEBSITEhttps://github.com/OCA/queue
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 19:40:49
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/queue:
    - queue_job
odoo/odoo:
    - mail
    - base
    - base_setup
    - web
    - bus
    - web_tour
    - html_editor
    - base_sparse_field
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES openupgradelib
requests
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
This addon adds an a grouper for queue jobs.

It allows to show your jobs in a batched form in order to know better
the results.

Example:

``` python
from odoo import models, fields, api


class MyModel(models.Model):
    _name = 'my.model'

    def my_method(self, a, k=None):
        _logger.info('executed with a: %s and k: %s', a, k)


class MyOtherModel(models.Model):
    _name = 'my.other.model'

    @api.multi
    def button_do_stuff(self):
        batch = self.env['queue.job.batch'].get_new_batch('Group')
        model = self.env['my.model'].with_context(job_batch=batch)
        for i in range(1, 100):
            model.with_delay().my_method('a', k=i)
```

In the snippet of code above, when we call `button_do_stuff`, 100 jobs
capturing the method and arguments will be postponed. It will be
executed as soon as the Jobrunner has a free bucket, which can be
instantaneous if no other job is running.

Once all the jobs have finished, the grouper will be marked as finished.

Code Analysis

Views touched (5)
XML IDNameModelTypeStatus
view_queue_job_batch_form queue.job.batch.form queue.job.batch form New
view_queue_job_batch_search queue.job.batch.search queue.job.batch search New
view_queue_job_batch_tree queue.job.batch.tree queue.job.batch list New
view_queue_job_form queue.job.form queue.job field Inherits queue_job.view_queue_job_form
view_queue_job_search queue.job.search queue.job field Inherits queue_job.view_queue_job_search
Models touched (3)

New fields (1)
  • job_batch_id Many2one → queue.job.batch
    args: 'queue.job.batch'
Public methods (2)
  • create(self, vals_list)
    @api.model_create_multi
  • write(self, vals)

New fields (11)
  • company_id Many2one → res.company
    readonly=True args: 'res.company'
  • completeness Float
    compute='_compute_job_count'
  • failed_job_count Float
    compute='_compute_job_count'
  • failed_percentage Float
    compute='_compute_job_count'
  • finished_job_count Float
    compute='_compute_job_count'
  • is_read Boolean
  • job_count Integer
    compute='_compute_job_count'
  • job_ids One2many → queue.job
    inverse_name='job_batch_id' readonly=True args: 'queue.job'
  • name Char
    readonly=True required=True tracking=True
  • state Selection
    default='pending' readonly=True required=True tracking=True args: [('pending', 'Pending'), ('enqueued', 'Enqueued'), ('progress', 'In Progress'), ('finished', 'Finished')]
  • user_id Many2one → res.users
    readonly=True required=True tracking=True args: 'res.users'
Public methods (3)
  • check_state(self)
  • get_new_batch(self, name, **kwargs)
    @api.model
  • set_read(self)

New fields (0)

No new fields.

Public methods (0)

No public methods.

REPOSITORY
REPOSITORYOCA/queue
GIT
GIThttps://github.com/OCA/queue.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/queue/tree/18.0/queue_job_batch
VERSION
VERSION 1.1.0
CATEGORY
CATEGORYGeneric Modules
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Creu Blanca
MAINTAINERS
MAINTAINERSOdoo Community Association (OCA), Creu Blanca
COMMITTERS
COMMITTERSWeblate, OCA-git-bot, Iván Todorovich, oca-ci, hoangtrann
WEBSITE
WEBSITEhttps://github.com/OCA/queue
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 19:30:14
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/queue:
    - queue_job
odoo/odoo:
    - mail
    - base
    - base_setup
    - web
    - bus
    - web_tour
    - html_editor
    - base_sparse_field
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES requests
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
This addon adds an a grouper for queue jobs.

It allows to show your jobs in a batched form in order to know better
the results.

Example:

``` python
from odoo import models, fields, api


class MyModel(models.Model):
    _name = 'my.model'

    def my_method(self, a, k=None):
        _logger.info('executed with a: %s and k: %s', a, k)


class MyOtherModel(models.Model):
    _name = 'my.other.model'

    @api.multi
    def button_do_stuff(self):
        batch = self.env['queue.job.batch'].get_new_batch('Group')
        model = self.env['my.model'].with_context(job_batch=batch)
        for i in range(1, 100):
            model.with_delay().my_method('a', k=i)
```

In the snippet of code above, when we call `button_do_stuff`, 100 jobs
capturing the method and arguments will be postponed. It will be
executed as soon as the Jobrunner has a free bucket, which can be
instantaneous if no other job is running.

Once all the jobs have finished, the grouper will be marked as finished.

Code Analysis

Views touched (5)
XML IDNameModelTypeStatus
view_queue_job_batch_form queue.job.batch.form queue.job.batch form New
view_queue_job_batch_search queue.job.batch.search queue.job.batch search New
view_queue_job_batch_tree queue.job.batch.tree queue.job.batch list New
view_queue_job_form queue.job.form queue.job field Inherits queue_job.view_queue_job_form
view_queue_job_search queue.job.search queue.job field Inherits queue_job.view_queue_job_search
Models touched (3)

New fields (1)
  • job_batch_id Many2one → queue.job.batch
    index='btree_not_null' args: 'queue.job.batch'
Public methods (2)
  • create(self, vals_list)
    @api.model_create_multi
  • write(self, vals)

New fields (11)
  • company_id Many2one → res.company
    readonly=True args: 'res.company'
  • completeness Float
    compute='_compute_job_count'
  • failed_job_count Float
    compute='_compute_job_count'
  • failed_percentage Float
    compute='_compute_job_count'
  • finished_job_count Float
    compute='_compute_job_count'
  • is_read Boolean
  • job_count Integer
    compute='_compute_job_count'
  • job_ids One2many → queue.job
    inverse_name='job_batch_id' readonly=True args: 'queue.job'
  • name Char
    readonly=True required=True tracking=True
  • state Selection
    default='pending' readonly=True required=True tracking=True args: [('pending', 'Pending'), ('enqueued', 'Enqueued'), ('progress', 'In Progress'), ('finished', 'Finished')]
  • user_id Many2one → res.users
    readonly=True required=True tracking=True args: 'res.users'
Public methods (3)
  • check_state(self)
  • get_new_batch(self, name, **kwargs)
    @api.model
  • set_read(self)

New fields (0)

No new fields.

Public methods (0)

No public methods.

REPOSITORY
REPOSITORYOCA/queue
GIT
GIThttps://github.com/OCA/queue.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/queue/tree/16.0/queue_job_batch
VERSION
VERSION 1.0.1
CATEGORY
CATEGORYGeneric Modules
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Creu Blanca
MAINTAINERS
MAINTAINERSOdoo Community Association (OCA), Creu Blanca
COMMITTERS
COMMITTERSWeblate, OCA-git-bot, oca-ci, JasminSForgeFlow
WEBSITE
WEBSITEhttps://github.com/OCA/queue
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:53:50
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/queue:
    - queue_job
odoo/odoo:
    - mail
    - base
    - base_setup
    - web
    - bus
    - web_tour
    - base_sparse_field
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES requests
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (5)
XML IDNameModelTypeStatus
view_queue_job_batch_form queue.job.batch.form queue.job.batch form New
view_queue_job_batch_search queue.job.batch.search queue.job.batch search New
view_queue_job_batch_tree queue.job.batch.tree queue.job.batch tree New
view_queue_job_form queue.job.form queue.job field Inherits queue_job.view_queue_job_form
view_queue_job_search queue.job.search queue.job field Inherits queue_job.view_queue_job_search
Models touched (2)

New fields (1)
  • job_batch_id Many2one → queue.job.batch
    args: 'queue.job.batch'
Public methods (2)
  • create(self, vals)
    @api.model
  • write(self, vals)

New fields (11)
  • company_id Many2one → res.company
    readonly=True args: 'res.company'
  • completeness Float
    compute='_compute_job_count'
  • failed_job_count Float
    compute='_compute_job_count'
  • failed_percentage Float
    compute='_compute_job_count'
  • finished_job_count Float
    compute='_compute_job_count'
  • is_read Boolean
    default=True
  • job_count Integer
    compute='_compute_job_count'
  • job_ids One2many → queue.job
    inverse_name='job_batch_id' readonly=True args: 'queue.job'
  • name Char
    readonly=True required=True tracking=True
  • state Selection
    default='draft' readonly=True required=True tracking=True args: [('draft', 'Draft'), ('enqueued', 'Enqueued'), ('progress', 'In Progress'), ('finished', 'Finished')]
  • user_id Many2one → res.users
    readonly=True required=True tracking=True args: 'res.users'
Public methods (4)
  • check_state(self)
  • enqueue(self)
  • get_new_batch(self, name, **kwargs)
    @api.model
  • set_read(self)
REPOSITORY
REPOSITORYOCA/queue
GIT
GIThttps://github.com/OCA/queue.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/queue/tree/14.0/queue_job_batch
VERSION
VERSION 1.0.2
CATEGORY
CATEGORYGeneric Modules
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Creu Blanca
MAINTAINERS
MAINTAINERSOdoo Community Association (OCA), Creu Blanca
COMMITTERS
COMMITTERSPierre Verkest, Weblate, OCA-git-bot, Simone Orsi, oca-ci, Diep Huu Hoang
WEBSITE
WEBSITEhttps://github.com/OCA/queue
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:41:03
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/queue:
    - queue_job
odoo/odoo:
    - mail
    - base
    - base_setup
    - web
    - bus
    - web_tour
    - base_sparse_field
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES requests
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (6)
XML IDNameModelTypeStatus
assets_backend mail assets ir.ui.view qweb Inherits web.assets_backend
view_queue_job_batch_form queue.job.batch.form queue.job.batch form New
view_queue_job_batch_search queue.job.batch.search queue.job.batch search New
view_queue_job_batch_tree queue.job.batch.tree queue.job.batch tree New
view_queue_job_form queue.job.form queue.job field Inherits queue_job.view_queue_job_form
view_queue_job_search queue.job.search queue.job field Inherits queue_job.view_queue_job_search
Models touched (2)

New fields (1)
  • job_batch_id Many2one → queue.job.batch
    args: 'queue.job.batch'
Public methods (2)
  • create(self, vals)
    @api.model
  • write(self, vals)

New fields (11)
  • company_id Many2one → res.company
    readonly=True args: 'res.company'
  • completeness Float
    compute='_compute_job_count'
  • failed_job_count Float
    compute='_compute_job_count'
  • failed_percentage Float
    compute='_compute_job_count'
  • finished_job_count Float
    compute='_compute_job_count'
  • is_read Boolean
    default=True
  • job_count Integer
    compute='_compute_job_count'
  • job_ids One2many → queue.job
    inverse_name='job_batch_id' readonly=True args: 'queue.job'
  • name Char
    readonly=True required=True tracking=True
  • state Selection
    default='draft' readonly=True required=True tracking=True args: [('draft', 'Draft'), ('enqueued', 'Enqueued'), ('progress', 'In Progress'), ('finished', 'Finished')]
  • user_id Many2one → res.users
    readonly=True required=True tracking=True args: 'res.users'
Public methods (4)
  • check_state(self)
  • enqueue(self)
  • get_new_batch(self, name, **kwargs)
    @api.model
  • set_read(self)
REPOSITORY
REPOSITORYOCA/queue
GIT
GIThttps://github.com/OCA/queue.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/queue/tree/12.0/queue_job_batch
VERSION
VERSION 1.0.1
CATEGORY
CATEGORYGeneric Modules
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Creu Blanca
MAINTAINERS
MAINTAINERSOdoo Community Association (OCA), Creu Blanca
COMMITTERS
COMMITTERSStéphane Bidoul, Lois Rilo, OCA Transbot, oca-travis, Weblate, OCA-git-bot, Quentin Groulard
WEBSITE
WEBSITEhttps://github.com/OCA/queue
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:29:20
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/queue:
    - queue_job
odoo/odoo:
    - mail
    - base
    - base_setup
    - web
    - bus
    - web_tour
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES requests
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (6)
XML IDNameModelTypeStatus
assets_backend mail assets ir.ui.view qweb Inherits web.assets_backend
view_queue_job_batch_form queue.job.batch.form queue.job.batch form New
view_queue_job_batch_search queue.job.batch.search queue.job.batch search New
view_queue_job_batch_tree queue.job.batch.tree queue.job.batch tree New
view_queue_job_form queue.job.form queue.job field Inherits queue_job.view_queue_job_form
view_queue_job_search queue.job.search queue.job field Inherits queue_job.view_queue_job_search
Models touched (2)

New fields (1)
  • job_batch_id Many2one → queue.job.batch
    args: 'queue.job.batch'
Public methods (2)
  • create(self, vals)
    @api.model
  • write(self, vals)
    @api.multi

New fields (11)
  • company_id Many2one → res.company
    readonly=True args: 'res.company'
  • completeness Float
    compute='_compute_job_count'
  • failed_job_count Float
    compute='_compute_job_count'
  • failed_percentage Float
    compute='_compute_job_count'
  • finished_job_count Float
    compute='_compute_job_count'
  • is_read Boolean
    default=True
  • job_count Integer
    compute='_compute_job_count'
  • job_ids One2many → queue.job
    inverse_name='job_batch_id' readonly=True args: 'queue.job'
  • name Char
    readonly=True required=True track_visibility='onchange'
  • state Selection
    default='draft' readonly=True required=True track_visibility='onchange' args: [('draft', 'Draft'), ('enqueued', 'Enqueued'), ('progress', 'In Progress'), ('finished', 'Finished')]
  • user_id Many2one → res.users
    readonly=True required=True track_visibility='onchange' args: 'res.users'
Public methods (4)
  • check_state(self)
    @job
  • enqueue(self)
  • get_new_batch(self, name, **kwargs)
    @api.model
  • set_read(self)
    @api.multi
REPOSITORY
REPOSITORYOCA/queue
GIT
GIThttps://github.com/OCA/queue.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/queue/tree/11.0/queue_job_batch
VERSION
VERSION 1.1.1
CATEGORY
CATEGORYGeneric Modules
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Creu Blanca
MAINTAINERS
MAINTAINERSOdoo Community Association (OCA), Creu Blanca
COMMITTERS
COMMITTERSEnric Tobella, Lois Rilo, OCA Transbot, oca-travis, OCA-git-bot
WEBSITE
WEBSITEhttps://github.com/OCA/queue
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:23:59
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/queue:
    - queue_job
odoo/odoo:
    - mail
    - base
    - base_setup
    - web
    - bus
    - web_tour
    - base_sparse_field
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES requests
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (6)
XML IDNameModelTypeStatus
assets_backend mail assets ir.ui.view qweb Inherits web.assets_backend
view_queue_job_batch_form queue.job.batch.form queue.job.batch form New
view_queue_job_batch_search queue.job.batch.search queue.job.batch search New
view_queue_job_batch_tree queue.job.batch.tree queue.job.batch tree New
view_queue_job_form queue.job.form queue.job field Inherits queue_job.view_queue_job_form
view_queue_job_search queue.job.search queue.job field Inherits queue_job.view_queue_job_search
Models touched (2)

New fields (1)
  • job_batch_id Many2one → queue.job.batch
    args: 'queue.job.batch'
Public methods (2)
  • create(self, vals)
    @api.model
  • write(self, vals)
    @api.multi

New fields (11)
  • company_id Many2one → res.company
    readonly=True args: 'res.company'
  • completeness Float
    compute='_compute_job_count'
  • failed_job_count Float
    compute='_compute_job_count'
  • failed_percentage Float
    compute='_compute_job_count'
  • finished_job_count Float
    compute='_compute_job_count'
  • is_read Boolean
    default=True
  • job_count Integer
    compute='_compute_job_count'
  • job_ids One2many → queue.job
    inverse_name='job_batch_id' readonly=True args: 'queue.job'
  • name Char
    readonly=True required=True track_visibility='onchange'
  • state Selection
    default='draft' readonly=True required=True track_visibility='onchange' args: [('draft', 'Draft'), ('enqueued', 'Enqueued'), ('progress', 'In Progress'), ('finished', 'Finished')]
  • user_id Many2one → res.users
    readonly=True required=True track_visibility='onchange' args: 'res.users'
Public methods (4)
  • check_state(self)
    @job
  • enqueue(self)
  • get_new_batch(self, name, **kwargs)
    @api.model
  • set_read(self)
    @api.multi