[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: API to get revision size on disk

From: Evgeny Kotkov <evgeny.kotkov_at_visualsvn.com>
Date: Tue, 9 Apr 2019 20:02:09 +0300

Julian Foad <julianfoad_at_apache.org> writes:

> Similar consideration applies to the API. I think this could be a libsvn_fs
> API rather than only in libsvn_fs_fs. Agreed?

Maybe, as an alternative to abstracting and promoting this to a public FS API,
we could add a way of performing backend-specific I/O operations through an
API like svn_fs_ioctl()?

See the attached patch that implements it for existing fsfs stats, dump index
and load index operations, and, as I suppose, may also be extended for the
"get revision size/stats" operation.

This concept and the patch serve two purposes:

- They allow us to properly expose FS-specific details and invoke FS-specific
  operations everywhere without necessarily promoting them into a proper public
  API (the ioctl code itself may be made either public or private, depending on
  the requirements).

- They solve an potential dependency/linking problem where tools like `svnfsfs`
  work through the libsvn_fs's loader, but also have to load and call private
  APIs from libsvn_fs_fs thus ignoring the loader. The latter part may
  potentially cause issues with the global shared state, etc. With the
  patch, all such operations always go through the FS loader.

Regards,
Evgeny Kotkov

Received on 2019-04-09 19:09:11 CEST

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.