Commit Graph

66 Commits

Author SHA1 Message Date
Sorin Sbarnea b3ce51fe2a Use py3 with elastic-recheck
Depends-On: https://review.opendev.org/#/c/747056/
Change-Id: I90c3784eb8c93616cba1270cd7c5a9babb5c440f
2020-08-20 11:12:22 +00:00
OpenDev Sysadmins 6e2b3aa762 OpenDev Migration Patch
This commit was bulk generated and pushed by the OpenDev sysadmins
as a part of the Git hosting and code review systems migration
detailed in these mailing list posts:

http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003603.html
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004920.html

Attempts have been made to correct repository namespaces and
hostnames based on simple pattern matching, but it's possible some
were updated incorrectly or missed entirely. Please reach out to us
via the contact information listed at https://opendev.org/ with any
questions you may have.
2019-04-19 19:25:38 +00:00
Ian Wienand 5e294a9615 Replace openstack.org git:// URLs with https://
This is a mechanically generated change to replace openstack.org
git:// URLs with https:// equivalents.

This is in aid of a planned future move of the git hosting
infrastructure to a self-hosted instance of gitea (https://gitea.io),
which does not support the git wire protocol at this stage.

This update should result in no functional change.

For more information see the thread at

 http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003825.html

Change-Id: I471298f78d66fc3b224ffc9006364a2e49809998
2019-03-24 20:35:38 +00:00
Clark Boylan 678e461ca7 flock lockfile path comes before the command to lock
When I added the timeout I didn't move the lock file path properly. Fix
this by putting the lock file path before the timeout command to flock.

Change-Id: Iacf8d55f9cfe5b2c92569929bbdadebbe2f8de09
2019-03-20 15:16:49 -07:00
Clark Boylan 014bc3b72e Timeout generation of e-r graphs
Add a four hour timeout to the generation of e-r graphs as these scripts
occasiaonlly run for days without exiting. We'd rather fail then try
again later to ensure the graphs are mostly up to date.

Change-Id: I7ee1c94c41edb9d6b5aeedebac64aeded1cf0e97
2019-03-20 11:32:01 -07:00
Matt Riedemann 9229117aba Update elastic-recheck jobs_re config
With zuul v3 lots of jobs have been renamed and the old "dsvm"
isn't really standard practice anymore, which means elastic recheck
skips processing for lots of failed jobs that would otherwise have
hits, including tempest-full and our grenade jobs.

This updates the regex to include devstack|tempest|grenade at
a minimum and leaves a TODO since there clearly lots of other
voting jobs which have categorized failures but aren't being processed.

Change-Id: I21e3d1058615321f84a00eab9d3dface7418fcc1
2019-01-04 14:52:25 -05:00
Colleen Murphy f0c649ba9d Add beaker tests
Add tests to ensure the elastic_recheck classes work and that the
service can start.

This module hardcodes IRC bot configs, so the tests use resource
overrides to set the bot channels to a test channel that's also used
elsewhere in our tests to avoid spamming our real channels.

In order for the bot to actually be functional it would need to have a
real gerrit account, which we don't have, but this should still be
sufficient as a test.

Change-Id: I6da62d63d885037ecbc1560deec323e0d8583c3c
2018-08-14 00:18:44 +02:00
Colleen Murphy 4b617e0229 Add support for Xenial
Add an exec to trigger a systemd reload so that the existing SysV init
script just works.

Change-Id: Ieb7e701579e74ca62622880ed8ec2b857d98b60a
2018-07-10 16:56:15 +02:00
Colleen Murphy 9b032cffba Update Gemfile for Zuulv3
The logic in the Gemfile was relying on Zuulv2 variables to find out
whether the spec helper gem was already available on disk, and since
Zuulv3 has changed things it was failing to find it and downloading the
master version instead. This patch ensures the Gemfile looks for the gem
in the right place when running in CI.

Change-Id: I520315aefd2983ed95ee9236ddb26b1280aa66b1
2018-07-10 16:56:13 +02:00
Jens Harbott a1f5230d2b Talk about Zuul instead of jenkins
This was already changed in elastic-recheck in [0], so let's also use
this in our running config.

[0] https://review.openstack.org/330684

Change-Id: If9911f1ad2fa45afd6cfde1216f6178e87891028
2018-05-09 11:30:19 +00:00
Colleen Murphy 2261796c78 Depend on helper gem for spec_helper_acceptance
Instead of keeping a local copy of spec_helper_acceptance.rb and
requiring updates to all modules for any change, we can move it into the
common helper gem and require it from there. This will make it easier to
create and review changes that affect all puppet modules. Also change
the Gemfile to look for the gem in the local workspace if running in a
zuul environment.

Change-Id: I6df94c6dbb8b4198765375619aaf828339a6b6a0
2017-08-18 10:41:43 +02:00
Paul Belanger 79c4168c97 Add dsvm|tripleo to jobs_regex
We've been tracking dsvm jobs for a long time, but also start
commenting for tripleo jobs. This is to help better classify job
failures.

Change-Id: I1e2369225c9bd83296684af0dd9ea0514d9098c4
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-08-07 13:57:57 -04:00
Colleen Murphy 923d41d538 Update beaker setup for xenial
Add a xenial nodeset and update the spec helper to install puppet 3 from
the Ubuntu repos instead of from puppetlabs.

Change-Id: I98222aaad48dc6dc9329494f9f14a80c1242fdcd
2017-06-11 21:46:01 +02:00
Paul Belanger e0e038aba4
Add bindep.txt file
Bindep is a tool for checking the presence of binary packages needed
to use an application / library. It started life as a way to make it
easier to set up a development environment for OpenStack projects.

Change-Id: Ife8f5f967a12276466c421df08b00cfbbbf357da
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-05-01 21:07:06 -04:00
Ihar Hrachyshka f43cc3d760 Enable recheck irc bot for neutron
Change-Id: I93057432e4e68e69e4fe047851c875ea2b5d280e
2017-02-15 20:17:42 +00:00
Matthew Treinish ad69a89541
Remove unnecessary rm from uncat cron job
Change-Id: I226238936633580edeebaf5d4df04513133dd3d9
2016-08-24 10:37:40 -04:00
Matthew Treinish 3c4158b66d Add missing -p to mkdir on uncat cron job
Change-Id: I0e061c14b4ba12c8ee2f3895dca9b1b4bc14b1f0
2016-08-24 10:28:28 -04:00
Matthew Treinish c15da7419e Rework uncategorized script to handle multiple html files
In a recent elastic-recheck change we updated the output of the
uncategorized command to split between the integrated gate failues
and everything else. In the future we'll add a configurable views
system where we can construct multiple different groups. The days
of a single uncategorized.html file have disappeared. This commit
adds the necessary support to the cron job so it can handle an
multiple number of html files.

Change-Id: I12690cecd3b5d27fa3e508f7ea4daa43696423b8
2016-08-10 12:34:31 -04:00
Spencer Krum 730b85138a Use new infra_spec_helper for gem dependencies
Change-Id: Idd58921e0575bb61b8cc2f254283842b29fc9ba0
2016-06-21 18:38:03 -07:00
Spencer Krum 822dad5c5c Pin google-api-client; sanitize Gemfile
Change-Id: Ib95b0138725f2ecc940fbd35b3683c789057113b
2016-04-14 15:18:19 -07:00
Andrey Nikitin e615e916d1 Order of the classes parameters is refactored
Order and intendation of those parameters are changed
to follow Puppet Style Guide recommendation [0].
Moreover, it will allow to an user to find much faster
a variable in a list of variables.

[0]. https://docs.puppetlabs.com/guides/style_guide.html

Change-Id: I36851bcdbef1157fbc339834a1cc8dc8344397ce
2016-03-21 11:38:07 +03:00
Jenkins e51b3a583a Merge "Allow configuration of logstash url" 2015-12-24 19:20:03 +00:00
Ramy Asselin 9a3f13c2e7 Allow configuration of logstash url
Elastic recheck commands pull the logstash url
from the provided configuration file. Allow this
url to be set.

Change-Id: I5fd2bc05f1cd6647fa43aaa307c47935c64b5f36
Depends-on: I282745796a40f10955e0c9893e817779b2d4d55a
2015-12-11 16:43:29 -08:00
Sean Dague c9cd39aaac put a 1hr timeout on flock blocking
From time to time the flock calls on the er system back up for an
unknown reason. However, when fixing another bug I found that flock
has a wait timeout. Set this to an hour so that if we fail to flock
after an hour we don't back up forever.

Change-Id: Ie574b994d2b5cc38f559d3d7f8dd980148cf0890
2015-11-17 12:14:32 -05:00
Ramy Asselin 2dd94c3254 Set port to 80 in preparation for pyelasticsearch upgrade
pyelasticseach>=1.0 defaults the port to 9200 if not specified.
Fix it to port 80, so that when pyelasticsearch is upgraded, the
correct port (80) will still be used.

Change-Id: I50107e90449f8d78b70985e6f2b808a951310eb3
2015-10-21 14:19:25 -07:00
Ramy Asselin 1d93e6581d Allow elastic-recheck-uncategorized custom options
Allow custom command line options for the elastic-recheck-uncategorized,
graph_all_cmd, and graph_gate_cmd.

This can include other current or future options e.g. --db_uri --es_url.

Remove these commands from init.pp since they are only used by the cron.pp
class (since Ibf5dad1071f65f8d676e8b9a0ec4331bada9943f).

Change-Id: I4588ea4e40ae643070f8da4954cca984ec6a3d96
2015-10-17 01:04:58 +00:00
Ramy Asselin f8b1c57f9a Allow elastic-recheck daemon args to be specified
For example, allow passing in --noirc or --nocomment.

Change-Id: I90d3e3bf9dfce70b2de379edee4acfbb68f2ec09
2015-10-16 18:29:26 +00:00
Ramy Asselin 4677af4140 Populate the data_source in elastic-recheck.conf
This allows non-default values to be used.

Change-Id: I26b0e1df8618f3285ccdeff3b736443e64bf820c
2015-10-16 18:26:49 +00:00
Ramy Asselin 3111028c67 Make elastic_recheck git source and revision configurable
All others to override the version of elastic_recheck used.

Change-Id: I8572610a6fa7b934834186c51ca01bf4429b3726
2015-10-15 19:17:19 +00:00
Spencer Krum 5e353fa822 Fix target path for regular git clone during tests
Use same target directory for zuul-cloner and
the regular git command.

Change-Id: I898378c03e874b02c7aed698f0a147230e306318
Co-Authored-By: Fabien Boucher <fabien.boucher@enovance.com>
2015-08-19 16:35:08 -07:00
Spencer Krum 843ca0265c Boilerplate beaker-rspec files
Change-Id: I07f98846d405429f93da5c1d91037e9ae04be18b
2015-07-28 02:04:08 -07:00
Colleen Murphy f1b7e20f52 Add Gemfile and puppet 4 checks
In anticipation of puppet 4, start trying to deal with puppet 4 things
that can be helpfully predicted by puppet lint plugins. This patch also
corrects lint errors caught by the puppet-lint-absolute_classname-check
and puppet-lint-empty_string-check gems as well as arrow alignment
which wasn't being caught under the system version of puppet-lint.

Change-Id: I5552777ba63d07039f9b2bed9c4100a44e6a0255
2015-07-21 18:49:54 -07:00
Paul Belanger 937c3d7f49 Fix variable access warnings
Change-Id: Ib18de7f55de01f4764b1c4f318e7846168a4603e
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-07-09 16:36:15 -04:00
Jeremy Stanley c76eaccb33 Replace ci.o.o links with docs.o.o/infra
The http://ci.openstack.org/ documentation site has been deprecated,
replaced by redirects to corresponding paths within
http://docs.openstack.org/infra/ where other Project Infrastructure
documentation already resides.

Change-Id: I5c3f843b3890d66549f08c18537dfd1f42ec6b7c
2015-05-14 21:43:05 +00:00
Ramy Asselin 1097abe4b6 Rename openstackci to openstackinfra
Change-Id: I1bbbc6653e0608385e9fc1ba55c94296bbef8eab
2015-04-20 13:43:28 -07:00
Ramy Asselin 6586ef847c Add puppet module files for elastic_recheck
Change-Id: I2daff99488b00f6d3b316db8016b7871db49f845
2015-01-29 15:14:53 -08:00
Jeremy Stanley c80b87ca5c Workflow documentation is now in infra-manual
Replace URLs for workflow documentation to appropriate parts of the
OpenStack Project Infrastructure Manual.

Change-Id: I8aa32f5617a0331c116a703c45ae7f644f5b409a
2015-01-08 20:31:20 +00:00
Jeremy Stanley 49c28acc8a Stop the elastic-recheck bot more gracefully
* modules/elastic_recheck/files/elastic-recheck.init: It has in the
past been observed that the elastic-recheck IRC/Gerrit-commenting
bot does not always terminate cleanly. Use a retry with escalation
of kill signals in the initscript to help prevent additional old
processes from hanging around when restarts take place.

Change-Id: I9498eeeb935cb609c2c4c099c3552bed337fbe99
2014-10-03 17:23:44 +00:00
Sean Dague 294bd6865d convert to two level recheckwatchbot.yaml
As of I7353af4c3f141d4bd617d6fd388d7957e0586ba8 we'll introduce
the ability to have a 2 layer config which includes the messages
that we'll send back to the user on gerrit outside of the
elastic-recheck code base. This makes it easier to make changes
to the UX consistent with what we want to change with the rest
of the config.

Change-Id: I9208123a4cb3be02c272cd8a6eba460f4130a960
Depends-On: I7353af4c3f141d4bd617d6fd388d7957e0586ba8
2014-07-22 10:50:51 -04:00
Clark Boylan de1b32ff9e Make e-r crons valid puppet
Puppet does not like cron list syntax to be made as a normal string.
Instead you must give puppet cron resources a puppet list that it will
convert to a cron list...

Change-Id: Ia0839be9b7d8ae772065f782adf61f831e75b92e
2014-04-07 11:35:03 -07:00
Clark Boylan f298499744 Run e-r batch jobs twice an hour ten minutes apart
Decrease the time between e-r batch jobs to half an hour between
consecutive runs of the same job to reduce the latency on the updates of
these reports. Offset each of the three batch jobs from each other by
ten minutes. The run times look like this now:

  minute: 0 10 20 30 40 50
  job:    1  2  3  1  2  3

Change-Id: Ic4176b019e6da71e8c1e33ca89f53b6700309a91
2014-03-28 12:56:51 -07:00
James E. Blair 4f24fbee80 Log recheckwatchbot messages
The qualname was wrong for this logger.

Change-Id: Idc20113fcb96af8b979d1b6552155f2a1e8c5c66
2014-03-03 08:08:18 -08:00
Clark Boylan 311f02092a Run fewer es queries with elastic_recheck.
Currently elastic-recheck is hammering the ElasticSearch cluster every
15 minutes, basically bringing everything else to a halt while these
queries are processed. Spread elastic-recheck periodic queries out, run
each once an hour and 20 minutes after the previous set of queries.

Also, remove the auto triggering when files change, instead we wait for
the hour to roll over and give us new data.

Change-Id: Ibf5dad1071f65f8d676e8b9a0ec4331bada9943f
2014-02-10 16:25:24 -08:00
Joe Gordon 639113240c Generate two elastic-recheck-graph json files all, and gate only
We want to display the hits for all queues and for just the gate queue.
A parameter was added to elastic-recheck-graph to support this, and a
second patch updates the web page to give the gate queue only option.
This patch updates the usage of elastic-recheck-gate.

Related elastic-recheck patchs:
 * I9217a2ceedf86ffe04851084df78238384fccd51
 * I23ed8d945c9517221622e1ca215c80539bb07bbd

Change-Id: Iac51aeaf152f50f8b9a064cd249b0920bef824df
2014-02-03 16:25:36 -08:00
Jenkins fe6641c027 Merge "Add projects section to elastic recheck bot yaml" 2014-01-27 20:05:21 +00:00
Sean Dague ae1e2217ba fix template directory for uncategorized page
your results can be dramatically improved by knowing what you are
doing.

Change-Id: Id9228173ea6270c82f98a75f9a0feeb8fb6a988f
2014-01-23 19:00:47 -05:00
Sean Dague a08763eaf7 fix er_run commands
puppet exec doesn't run under a real shell, so running cd doesn't
work because it's not a command. Instead use cwd properly to
actually run these commands.

Also actually call the correct command to generate the uncategorized
jobs page.

Change-Id: I84ed19bbdc16d185316e3967efbd798e06a521d1
2014-01-23 16:36:38 -05:00
Matthew Treinish 0013a700fb Add projects section to elastic recheck bot yaml
The elastic-recheck change: Ic3dd76bad94213c7152c29a99c00ed23a2c01a31
will add a new section to the recheckwatchbot yaml file to specify
which bug targets get reported to which channels. This commit preempts
that change by adding the new section to the -qa channel to preserve
the existing functionality.

Change-Id: I452040883027b260c0480b9d7ac2e2ca476b72b3
2014-01-23 14:52:39 -05:00
Sean Dague ff2b7a4ba9 add in elastic-recheck-unclassified report
this adds the new elastic-recheck-unclassified report, which
generates an html page of all the unclassified gate failures.

it also runs this command, and the elastic-recheck-graph command
not only on cron, but also on updates to the repository. In order
to do this safely, we create a new er_safe_run.sh in /usr/local
that provides a flock front end to ensure we won't race on our
html writes.

Change-Id: I624f2629e2ac19a1394866f73f1aa9ba18e968ce
2014-01-21 18:29:30 -05:00
James E. Blair 342eda2a9d Move elastic-recheck bot to status.o.o
Also, normalize some parameters to the status manifest to make it
more readable (since they follow the same pattern).  And make the
ssh config for elastic-recheck bot match reviewday.

Change-Id: I2417f121e7b3685aab9540504cdd4c6db1754e67
2013-12-31 19:35:47 +00:00