This is an automated email from the ASF dual-hosted git repository.

shahrs87 pushed a commit to branch PHOENIX-6883-feature
in repository https://gitbox.apache.org/repos/asf/phoenix.git


The following commit(s) were added to refs/heads/PHOENIX-6883-feature by this 
push:
     new 8effca5b0c PHOENIX-7280 Test failure: 
ViewMetadataIT#testViewAndTableAndDropCascadeWithIndexes (#1858)
8effca5b0c is described below

commit 8effca5b0ccc74b3e7c95be979eeb19aee00b160
Author: Rushabh Shah <shahr...@apache.org>
AuthorDate: Tue Mar 19 14:36:26 2024 -0700

    PHOENIX-7280 Test failure: 
ViewMetadataIT#testViewAndTableAndDropCascadeWithIndexes (#1858)
---
 .../java/org/apache/phoenix/coprocessor/MetaDataEndpointImpl.java     | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git 
a/phoenix-core-server/src/main/java/org/apache/phoenix/coprocessor/MetaDataEndpointImpl.java
 
b/phoenix-core-server/src/main/java/org/apache/phoenix/coprocessor/MetaDataEndpointImpl.java
index 032ffefb3d..6eb7577e95 100644
--- 
a/phoenix-core-server/src/main/java/org/apache/phoenix/coprocessor/MetaDataEndpointImpl.java
+++ 
b/phoenix-core-server/src/main/java/org/apache/phoenix/coprocessor/MetaDataEndpointImpl.java
@@ -1491,7 +1491,7 @@ TABLE_FAMILY_BYTES, TABLE_SEQ_NUM_BYTES);
                     if (indexType != IndexType.LOCAL) {
                         parentTable = getTable(null, 
SchemaUtil.getSchemaNameFromFullName(famName.getBytes()).getBytes(StandardCharsets.UTF_8),
                                 
SchemaUtil.getTableNameFromFullName(famName.getBytes()).getBytes(StandardCharsets.UTF_8),
 clientTimeStamp, clientVersion);
-                        if (parentTable == null) {
+                        if (parentTable == null || 
isTableDeleted(parentTable)) {
                             // parentTable is not in the cache. Since famName 
is only logical name, we need to find the physical table.
                             try (PhoenixConnection connection = 
QueryUtil.getConnectionOnServer(env.getConfiguration()).unwrap(PhoenixConnection.class))
 {
                                 parentTable = 
connection.getTableNoCache(famName.getString());
@@ -1501,7 +1501,7 @@ TABLE_FAMILY_BYTES, TABLE_SEQ_NUM_BYTES);
                         }
                     }
 
-                    if (parentTable == null) {
+                    if (parentTable == null || isTableDeleted(parentTable)) {
                         if (indexType == IndexType.LOCAL) {
                             PName tablePhysicalName = getPhysicalTableName(
                                 env.getRegion(),null,

Reply via email to