You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by zh...@apache.org on 2024/12/01 07:43:24 UTC
(shardingsphere) branch master updated: Try to fix #33860 (#33861)
This is an automated email from the ASF dual-hosted git repository.
zhangliang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git
The following commit(s) were added to refs/heads/master by this push:
new 1671636b062 Try to fix #33860 (#33861)
1671636b062 is described below
commit 1671636b062c66c1a50cd45da31c641eced46c40
Author: Liang Zhang <zh...@apache.org>
AuthorDate: Sun Dec 1 15:43:18 2024 +0800
Try to fix #33860 (#33861)
---
.../builder/dialect/PostgreSQLShardingSphereStatisticsBuilder.java | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/infra/common/src/main/java/org/apache/shardingsphere/infra/metadata/statistics/builder/dialect/PostgreSQLShardingSphereStatisticsBuilder.java b/infra/common/src/main/java/org/apache/shardingsphere/infra/metadata/statistics/builder/dialect/PostgreSQLShardingSphereStatisticsBuilder.java
index c9a85dac946..c4c64fc4029 100644
--- a/infra/common/src/main/java/org/apache/shardingsphere/infra/metadata/statistics/builder/dialect/PostgreSQLShardingSphereStatisticsBuilder.java
+++ b/infra/common/src/main/java/org/apache/shardingsphere/infra/metadata/statistics/builder/dialect/PostgreSQLShardingSphereStatisticsBuilder.java
@@ -76,8 +76,10 @@ public final class PostgreSQLShardingSphereStatisticsBuilder implements Sharding
}
for (Entry<String, Collection<String>> entry : INIT_DATA_SCHEMA_TABLES.entrySet()) {
ShardingSphereSchemaData schemaData = new ShardingSphereSchemaData();
- initTables(database.getSchema(entry.getKey()), entry.getValue(), schemaData);
- databaseData.putSchema(entry.getKey(), schemaData);
+ if (null != database.getSchema(entry.getKey())) {
+ initTables(database.getSchema(entry.getKey()), entry.getValue(), schemaData);
+ databaseData.putSchema(entry.getKey(), schemaData);
+ }
}
}