Commit 7c77b0d3 authored by Holger Levsen's avatar Holger Levsen

reproducible Archlinux ToDo: drop 8000 sql queries

Signed-off-by: Holger Levsen's avatarHolger Levsen <holger@layer-acht.org>
parent 3d46a865
......@@ -332,6 +332,7 @@ See link:https://jenkins.debian.net/userContent/about.html["about jenkins.debian
* use db
** problem: we currently have more (detailed) stati in archlinux
** extend scheduler.sh:
*** stop checking making 8000 queries instead of 1...
*** actually schedule old packages once queue is empty (except blacklisted packages)
*** also delete unknown packages from db: sources and schedule, later results as well
*** check/make sure that packages which are newer in trunk than repo are only scheduled once
......
......@@ -80,6 +80,7 @@ update_archlinux_repositories() {
PKG=$pkgbase
SUITE="archlinux_$repo"
ARCH="x86_64"
# FIXME: doing the next line 8000 times is grossly inefficient and should be replaced by one single query
VERSION=$(query_db "SELECT version FROM sources WHERE name='$PKG' AND suite='$SUITE' AND architecture='$ARCH';" || query_db "SELECT version FROM sources WHERE name='$PKG' AND suite='$SUITE' AND architecture='$ARCH';")
if [ -z "$VERSION" ] ; then
# new package, add to db and schedule
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment