Skip to content

Commit a27e920

Browse files
authored
Make dump commands read only (#14562)
1 parent 4adb4e5 commit a27e920

File tree

5 files changed

+4
-5
lines changed

5 files changed

+4
-5
lines changed

ydb/public/lib/ydb_cli/commands/ydb_admin.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ class TCommandDatabase : public TClientCommandTree {
3535
};
3636

3737
TCommandDatabaseDump::TCommandDatabaseDump()
38-
: TYdbCommand("dump", {}, "Dump database into local directory")
38+
: TYdbReadOnlyCommand("dump", {}, "Dump database into local directory")
3939
{}
4040

4141
void TCommandDatabaseDump::Config(TConfig& config) {

ydb/public/lib/ydb_cli/commands/ydb_admin.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ class TCommandAdmin : public TClientCommandTree {
1212
virtual void Config(TConfig& config) override;
1313
};
1414

15-
class TCommandDatabaseDump : public TYdbCommand {
15+
class TCommandDatabaseDump : public TYdbReadOnlyCommand {
1616
public:
1717
TCommandDatabaseDump();
1818
void Config(TConfig& config) override;

ydb/public/lib/ydb_cli/commands/ydb_cluster.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ int TCommandClusterBootstrap::Run(TConfig& config) {
4646
}
4747

4848
TCommandClusterDump::TCommandClusterDump()
49-
: TYdbCommand("dump", {}, "Dump cluster into local directory")
49+
: TYdbReadOnlyCommand("dump", {}, "Dump cluster into local directory")
5050
{}
5151

5252
void TCommandClusterDump::Config(TConfig& config) {

ydb/public/lib/ydb_cli/commands/ydb_cluster.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class TCommandClusterBootstrap : public TYdbCommand {
2222
int Run(TConfig& config) override;
2323
};
2424

25-
class TCommandClusterDump : public TYdbCommand {
25+
class TCommandClusterDump : public TYdbReadOnlyCommand {
2626
public:
2727
TCommandClusterDump();
2828
void Config(TConfig& config) override;

ydb/tests/functional/ydb_cli/test_ydb_backup.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1339,7 +1339,6 @@ def create_backup(cls, command, expected_files, additional_args=[]):
13391339
[
13401340
backup_bin(),
13411341
"--verbose",
1342-
"--assume-yes",
13431342
"--endpoint", "grpc://localhost:%d" % cls.cluster.nodes[1].grpc_port,
13441343
]
13451344
+ command

0 commit comments

Comments
 (0)