mprahl
02e11b9b39
Don't try to untag stale module builds that don't have any completed components
2017-11-20 10:38:56 -05:00
mprahl
ef5dc64f2b
Transition stale failed builds to the "garbage" state and untag their components
2017-11-17 12:07:51 -05:00
mprahl
fa6f43e748
Fail module builds directly when a component build in a batch fails
2017-11-17 10:44:15 -05:00
Ralph Bean
8431d2698b
Explicit imports of builders in the test suite.
2017-11-10 16:03:14 -05:00
mprahl
bb0dde9936
Only complete the module build when *all components are tagged* and a KojiRepoRegen message is received
2017-11-10 08:33:53 -05:00
Ralph Bean
f369182d72
Merge #771 Make the module build log name configurable
2017-11-08 16:12:14 +00:00
Jakub Kadlcik
f098e6e3b7
Make the module build log name configurable
2017-11-07 00:04:14 +01:00
mprahl
11e39ab0c3
Fix multiple transitions to the failed state
2017-11-06 16:46:57 -05:00
mprahl
d8f126e978
Allow resuming from a failure during the "init" phase
...
This also shifts build failure transitions from individual functions
in utils.py to the init module handler.
2017-11-06 14:15:12 -05:00
mprahl
c7e6fff1d8
Handle module builds without components
2017-10-31 14:47:26 -04:00
Jan Kaluža
a7ab1249da
Merge #736 Do not get buildroot_groups everytime we create KojiModuleBuilder.
2017-10-26 19:20:08 +00:00
Jan Kaluza
b56f56a486
Use dogpile.cache to cache the default_buildroot_groups result
2017-10-26 14:03:23 +02:00
Jan Kaluza
8fedf35b6c
Log the original exception in consumer before trying to do anything else. Also commit the db.session before doing build.transition
2017-10-26 13:26:43 +02:00
Martin Curlej
60b3d97c97
flake8 cleanup
...
Signed-off-by: Martin Curlej <mcurlej@redhat.com >
removed some noqa tags
2017-10-25 12:13:59 +02:00
mprahl
a9bf4e9727
Add a sleep in the init handler to protect against a race condition
2017-10-16 14:45:04 -04:00
mprahl
6e8d103a0c
Remove unneeded build transition
2017-10-16 14:45:04 -04:00
Jakub Kadlcik
e6a23cfd64
Record components through the backend after module submission
2017-10-16 14:45:04 -04:00
Ralph Bean
7d9edc8f92
Merge #719 Scan for modules stuck in the wait state.
2017-09-29 20:20:42 +00:00
Ralph Bean
6150000d1e
Scan for modules stuck in the wait state.
...
And fake a message to get them building again.
But only if they look to have been stuck for more than 10 minutes.
2017-09-29 14:13:58 -04:00
Ralph Bean
8e27fe16fe
Raise a special exception for special messages.
...
Today, we ignore koji messages with a None `task_id` in two ways. First
with a conditional, and then with a second check in the message
`__init__` method. This is a belt-and-suspenders approach.
For other reasons in the UMB messaging plugin, we'd like to put this
check in just one place and use a special exception in the initializer
instead of in a conditional beforehand.
2017-09-29 13:07:06 -04:00
Ralph Bean
f2fb71ccdf
Fix NameError.
...
Here, `task_id` was referenced before it was defined.
This fixes that error and adds a little more color to the log statement.
2017-09-26 14:44:18 -04:00
Jan Kaluza
ad6874b0e6
Fix #670 - Tag Content Generator Koji build to special tag based on the base module stream
2017-09-25 08:36:29 +02:00
Ralph Bean
4d393b9e73
Handle python3 queue rename.
2017-09-19 13:21:29 -04:00
Ralph Bean
5e08d2ffe4
Introduce pluggable backends.
...
This allows an operator to write a custom messaging backend to handle
whatever transport and format.
2017-09-19 13:13:40 -04:00
Mike Bonnet
1f077a12ea
pass the entire message to get_abstracted_msg()
...
Other messaging backends may use different formats, so pass the
entire message through and let get_abstracted_msg() handle it.
2017-09-19 13:12:45 -04:00
Jan Kaluza
999baa2992
Wait for components to be tagged also in final tag before marking module as done.
2017-09-15 15:25:29 +02:00
Filip Valder
3cb41aa5dc
Changes in MBS restful API:
...
- Refactor MBS API code
- Unify module-/component_build API philosophy/design/approach
- Naming fixes
- _utc_datetime_to_iso moved from ModuleBuildAPI and is now a module-level function.
- Existing v1 API remains unchanged. ComponentBuildAPI now supports individual component build listing + verbose mode.
- documented in README
- various component_build API tests added
2017-09-11 14:48:22 +02:00
Jan Kaluza
83628ec74f
Add 'requires' of 'build-required' modules to buildroot when building module.
2017-09-08 09:25:44 +02:00
Jan Kaluza
dfdd924bbf
Always regen repository when starting module build to not wait on kojira.
2017-08-18 09:39:07 +02:00
Jan Kaluza
aac4227eb8
Add 'mbs-build local [[--add-local-build n:s:v], ...]' to use local builds as dependency.
2017-08-17 10:00:19 +02:00
Filip Valder
41f5472021
Merge #631 Do not rebuild the -build tag repository for last batch.
2017-08-09 00:40:05 +00:00
Jan Kaluza
4bbb0cc416
Create module-build-macros component just once - do not duplicate it for each resubmition of a module.
2017-08-08 06:52:28 +02:00
Jan Kaluza
15523ac90e
Fix the bug when module build stuck in the 'build' state even with failed component builds.
2017-08-07 15:47:06 +02:00
Jan Kaluza
27d249fe17
Do not rebuild the -build tag repository for last batch.
2017-08-07 15:46:38 +02:00
Filip Valder
7ef2975984
PEP8 fixes
2017-07-17 18:29:10 +02:00
Jan Kaluza
439767cbcf
Tag the component to final tag in case it is built, but not tagged.
2017-07-13 13:37:10 -04:00
Ralph Bean
a755104bd4
Fix the test suite.
...
We had some circular imports that caused the tests (and more?) to fail.
I ran into this when looking at the tests for #583 and #595 .
2017-07-06 21:02:32 -04:00
Jan Kaluza
93092a43be
Add per-module-build logging feature
2017-06-30 16:30:47 +02:00
Jan Kaluza
a07b44411c
Set the state_reason when format_mmd raises in frontend and do not overwrite the state_reason in backend.
2017-06-06 14:49:49 +02:00
Stanislav Ochotnicky
b33beb0cef
Enable koji content generator code
...
If the koji_enable_content_generator is configured to True koji instance
has to be configured as follows:
koji call addBType module
koji grant-cg-access <mbs-user> module-build-service --new
Without the above configuration MBS will start failing the builds
2017-05-31 14:48:34 +02:00
Jan Kaluza
f27b0ddb81
Regenerate the repo when module-build-macros is reused to ensure it is in the buildroot.
2017-05-24 14:26:08 +02:00
Jan Kaluža
7d024e17c3
Merge #564 Fix fedmsg issue on Copr
2017-05-22 19:43:26 +00:00
Jakub Kadlčík
4992d97937
Remove leftovers from incomplete copr fedmsg implementation
2017-05-22 18:07:54 +02:00
Jan Kaluza
a819f51549
Change module build state to 'build' even if we reuse all the components, so we handle the buildsys.tag message.
2017-05-22 13:54:08 +02:00
Jan Kaluža
4593ee5d95
Merge #526 Do not tag built components if there is any failed one.
2017-05-17 09:48:05 +00:00
Jan Kaluza
7d7a45f997
Do not tag built components if there is any failed one.
2017-05-12 10:39:48 +02:00
Jan Kaluza
22758419c0
Delete build target after config.koji_target_delete_time seconds.
2017-05-11 14:43:05 +02:00
Jan Kaluza
024877592c
Do not build module-build-macros when all the components will be reused from previous module build.
2017-05-02 12:09:23 +02:00
Matt Prahl
dd72504395
Merge #509 Pass the whole ModuleBuild object to the builder
2017-04-13 15:54:18 +00:00
Jakub Kadlčík
b78b0346d2
Pass the module build into builder
2017-04-12 23:53:55 +02:00