It's been several weeks since I posted v2 (I got distracted by
improving libnbd to better test things, which in turn surfaced some
major memory leak problems in nbdsh that are now fixed). Many of the
patches are minor rebases from v2, with the biggest changes being
fallout from:
- patch 2: rename nbdkit_add_default_export to nbdkit_use_default_export
- overall: this missed 1.22, so update appropriate documentation
- libnbd's 'nbdinfo --list' differs in behavior between 1.4.0 and 1.4.1
regarding descriptions, so fix the tests to work for both versions
- rebased on top of rewriting test-layers to use libnbd
- rebased on top of putting nbdkit_*_intern() in place already
I'm probably at the point where it is just worth committing this
series, and dealing with any further changes as followup patches.
Key:
[----] : patches are identical
[####] : number of functional differences between upstream/downstream patch
[down] : patch is downstream-only
The flags [FC] indicate (F)unctional and (C)ontextual differences, respectively
001/14:[0059] [FC] 'api: Add .default_export'
002/14:[down] 'api: Add nbdkit_use_default_export'
003/14:[0059] [FC] 'server: Respond to NBD_INFO_NAME request'
004/14:[0021] [FC] 'sh, eval: Implement .default_export'
005/14:[0036] [FC] 'api: Alter .list_exports'
006/14:[0032] [FC] 'api: Add .export_description'
007/14:[0015] [FC] 'exportname: New filter'
008/14:[0049] [FC] 'filters: Add .export_description wrappers'
009/14:[0002] [FC] 'ext2: Supply .list_exports and .default_export'
010/14:[----] [--] 'nbd: Implement .default_export, .export_description'
011/14:[0010] [FC] 'nbd: Add dynamic-export=true option'
012/14:[0002] [FC] 'nbd: Implement .list_exports'
013/14:[0019] [FC] 'python: Implement .list_exports and friends'
014/14:[0017] [FC] 'ocaml: Implement .list_exports and friends'
Eric Blake (14):
api: Add .default_export
api: Add nbdkit_use_default_export
server: Respond to NBD_INFO_NAME request
sh, eval: Implement .default_export
api: Alter .list_exports
api: Add .export_description
exportname: New filter
filters: Add .export_description wrappers
ext2: Supply .list_exports and .default_export
nbd: Implement .default_export, .export_description
nbd: Add dynamic-export=true option
nbd: Implement .list_exports
python: Implement .list_exports and friends
ocaml: Implement .list_exports and friends
docs/nbdkit-filter.pod | 65 +++-
docs/nbdkit-plugin.pod | 112 +++++-
docs/nbdkit-protocol.pod | 14 +
.../exportname/nbdkit-exportname-filter.pod | 154 ++++++++
filters/ext2/nbdkit-ext2-filter.pod | 6 +
filters/log/nbdkit-log-filter.pod | 2 +-
plugins/eval/nbdkit-eval-plugin.pod | 6 +
plugins/file/nbdkit-file-plugin.pod | 9 +-
plugins/nbd/nbdkit-nbd-plugin.pod | 30 +-
plugins/python/nbdkit-python-plugin.pod | 25 ++
plugins/sh/nbdkit-sh-plugin.pod | 39 +-
include/nbdkit-common.h | 2 +
include/nbdkit-filter.h | 13 +-
include/nbdkit-plugin.h | 4 +-
configure.ac | 2 +
filters/exportname/Makefile.am | 67 ++++
tests/Makefile.am | 31 +-
server/internal.h | 15 +-
server/backend.c | 93 +++--
server/exports.c | 32 +-
server/filters.c | 31 +-
server/nbdkit.syms | 1 +
server/plugins.c | 33 +-
server/protocol-handshake-newstyle.c | 88 ++++-
server/test-public.c | 9 +-
plugins/ocaml/NBDKit.mli | 9 +
plugins/sh/methods.h | 2 +
plugins/ocaml/NBDKit.ml | 17 +
plugins/ocaml/example.ml | 33 +-
plugins/cc/cc.c | 73 ++--
plugins/eval/eval.c | 70 ++--
plugins/nbd/nbd.c | 250 +++++++++++--
plugins/ocaml/ocaml.c | 92 ++++-
plugins/ondemand/ondemand.c | 11 +-
plugins/python/python.c | 185 ++++++++--
plugins/sh/methods.c | 84 ++++-
plugins/sh/sh.c | 70 ++--
plugins/sh/example.sh | 2 +-
filters/exportname/exportname.c | 342 ++++++++++++++++++
filters/ext2/ext2.c | 122 +++++--
filters/gzip/gzip.c | 37 +-
filters/log/log.c | 8 +-
filters/partition/partition.c | 56 ++-
filters/tar/tar.c | 46 ++-
filters/tls-fallback/tls-fallback.c | 60 ++-
filters/xz/xz.c | 40 +-
tests/test-eval-exports.sh | 41 ++-
tests/test-export-info.sh | 111 ++++++
tests/test-exportname.sh | 193 ++++++++++
tests/test-ext2-exportname.sh | 73 ++++
tests/test-nbd-dynamic-content.sh | 75 ++++
tests/test-nbd-dynamic-list.sh | 162 +++++++++
tests/test-python-export-list.sh | 71 ++++
tests/test-tls-fallback.sh | 53 ++-
tests/python-export-list.py | 59 +++
tests/test-layers-filter.c | 13 +-
tests/test-layers-plugin.c | 8 +
tests/test-layers.c | 12 +
TODO | 20 +-
59 files changed, 2950 insertions(+), 433 deletions(-)
create mode 100644 filters/exportname/nbdkit-exportname-filter.pod
create mode 100644 filters/exportname/Makefile.am
create mode 100644 filters/exportname/exportname.c
create mode 100755 tests/test-export-info.sh
create mode 100755 tests/test-exportname.sh
create mode 100755 tests/test-ext2-exportname.sh
create mode 100755 tests/test-nbd-dynamic-content.sh
create mode 100755 tests/test-nbd-dynamic-list.sh
create mode 100755 tests/test-python-export-list.sh
create mode 100644 tests/python-export-list.py
--
2.28.0