Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[YSQL] Allowing drop table which is under replication #12003

Closed
Arjun-yb opened this issue Apr 6, 2022 · 0 comments
Closed

[YSQL] Allowing drop table which is under replication #12003

Arjun-yb opened this issue Apr 6, 2022 · 0 comments
Assignees
Labels
area/ysql Yugabyte SQL (YSQL) kind/bug This issue is a bug priority/medium Medium priority issue xCluster Label for xCluster related issues/improvements

Comments

@Arjun-yb
Copy link
Contributor

Arjun-yb commented Apr 6, 2022

Jira Link: DB-854

Description

Validated in 2.13.2.0-b3 and 2.8.5.0-b2

Steps:

  1. Create tables in source and target
  2. Create xcluster replication
  3. Delete table at source side
  4. Observe the behaviour

Actual:
For indexes


yugabyte=# drop index idx1;
WARNING:  Not implemented: Cannot delete a table in replication.: table { table_id: "000033e1000030008000000000004005" } is_index_table: true
DROP INDEX

For tables


yugabyte=# drop table t1;
WARNING:  Not implemented: Cannot delete a table in replication.: table { table_id: "000033e1000030008000000000004000" } is_index_table: false
DROP TABLE

Table is not present if user executes \d in YSQLSH
And user can see the table in Platform UI

Expected:
Deleting table which is under replication should not allow to delete table.

Note: YCQL is working fine, observed this issue at YSQL

@Arjun-yb Arjun-yb added area/ysql Yugabyte SQL (YSQL) status/awaiting-triage Issue awaiting triage labels Apr 6, 2022
@Arjun-yb Arjun-yb added the xCluster Label for xCluster related issues/improvements label Apr 6, 2022
@yugabyte-ci yugabyte-ci added kind/bug This issue is a bug priority/medium Medium priority issue labels Jun 8, 2022
@yugabyte-ci yugabyte-ci removed the status/awaiting-triage Issue awaiting triage label Jun 24, 2022
hulien22 added a commit that referenced this issue Jul 20, 2022
Summary:
Currently dropping YSQL tables under replication leads to a message saying that the table cannot be
dropped followed by the table being dropped only at the YSQL layer. This leads to some confusing
behaviour where the table can't be accessed via ysqlsh, but can be seen in admin UIs.

The plan to properly fix this is being worked on in gh issue #753, but for now, re-enabling the
deletion of YSQL tables under replication, while still blocking YCQL table deletion.

Test Plan:
```
ybd --cxx-test integration-tests_twodc_ysql-test --gtest_filter "*DeleteTableChecks*"
ybd --cxx-test integration-tests_twodc-test --gtest_filter "*DeleteTableChecks*"
```

Reviewers: rahuldesirazu, slingam, nicolas

Reviewed By: nicolas

Subscribers: ybase, bogdan

Differential Revision: https://phabricator.dev.yugabyte.com/D18225
hulien22 added a commit that referenced this issue Aug 19, 2022
… replication

Summary:
Currently dropping YSQL tables under replication leads to a message saying that the table cannot be
dropped followed by the table being dropped only at the YSQL layer. This leads to some confusing
behaviour where the table can't be accessed via ysqlsh, but can be seen in admin UIs.

The plan to properly fix this is being worked on in gh issue #753, but for now, re-enabling the
deletion of YSQL tables under replication, while still blocking YCQL table deletion.

Original commit: 48e8e32 / D18225

Test Plan:
```
ybd --cxx-test integration-tests_twodc_ysql-test --gtest_filter "*DeleteTableChecks*"
ybd --cxx-test integration-tests_twodc-test --gtest_filter "*DeleteTableChecks*"
```

Reviewers: rahuldesirazu, nicolas, slingam

Reviewed By: slingam

Subscribers: bogdan, ybase

Differential Revision: https://phabricator.dev.yugabyte.com/D18472
hulien22 added a commit that referenced this issue Aug 22, 2022
…r replication

Summary:
Currently dropping YSQL tables under replication leads to a message saying that the table cannot be
dropped followed by the table being dropped only at the YSQL layer. This leads to some confusing
behaviour where the table can't be accessed via ysqlsh, but can be seen in admin UIs.

The plan to properly fix this is being worked on in gh issue #753, but for now, re-enabling the
deletion of YSQL tables under replication, while still blocking YCQL table deletion.

Original commit: 48e8e32 / D18225

Closes #12003.

Test Plan:
```
ybd --cxx-test integration-tests_twodc_ysql-test --gtest_filter "*DeleteTableChecks*"
ybd --cxx-test integration-tests_twodc-test --gtest_filter "*DeleteTableChecks*"
```

Reviewers: rahuldesirazu, slingam, nicolas

Reviewed By: nicolas

Subscribers: bogdan, ybase

Differential Revision: https://phabricator.dev.yugabyte.com/D18473
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/ysql Yugabyte SQL (YSQL) kind/bug This issue is a bug priority/medium Medium priority issue xCluster Label for xCluster related issues/improvements
Projects
None yet
Development

No branches or pull requests

4 participants