From 5ba392f9ae1c61ce0648400cd403794cbe0a6676 Mon Sep 17 00:00:00 2001 From: Iustin Pop <iustin@google.com> Date: Fri, 22 Feb 2013 13:18:45 +0100 Subject: [PATCH] Enable split queries for export in CLI Rapi doesn't seem to export backup lists, so we enable the split query only in gnt-backup. Signed-off-by: Iustin Pop <iustin@google.com> Reviewed-by: Michael Hanselmann <hansmi@google.com> --- lib/client/gnt_backup.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/client/gnt_backup.py b/lib/client/gnt_backup.py index edc8b4400..4a1859385 100644 --- a/lib/client/gnt_backup.py +++ b/lib/client/gnt_backup.py @@ -1,7 +1,7 @@ # # -# Copyright (C) 2006, 2007, 2010, 2011 Google Inc. +# Copyright (C) 2006, 2007, 2010, 2011, 2013 Google Inc. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -50,9 +50,11 @@ def PrintExportList(opts, args): qfilter = qlang.MakeSimpleFilter("node", opts.nodes) + cl = GetClient(query=True) + return GenericList(constants.QR_EXPORT, selected_fields, None, opts.units, opts.separator, not opts.no_headers, - verbose=opts.verbose, qfilter=qfilter) + verbose=opts.verbose, qfilter=qfilter, cl=cl) def ListExportFields(opts, args): @@ -65,8 +67,10 @@ def ListExportFields(opts, args): @return: the desired exit code """ + cl = GetClient(query=True) + return GenericListFields(constants.QR_EXPORT, args, opts.separator, - not opts.no_headers) + not opts.no_headers, cl=cl) def ExportInstance(opts, args): -- GitLab