From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on sa.local.altlinux.org X-Spam-Level: X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=v8ggHTmfMPGvuXziO3yDxhuNSwn/XLMZdSJ7bEQ2+tA=; b=pi9kxH2u3SRUwCQhXVygTtSjUgwHs8SwHM48QioLu6vHCfeDz/t71y6JBxjxBTEWX/ mP6h9E1xeBzotSL1de4gYAbrRO8KGJMJkaYkLElaWxiyBhppnTz8ow1MbRWbgjN9Ei10 lo6W6ufC2/y/X/KZIRwLQmG2Xy+O/5AYcP+xDmlo4RhrATODtk4zjL9u2Bz/kmxe9wr+ pZYdZ9kdk3uFfNqnDjGTh3jEtR1xyziYe1wX02+GRB2HFxvpNkwAM3Xml5GqfHuR91Ra fgWkV0WYJ4gCi6VURxUAQr/suIJL9K2q+YSAps9N2h1RyoWdBsJjNekAJueh+s4Ey7IC I7Aw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=v8ggHTmfMPGvuXziO3yDxhuNSwn/XLMZdSJ7bEQ2+tA=; b=SHxiencFKmBsOU1f+nIx1L/wsWvnh2jbqz6vatfTyGLTwJAATzn9XQP2rZzsSwuHX3 fB3waFEl2Sotn+/0WnqM8jz6BS4g9xr6gk8BGbBwKWYs/ocAkiJzeLcExVS3N/01AZiV bnWyPKXywf/HHHSikI+B+G3vQQFW19UoSt2eJzLUZT9P2Dnw17I6SGkophBOq2y8NPF/ jjLzMNtkYxpXk38OqslsQrzALIg5gI24Bl3y3tUq5ypDS9M1iVwnGRHGnIH6oa3a7fAG mNYuv1lmS6JXcWOdohJDaT0PR9MDTxDjvqpRya1Mg96Sg2KEcQc6p7k0FU7qIrRljOiY ae1w== X-Gm-Message-State: AGi0PuY5cLzSZ2YxVY3JQMfkmL9yixPP4RhG+uhLFolntVOiuYtC9NN7 E54g228TBsU9wgvWtVA04QKPg7UrWd3wij1xVdJw1A== X-Google-Smtp-Source: APiQypLsT8ja6g2z7XjMRy0o9I/kxdTUxfU+SVWvfgrxyBtEQdxY7EgvDfH2PoPdYbntIqATC1tOLVdIipY75x4yfY0= X-Received: by 2002:a6b:8e8b:: with SMTP id q133mr4149788iod.76.1587373537605; Mon, 20 Apr 2020 02:05:37 -0700 (PDT) MIME-Version: 1.0 References: <20200410231044.1436970-1-vseleznv@altlinux.org> <20200410231044.1436970-3-vseleznv@altlinux.org> <20200414164244.GC618226@portlab> <20200417135419.GA24862@altlinux.org> In-Reply-To: <20200417135419.GA24862@altlinux.org> From: Alexey Tourbin Date: Mon, 20 Apr 2020 12:05:26 +0300 Message-ID: To: ALT Linux Team development discussions Content-Type: text/plain; charset="UTF-8" Subject: [devel] stopping a cascade of rebuilds X-BeenThere: devel@lists.altlinux.org X-Mailman-Version: 2.1.12 Precedence: list Reply-To: ALT Linux Team development discussions List-Id: ALT Linux Team development discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 20 Apr 2020 09:05:43 -0000 Archived-At: List-Archive: List-Post: On Fri, Apr 17, 2020 at 4:54 PM Dmitry V. Levin wrote: > > So what's the right set of tags for a binary package, and what is its > > identity? (I'm not sure identity is the right word, I would rather > > call it ID. Identity is who you are and what you believe in, for > > example a black person who votes for Obama.) I've already hinted that > > identity can be defined via substitution: if you replace a package > > with a different package but the same identity, there should be no > > functional difference, and furthermore no difference "for all intents > > and purposes", except for a few observable differences which we deem > > immaterial and permit explicitly, such as FileMtimes. So obviously you > > need to hash at least FileDigests and > > Requires/Provides/Obsoletes/Conflicts. This should satisfy the > > definition of ID for rpm (the dependencies are satisfied in the same > > way, and file conflicts are the resolved in the same way, so rpm can't > > tell the difference if we make a substitution.) > > What about various types of scripts? > > $ rpmquery --querytags | grep 'PROG$' > PREINPROG > POSTINPROG > PREUNPROG > POSTUNPROG > VERIFYSCRIPTPROG > TRIGGERSCRIPTPROG Sure, slipped my mind. These IDs can have another application. Suppose a task is resumed, and subtask #100 needs a rebuild. It is likely that, after the rebuild, the result won't change (all subpackage end up with the same IDs). However, we replace the packages anyway. This will trigger the rebuild of subtask #200, if it depends on subtrask #100. There are two approaches to spare the unnecessary rebuild: 1) Don't overwrite local files with those from the remote build, if they are identical. 2) When tracking the contents of BuildRoot, take into account IDs instead of HeaderSHA1. There is a peculiarity with the first approach: if subtask #100 has both arch and noarch subpackages, the decision to overwrite files cannot be made locally / per architecture. If you need to overwrite subpackages for at least one architecture, then you have to overwrite for all architectures, otherwise there will be unmet dependencies between arch and noarch subpackages. I think we already have this problem: the decision to rebuild a subtask is made locally (or rather remotely), per architecture. So occasionally we've seen unmet dependencies due to disttag mismatch. Has the problem been addressed?