look process-new with an own lockfile.
This wont make a difference for dinstall, same lock time there.
But it will make a big difference whenever cron.unchecked runs (which is far
more often), as it now will lock for a few seconds and not for the
sometimes unbearable long times process-unchecked and the w-b trigger
needs.
Signed-off-by: Joerg Jaspert <joerg@debian.org>
# lock cron.unchecked (it immediately exits when this exists)
LOCK_DAILY="$lockdir/daily.lock"
-# Lock process-new and cron.unchecked from doing work
+# Lock cron.unchecked from doing work
LOCK_ACCEPTED="$lockdir/unchecked.lock"
+# Lock process-new from doing work
+LOCK_NEW="$lockdir/processnew.lock"
+
# This file is simply used to indicate to britney whether or not
# the Packages file updates completed sucessfully. It's not a lock
# from our point of view
stage $GO
lockfile "$LOCK_ACCEPTED"
+lockfile "$LOCK_NEW"
GO=(
FUNC="process_unchecked"
stage $GO
rm -f "$LOCK_ACCEPTED"
+rm -f "$LOCK_NEW"
GO=(
FUNC="msfl"
LOCKDAILY=""
LOCKFILE="$lockdir/unchecked.lock"
+LOCK_NEW="$lockdir/processnew.lock"
NOTICE="$lockdir/daily.lock"
if [ -e $NOTICE ]; then
# the actual unchecked functions follow #
########################################################################
+lockfile "$LOCK_NEW"
acceptnew
+rm -f "$LOCK_NEW"
# only run one cron.unchecked
lockfile -r3 $LOCKFILE || exit 0
Process-New
{
- DinstallLockFile "/srv/ftp.debian.org/lock/unchecked.lock";
+ DinstallLockFile "/srv/ftp.debian.org/lock/processnew.lock";
LockDir "/srv/ftp.debian.org/lock/new/";
};