diff --git a/distribution/proxy/Dockerfile b/distribution/proxy/Dockerfile index 2c8f67c543c4e..b5700834f994e 100644 --- a/distribution/proxy/Dockerfile +++ b/distribution/proxy/Dockerfile @@ -14,6 +14,7 @@ # See the License for the specific language governing permissions and # limitations under the License. # + FROM alpine AS prepare ARG APP_NAME diff --git a/mode/core/src/main/java/org/apache/shardingsphere/mode/metadata/MetaDataContextsFactory.java b/mode/core/src/main/java/org/apache/shardingsphere/mode/metadata/MetaDataContextsFactory.java index 62dd8cc503715..0a2928f41f314 100644 --- a/mode/core/src/main/java/org/apache/shardingsphere/mode/metadata/MetaDataContextsFactory.java +++ b/mode/core/src/main/java/org/apache/shardingsphere/mode/metadata/MetaDataContextsFactory.java @@ -25,6 +25,7 @@ import org.apache.shardingsphere.infra.config.props.ConfigurationProperties; import org.apache.shardingsphere.infra.config.rule.RuleConfiguration; import org.apache.shardingsphere.infra.database.DatabaseTypeEngine; +import org.apache.shardingsphere.infra.database.core.type.DatabaseType; import org.apache.shardingsphere.infra.datasource.pool.config.DataSourceConfiguration; import org.apache.shardingsphere.infra.datasource.pool.destroyer.DataSourcePoolDestroyer; import org.apache.shardingsphere.infra.datasource.pool.props.domain.DataSourcePoolProperties; @@ -253,10 +254,10 @@ public static ShardingSphereDatabase createChangedDatabase(final String database private static ShardingSphereDatabase createChangedDatabase(final String databaseName, final boolean internalLoadMetaData, final MetaDataPersistService persistService, final DatabaseConfiguration databaseConfig, final ConfigurationProperties props, final ComputeNodeInstanceContext instanceContext) throws SQLException { + DatabaseType protocolType = DatabaseTypeEngine.getProtocolType(databaseConfig, props); return internalLoadMetaData - ? ShardingSphereDatabase.create(databaseName, DatabaseTypeEngine.getProtocolType(databaseConfig, props), - databaseConfig, instanceContext, persistService.getDatabaseMetaDataFacade().getSchema().load(databaseName)) - : ShardingSphereDatabase.create(databaseName, DatabaseTypeEngine.getProtocolType(databaseConfig, props), databaseConfig, props, instanceContext); + ? ShardingSphereDatabase.create(databaseName, protocolType, databaseConfig, instanceContext, persistService.getDatabaseMetaDataFacade().getSchema().load(databaseName)) + : ShardingSphereDatabase.create(databaseName, protocolType, databaseConfig, props, instanceContext); } private static ResourceMetaData getEffectiveResourceMetaData(final ShardingSphereDatabase database, final SwitchingResource resource) {