2018-02-28 16:31:05 +07:00
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
{
|
|
|
|
'name': "runbot",
|
|
|
|
'summary': "Runbot",
|
|
|
|
'description': "Runbot for Odoo 11.0",
|
|
|
|
'author': "Odoo SA",
|
|
|
|
'website': "http://runbot.odoo.com",
|
|
|
|
'category': 'Website',
|
[IMP] runbot: add a build stat model
When a build is done, various numerical informations could be extracted
from log files. e.g.: global query count or tests query count ...
The extraction regular expression could be hard-coded in a custom step
but there is no place holder where to store the retrieved information.
In order to compare results, we need to store it.
With this commit, a new model `runbot.build.stat` is used to store
key/values pair linked to a build/config_step. That way, extracted
values can be stored.
Also, another `runbot.build.stat.regex` is used to store regular
expressions that can be used to grep log files and extract values.
The regular expression must contain a named group like this:
`(?P<value>.+)`
The text catched by this group MUST be castable into a float.
Optionally, another named group can be used in the regular expresion
like this:
`(?P<key>.+)`
This `key` group will then be used to augment the key name in the
database.
Example:
Consider a log line like this one:
`odoo.addons.website_blog.tests.test_ui tested in 10.35s`
A regular expression like this, named `test_duration`:
`odoo.addons.(?P<key>.+) tested in (?P<value>\d+\.\d+)s`
Should store the following key:value:
`{
'key': 'test_duration.website_blog.tests.test_ui',
'value': 10.35
}`
A `generic` boolean field is present on the build.stat.regex object,
meaning that when no regex are linked to a make_stats config step, then,
all the generic regex will be applied.
A wizard is added to help the creation the regular expressions, allowing
to test if they work against a user provided example.
A _make_stats method is added to the ConfigStep model which is called
during the _schedule of a build, just before calling the next step.
The regex search is only apllied in steps that have the `make_stats`
boolean field set to true. Also, the build branch have to be flagged
`make_stats` too or the build can have a key `make_stats` in its
config_data field.
The `make_stats` field on the branch is a compute stored field.
That way, sticky branches are automaticaly set `make_stats' true.
Finally, an SQL view is used to facilitate the stats visualisation.
2020-03-05 23:35:50 +07:00
|
|
|
'version': '4.10',
|
2018-02-28 16:31:05 +07:00
|
|
|
'depends': ['website', 'base'],
|
|
|
|
'data': [
|
|
|
|
'security/runbot_security.xml',
|
|
|
|
'security/ir.model.access.csv',
|
|
|
|
'security/ir.rule.csv',
|
2019-04-22 20:49:33 +07:00
|
|
|
'views/assets.xml',
|
2018-02-28 16:31:05 +07:00
|
|
|
'views/repo_views.xml',
|
|
|
|
'views/branch_views.xml',
|
|
|
|
'views/build_views.xml',
|
[WIP] runbot: monitoring tools
Add a new model runbot.host to keep info and configuration about
hosts (worker servers), like number of worker, reserved or not,
ping times (last start loop, successful iteration, end loop, ...)
and also last errors, number of testing per host, psql connection
count, ...
A new monitoring frontend page is created, similar to glances
but with additionnal information like hosts states and
last_monitored builds (for nightly)
Later this model will be used for runbot_build host instead of char.
Host are automaticaly created when running _scheduler.
2019-08-19 21:03:14 +07:00
|
|
|
'views/host_views.xml',
|
2019-06-27 22:32:00 +07:00
|
|
|
'views/build_error_views.xml',
|
2019-08-28 19:58:17 +07:00
|
|
|
'views/error_log_views.xml',
|
2019-04-22 20:49:33 +07:00
|
|
|
'views/config_views.xml',
|
2018-02-28 16:31:05 +07:00
|
|
|
'views/res_config_settings_views.xml',
|
[IMP] runbot: add a build stat model
When a build is done, various numerical informations could be extracted
from log files. e.g.: global query count or tests query count ...
The extraction regular expression could be hard-coded in a custom step
but there is no place holder where to store the retrieved information.
In order to compare results, we need to store it.
With this commit, a new model `runbot.build.stat` is used to store
key/values pair linked to a build/config_step. That way, extracted
values can be stored.
Also, another `runbot.build.stat.regex` is used to store regular
expressions that can be used to grep log files and extract values.
The regular expression must contain a named group like this:
`(?P<value>.+)`
The text catched by this group MUST be castable into a float.
Optionally, another named group can be used in the regular expresion
like this:
`(?P<key>.+)`
This `key` group will then be used to augment the key name in the
database.
Example:
Consider a log line like this one:
`odoo.addons.website_blog.tests.test_ui tested in 10.35s`
A regular expression like this, named `test_duration`:
`odoo.addons.(?P<key>.+) tested in (?P<value>\d+\.\d+)s`
Should store the following key:value:
`{
'key': 'test_duration.website_blog.tests.test_ui',
'value': 10.35
}`
A `generic` boolean field is present on the build.stat.regex object,
meaning that when no regex are linked to a make_stats config step, then,
all the generic regex will be applied.
A wizard is added to help the creation the regular expressions, allowing
to test if they work against a user provided example.
A _make_stats method is added to the ConfigStep model which is called
during the _schedule of a build, just before calling the next step.
The regex search is only apllied in steps that have the `make_stats`
boolean field set to true. Also, the build branch have to be flagged
`make_stats` too or the build can have a key `make_stats` in its
config_data field.
The `make_stats` field on the branch is a compute stored field.
That way, sticky branches are automaticaly set `make_stats' true.
Finally, an SQL view is used to facilitate the stats visualisation.
2020-03-05 23:35:50 +07:00
|
|
|
'views/stat_views.xml',
|
2019-10-19 18:10:40 +07:00
|
|
|
'wizards/mutli_build_wizard_views.xml',
|
[IMP] runbot: add a build stat model
When a build is done, various numerical informations could be extracted
from log files. e.g.: global query count or tests query count ...
The extraction regular expression could be hard-coded in a custom step
but there is no place holder where to store the retrieved information.
In order to compare results, we need to store it.
With this commit, a new model `runbot.build.stat` is used to store
key/values pair linked to a build/config_step. That way, extracted
values can be stored.
Also, another `runbot.build.stat.regex` is used to store regular
expressions that can be used to grep log files and extract values.
The regular expression must contain a named group like this:
`(?P<value>.+)`
The text catched by this group MUST be castable into a float.
Optionally, another named group can be used in the regular expresion
like this:
`(?P<key>.+)`
This `key` group will then be used to augment the key name in the
database.
Example:
Consider a log line like this one:
`odoo.addons.website_blog.tests.test_ui tested in 10.35s`
A regular expression like this, named `test_duration`:
`odoo.addons.(?P<key>.+) tested in (?P<value>\d+\.\d+)s`
Should store the following key:value:
`{
'key': 'test_duration.website_blog.tests.test_ui',
'value': 10.35
}`
A `generic` boolean field is present on the build.stat.regex object,
meaning that when no regex are linked to a make_stats config step, then,
all the generic regex will be applied.
A wizard is added to help the creation the regular expressions, allowing
to test if they work against a user provided example.
A _make_stats method is added to the ConfigStep model which is called
during the _schedule of a build, just before calling the next step.
The regex search is only apllied in steps that have the `make_stats`
boolean field set to true. Also, the build branch have to be flagged
`make_stats` too or the build can have a key `make_stats` in its
config_data field.
The `make_stats` field on the branch is a compute stored field.
That way, sticky branches are automaticaly set `make_stats' true.
Finally, an SQL view is used to facilitate the stats visualisation.
2020-03-05 23:35:50 +07:00
|
|
|
'wizards/stat_regex_wizard_views.xml',
|
2018-02-28 16:31:05 +07:00
|
|
|
'templates/frontend.xml',
|
|
|
|
'templates/build.xml',
|
|
|
|
'templates/assets.xml',
|
2018-03-13 17:15:39 +07:00
|
|
|
'templates/dashboard.xml',
|
2018-02-28 16:31:05 +07:00
|
|
|
'templates/nginx.xml',
|
2018-03-14 00:14:15 +07:00
|
|
|
'templates/badge.xml',
|
2018-09-21 13:45:30 +07:00
|
|
|
'templates/branch.xml',
|
2019-04-22 20:49:33 +07:00
|
|
|
'data/runbot_build_config_data.xml',
|
2019-06-27 22:32:00 +07:00
|
|
|
'data/build_parse.xml',
|
|
|
|
'data/runbot_error_regex_data.xml',
|
|
|
|
'data/error_link.xml',
|
2020-01-10 17:54:29 +07:00
|
|
|
'data/website_data.xml',
|
2018-02-28 16:31:05 +07:00
|
|
|
],
|
|
|
|
}
|