← Back to team overview

launchpad-dev team mailing list archive

Re: Branching Ubuntu, again

 

On 19 April 2010 02:32, Michael Hudson <michael.hudson@xxxxxxxxxxxxx> wrote:
> update branch set next_mirror_time = CURRENT_TIMESTAMP AT TIME ZONE 'UTC'
> where id in (select branch from seriessourcepackagebranch where distroseries
> in (select distroseries.id from distroseries, distribution where
> distroseries.name in ('lucid', 'maverick') and distribution.name = 'ubuntu'
> limit 500))

Fwiw, to scatter the next_mirror_time over the next, say, 5 days you
can do something like:

  UPDATE branch SET next_mirror_time = (
    CURRENT_TIMESTAMP AT TIME ZONE 'UTC' + (
      random() * INTERVAL '5 days'))
  WHERE id ...

We've used this to band-aid checkwatches a few times :-/

Gavin.



References