Skip to content

Commit 48a468f

Browse files
committed
Move {ShowCreateDatabse,UndropDatabase}
Signed-off-by: Xuanwo <github@xuanwo.io>
1 parent f2dd9d7 commit 48a468f

File tree

8 files changed

+14
-13
lines changed

8 files changed

+14
-13
lines changed

src/query/legacy-planners/src/lib.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@
1515
mod plan_aggregator_final;
1616
mod plan_aggregator_partial;
1717
mod plan_broadcast;
18-
mod plan_database_show_create;
19-
mod plan_database_undrop;
2018
mod plan_delete;
2119
mod plan_empty;
2220
mod plan_explain;
@@ -106,8 +104,6 @@ mod plan_window_func;
106104
pub use plan_aggregator_final::AggregatorFinalPlan;
107105
pub use plan_aggregator_partial::AggregatorPartialPlan;
108106
pub use plan_broadcast::BroadcastPlan;
109-
pub use plan_database_show_create::ShowCreateDatabasePlan;
110-
pub use plan_database_undrop::UndropDatabasePlan;
111107
pub use plan_delete::DeletePlan;
112108
pub use plan_empty::EmptyPlan;
113109
pub use plan_explain::ExplainPlan;

src/query/planner/src/plans/mod.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,9 @@ pub use drop_database::DropDatabasePlan;
2424
mod rename_database;
2525
pub use rename_database::RenameDatabaseEntity;
2626
pub use rename_database::RenameDatabasePlan;
27+
28+
mod show_create_database;
29+
pub use show_create_database::ShowCreateDatabasePlan;
30+
31+
mod undrop_database;
32+
pub use undrop_database::UndropDatabasePlan;

src/query/legacy-planners/src/plan_database_show_create.rs renamed to src/query/planner/src/plans/show_create_database.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2021 Datafuse Labs.
1+
// Copyright 2022 Datafuse Labs.
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

src/query/legacy-planners/src/plan_database_undrop.rs renamed to src/query/planner/src/plans/undrop_database.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2021 Datafuse Labs.
1+
// Copyright 2022 Datafuse Labs.
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.
@@ -11,7 +11,6 @@
1111
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1212
// See the License for the specific language governing permissions and
1313
// limitations under the License.
14-
1514
use std::sync::Arc;
1615

1716
use common_datavalues::DataSchema;

src/query/service/src/interpreters/interpreter_database_show_create.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ use std::sync::Arc;
1818
use common_datablocks::DataBlock;
1919
use common_datavalues::prelude::*;
2020
use common_exception::Result;
21-
use common_legacy_planners::ShowCreateDatabasePlan;
21+
use common_planner::plans::ShowCreateDatabasePlan;
2222

2323
use crate::interpreters::Interpreter;
2424
use crate::pipelines::PipelineBuildResult;

src/query/service/src/interpreters/interpreter_database_undrop.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
use std::sync::Arc;
1616

1717
use common_exception::Result;
18-
use common_legacy_planners::UndropDatabasePlan;
18+
use common_planner::plans::UndropDatabasePlan;
1919

2020
use crate::interpreters::Interpreter;
2121
use crate::pipelines::PipelineBuildResult;

src/query/service/src/sql/planner/binder/ddl/database.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,14 @@ use common_datavalues::DataSchemaRefExt;
3030
use common_datavalues::ToDataType;
3131
use common_datavalues::Vu8;
3232
use common_exception::Result;
33-
use common_legacy_planners::ShowCreateDatabasePlan;
34-
use common_legacy_planners::UndropDatabasePlan;
3533
use common_meta_app::schema::DatabaseMeta;
3634
use common_meta_app::share::ShareNameIdent;
3735
use common_planner::plans::CreateDatabasePlan;
3836
use common_planner::plans::DropDatabasePlan;
3937
use common_planner::plans::RenameDatabaseEntity;
4038
use common_planner::plans::RenameDatabasePlan;
39+
use common_planner::plans::ShowCreateDatabasePlan;
40+
use common_planner::plans::UndropDatabasePlan;
4141

4242
use crate::sql::binder::Binder;
4343
use crate::sql::planner::semantic::normalize_identifier;

src/query/service/src/sql/planner/plans/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,17 +74,17 @@ use common_legacy_planners::RenameTablePlan;
7474
use common_legacy_planners::RevokePrivilegePlan;
7575
use common_legacy_planners::RevokeRolePlan;
7676
use common_legacy_planners::SettingPlan;
77-
use common_legacy_planners::ShowCreateDatabasePlan;
7877
use common_legacy_planners::ShowCreateTablePlan;
7978
use common_legacy_planners::ShowGrantsPlan;
8079
use common_legacy_planners::TruncateTablePlan;
81-
use common_legacy_planners::UndropDatabasePlan;
8280
use common_legacy_planners::UndropTablePlan;
8381
use common_legacy_planners::UseDatabasePlan;
8482
use common_planner::plans::CallPlan;
8583
use common_planner::plans::CreateDatabasePlan;
8684
use common_planner::plans::DropDatabasePlan;
8785
use common_planner::plans::RenameDatabasePlan;
86+
use common_planner::plans::ShowCreateDatabasePlan;
87+
use common_planner::plans::UndropDatabasePlan;
8888
use common_planner::MetadataRef;
8989
pub use copy_v2::CopyPlanV2;
9090
pub use copy_v2::ValidationMode;

0 commit comments

Comments
 (0)