From nobody Fri Oct 22 05:33:29 2021 X-Original-To: freebsd-git@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id C4B971804601 for ; Fri, 22 Oct 2021 05:33:42 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-ua1-x92e.google.com (mail-ua1-x92e.google.com [IPv6:2607:f8b0:4864:20::92e]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4HbCgn4qWvz4YNj for ; Fri, 22 Oct 2021 05:33:41 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-ua1-x92e.google.com with SMTP id a17so5465038uax.12 for ; Thu, 21 Oct 2021 22:33:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=9fvZxprePrwuzkYLZ3Zr7iicE5A7NAH1OMTsONOfZ0o=; b=PRI0pSfPwZL7ITUrHa2NBYS53FfvWTqeVnTPQHDHth5uQEB/0bOMTMEW4dRnhfGSXa 1Pz7mUD6oV6OZhcJf+0RK82nbBsKtxQG6GnRDKWlL20IkYEG72IseWhBzSiA1x7ZFbrP VpFKiCheUsJX/9EUoxH9RKH37yCj/d7YS8MWMsm0nd1GNI7DYko/t+q327SCoy7FrCq9 xrGCHbqIgNRcvKyBhiUA5TCaJC5WmVmmnWPp6D8iULFMvIjmYQ9izTtKlYq1E81AWGfV KmcK4VMokxbK+RMPQnjYYS2yqTu2qUcsCDfc/1gt5asfGyxZyGsGp3P50yW/MYYqSc8D ZvXg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=9fvZxprePrwuzkYLZ3Zr7iicE5A7NAH1OMTsONOfZ0o=; b=5RnHKUrdA4v6ZfrvkodmB2XPpanOfQ/E0g1WgCgO6dkWZPJrRjsWVnP7grzsTnk9ks fkoSGH8s5iEghcf4S+xFDIphclUkerN5nYb62Jyqpppy03VNWvUNGwVoRGIPwQYasExt KBowGzZ2W6C1oboiuIcjadFKDY42BcovVfFukC6x2wUkicnY66BfsNrublUkfrzKf6SQ hMXeb9YTMIL5fI124aLbT96kXX8bTu3e03eKftCOdXt4pwPAmAdzIhult60LYTsDb/wP rs/UaBNwYX4ZnxAe1FKn65p1P8gNStJDXVxnaPQt1ZN6uU9IRZTBDl3rBWTZTE6h5sH2 1TKw== X-Gm-Message-State: AOAM531/6Lk/oi2G/ufjo3uou59PZjA/wGjy76v5q1mqy1ynj4DGJ1jZ JHqBQzqTynaDk32DXjEiijQDd3rK3HoEc7pu9SmA85MzH5URTA== X-Google-Smtp-Source: ABdhPJxB1iLaTdtyUaGB+p3Zj7assJ0O+aEKB0XHiRslaYrMGKiQ6G50ZVxe6/0+vp/vglpEVfO5fPiBwqockbmBlvg= X-Received: by 2002:a05:6102:5114:: with SMTP id bm20mr12534335vsb.6.1634880820622; Thu, 21 Oct 2021 22:33:40 -0700 (PDT) List-Id: Discussion of git use in the FreeBSD project List-Archive: https://lists.freebsd.org/archives/freebsd-git List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-git@freebsd.org MIME-Version: 1.0 References: In-Reply-To: From: Warner Losh Date: Thu, 21 Oct 2021 23:33:29 -0600 Message-ID: Subject: Re: Subversion Mirror To: freebsd-git Content-Type: multipart/alternative; boundary="00000000000090487505ceea5a75" X-Rspamd-Queue-Id: 4HbCgn4qWvz4YNj X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20210112.gappssmtp.com header.s=20210112 header.b=PRI0pSfP; dmarc=none; spf=none (mx1.freebsd.org: domain of wlosh@bsdimp.com has no SPF policy when checking 2607:f8b0:4864:20::92e) smtp.mailfrom=wlosh@bsdimp.com X-Spamd-Result: default: False [-2.66 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20210112.gappssmtp.com:s=20210112]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-0.67)[-0.672]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-git@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; RCPT_COUNT_ONE(0.00)[1]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20210112.gappssmtp.com:+]; NEURAL_HAM_SHORT(-0.99)[-0.993]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::92e:from]; R_SPF_NA(0.00)[no SPF record]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; MIME_TRACE(0.00)[0:+,1:+,2:~]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; RCVD_TLS_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2] X-ThisMailContainsUnwantedMimeParts: Y --00000000000090487505ceea5a75 Content-Type: text/plain; charset="UTF-8" On Thu, Oct 21, 2021 at 5:19 PM Warner Losh wrote: > Greetings, > > This email documents two recent events with the git -> subversion mirror. > This seems like the best way to document these two issues given their > esoteric nature. > > We stopped mirroring stable/12 about a week ago. The root cause of this > outage was traced to there being an empty commit that was merged. This > caused the git cherry-pick that we do to bring these into the git-svn tree > that we use to publish to subversion to fail. The code has been updated to > handle these commits in the future. In the future, empty commits will > simply be skipped. Kyle did these commits to record a commit/backout pair > had been 'merged' so that they stopped showing up in the tools as merge > candidates. Since this metadata exists only in the git world, dropping them > in the subversion world is fine (we've stopped updating mergeinfo data for > stable/12). > > The second incident was when the BETA1 builds were delayed by 23 hours. > This was due to the creation of the releng/12.3 branch in git. This is our > first new releng branch since we started mirroring to svn and the process > was not documented by the author of the git to subversion script (namely > me). It took me a while to understand why simply creating the branch was > insufficient and to realize the proper path forward. > > The proper sequence of events is to create new releng/12.x branch from the > branch point by hand in subversion. All these things should be done as user > git2svn: > > % svn copy file:///home/svn/base/stable/12@r370949 > file:///home/svn/base/releng/12.3 -m 'Create releng/12.3' > > where r370949 was the point in subversion where releng/12.3 was branched. > There turned out to be a problem with this. In git when you create a branch, you make changes to it, unlike in subversion. So when I did the above copy, it got the branch point correct, but lost the changes that went along with the branch creation. I had to cherry-pick 27c4d9242bf086f2038defcd458bb4b146892add (the first change on the releng/12.3 branch) to make things the same and landed the change. Had I to do it again, I'd have written a script to do the git svn dcommit and the git propset to set the commit's name to gjb. I did the latter too slowly and the repo as mirrored with git2svn as the author name, so I changed it back. subversion is terrible about fixing bad metadata once it gets mirrored, so this is the lessor of the various evils. Warner > Once this branch was created, the 'git-svn' pump needed to be primed. The > releng123 branch needed to be added to ~git2svn/git2svn.conf file (and but > not to the list of branches= yet): > > # releng/12.3 config > releng123_name="releng/12.3" > releng123_path=/home/git/freebsd-src-releng-12.3 > > Once that was done, we needed to initialize the git2svn tree that lives on > git2svn.freebsd.org, as the user git2svn: > > % ./gsm2 -b releng123 branch-init > > which will create the necessary git-svn tree for the crontab's 'gsm2 > mirror' command to work. Once the branch has been initialized, releng123 > should be added to the branches= so that commits start to flow. > > These issues have been corrected, so the git -> svn mirror hopefully will > go back to being a background process that just works. One could argue this > should be automated. I've chosen not to automated it because it's a lot > more effort to do that than to document the process should we have a > 12.4-RELEASE in the future (and its associated releng/12.4). > > Finally, we're still mirroring the 11.x branches. This will stop at some > point in the future, though, most likely the next time the mirroring of > 11.x breaks :). > > Warner > --00000000000090487505ceea5a75--