public inbox for gentoo-portage-dev@lists.gentoo.org
 help / color / mirror / Atom feed
Search results ordered by [date|relevance]  view[summary|nested|Atom feed]
thread overview below | download: 
* [gentoo-portage-dev] [PATCH 0/4] Add sync-rcu support for rsync (bug 662070)
@ 2018-08-06  7:40 99% Zac Medico
  0 siblings, 0 replies; 1+ results
From: Zac Medico @ 2018-08-06  7:40 UTC (permalink / raw
  To: gentoo-portage-dev; +Cc: Zac Medico

Add a boolean sync-rcu repos.conf setting that behaves as follows:

sync-rcu = yes|no

    Enable read-copy-update (RCU) behavior for sync operations. The
    current latest immutable version of a repository will be referenced
    by a symlink found where the repository would normally be located
    (see the location setting). Repository consumers should resolve
    the cannonical path of this symlink before attempt to access
    the repository, and all operations should be read-only, since
    the repository is considered immutable. Updates occur by atomic
    replacement of the symlink, which causes new consumers to use the
    new immutable version, while any earlier consumers continue to
    use the cannonical path that was resolved earlier. This option
    requires sync-allow-hardlinks and sync-rcu-store-dir options to
    be enabled, and currently also requires that sync-type is set
    to rsync. This option is disabled by default, since the symlink
    usage would require special handling for scenarios involving bind
    mounts and chroots.

sync-rcu-store-dir

    Directory path reserved for sync-rcu storage. This directory must
    have a unique value for each repository (do not set it in the
    DEFAULT section).  This directory must not contain any other files
    or directories aside from those that are created automatically
    when sync-rcu is enabled.

sync-rcu-spare-snapshots = 1

    Number of spare snapshots for sync-rcu to retain with expired
    ttl. This protects the previous latest snapshot from being removed
    immediately after a new version becomes available, since it might
    still be used by running processes.

sync-rcu-ttl-days = 7

    Number of days for sync-rcu to retain previous immutable snapshots
    of a repository. After the ttl of a particular snapshot has
    expired, it will be remove automatically (the latest snapshot
    is exempt, and sync-rcu-spare-snapshots configures the number of
    previous snapshots that are exempt). If the ttl is set too low,
    then a snapshot could expire while it is in use by a running
    process.

Zac Medico (4):
  Implement asyncio.iscoroutinefunction for compat_coroutine
  Add _sync_decorator module
  rsync: split out repo storage framework
  Add sync-rcu support for rsync (bug 662070)

 lib/portage/repository/config.py                   |  36 ++-
 lib/portage/repository/storage/__init__.py         |   0
 .../repository/storage/hardlink_quarantine.py      |  95 ++++++++
 lib/portage/repository/storage/hardlink_rcu.py     | 251 +++++++++++++++++++++
 lib/portage/repository/storage/inplace.py          |  49 ++++
 lib/portage/repository/storage/interface.py        |  87 +++++++
 lib/portage/sync/controller.py                     |   1 +
 lib/portage/sync/modules/rsync/rsync.py            |  85 ++-----
 lib/portage/sync/syncbase.py                       |  33 +++
 .../tests/util/futures/test_compat_coroutine.py    |  14 ++
 lib/portage/util/futures/_asyncio/__init__.py      |  14 ++
 lib/portage/util/futures/_sync_decorator.py        |  54 +++++
 lib/portage/util/futures/compat_coroutine.py       |  12 +
 man/portage.5                                      |  35 +++
 14 files changed, 700 insertions(+), 66 deletions(-)
 create mode 100644 lib/portage/repository/storage/__init__.py
 create mode 100644 lib/portage/repository/storage/hardlink_quarantine.py
 create mode 100644 lib/portage/repository/storage/hardlink_rcu.py
 create mode 100644 lib/portage/repository/storage/inplace.py
 create mode 100644 lib/portage/repository/storage/interface.py
 create mode 100644 lib/portage/util/futures/_sync_decorator.py

-- 
2.16.4



^ permalink raw reply	[relevance 99%]

Results 1-1 of 1 | reverse | options above
-- pct% links below jump to the message on this page, permalinks otherwise --
2018-08-06  7:40 99% [gentoo-portage-dev] [PATCH 0/4] Add sync-rcu support for rsync (bug 662070) Zac Medico

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox