TeslaCN commented on a change in pull request #12432:
URL: https://github.com/apache/shardingsphere/pull/12432#discussion_r711611361
##########
File path:
shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/yaml/schema/swapper/SchemaYamlSwapper.java
##########
@@ -45,7 +45,7 @@
@Override
public YamlSchema swapToYamlConfiguration(final ShardingSphereSchema
schema) {
Map<String, YamlTableMetaData> tables =
schema.getAllTableNames().stream()
- .collect(Collectors.toMap(each -> each, each ->
swapYamlTable(schema.get(each)), (oldValue, currentValue) -> oldValue,
LinkedHashMap::new));
+ .collect(Collectors.<String, String, YamlTableMetaData,
Map>toMap(each -> each, each -> swapYamlTable(schema.get(each)), (oldValue,
currentValue) -> oldValue, LinkedHashMap::new));
Review comment:
Hi @totalo
This change causes build failed on JDK11 and JDK17. Is there any problem
before?
```
[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-compiler-plugin:3.8.0:compile (default-compile)
on project shardingsphere-infra-common: Compilation failure
[ERROR]
/Users/wuweijie/IdeaProjects/shardingsphere/shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/yaml/schema/swapper/SchemaYamlSwapper.java:[48,25]
incompatible types: java.lang.Object cannot be converted to
java.util.Map<java.lang.String,org.apache.shardingsphere.infra.yaml.schema.pojo.YamlTableMetaData>
[ERROR]
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e
switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please
read the following articles:
[ERROR] [Help 1]
http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the
command
[ERROR] mvn <args> -rf :shardingsphere-infra-common
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]