diff --git a/mybatis-flex-core/src/main/java/com/mybatisflex/core/audit/http/HttpUtil.java b/mybatis-flex-core/src/main/java/com/mybatisflex/core/audit/http/HttpUtil.java index c424331f..0b706e62 100644 --- a/mybatis-flex-core/src/main/java/com/mybatisflex/core/audit/http/HttpUtil.java +++ b/mybatis-flex-core/src/main/java/com/mybatisflex/core/audit/http/HttpUtil.java @@ -82,7 +82,7 @@ public class HttpUtil { private static SSLSocketFactory initSSLSocketFactory() { try { TrustManager[] tm = {new HttpUtil.TrustAnyTrustManager()}; - SSLContext sslContext = SSLContext.getInstance("TLS"); // ("TLS", "SunJSSE"); + SSLContext sslContext = SSLContext.getInstance("TLS"); // "TLS", "SunJSSE" sslContext.init(null, tm, new java.security.SecureRandom()); return sslContext.getSocketFactory(); } catch (Exception e) { diff --git a/mybatis-flex-core/src/main/java/com/mybatisflex/core/keygen/MybatisKeyGeneratorUtil.java b/mybatis-flex-core/src/main/java/com/mybatisflex/core/keygen/MybatisKeyGeneratorUtil.java index 6db4270e..228013ab 100644 --- a/mybatis-flex-core/src/main/java/com/mybatisflex/core/keygen/MybatisKeyGeneratorUtil.java +++ b/mybatis-flex-core/src/main/java/com/mybatisflex/core/keygen/MybatisKeyGeneratorUtil.java @@ -107,7 +107,7 @@ public class MybatisKeyGeneratorUtil { //看到有的框架把 keyGenerator 添加到 mybatis 的当前配置里去,其实是完全没必要的 //因为只有在 xml 解析的时候,才可能存在多一个 MappedStatement 拥有同一个 keyGenerator 的情况 //当前每个方法都拥有一个自己的 keyGenerator 了,没必要添加 - //this.addKeyGenerator(selectId, keyGenerator); + //addKeyGenerator(selectId, keyGenerator) return new SelectKeyGenerator(keyMappedStatement, isKeyBefore(idInfo, globalKeyConfig)); } diff --git a/mybatis-flex-core/src/main/java/com/mybatisflex/core/keygen/RowKeyGenerator.java b/mybatis-flex-core/src/main/java/com/mybatisflex/core/keygen/RowKeyGenerator.java index 2375af65..53d3feb0 100644 --- a/mybatis-flex-core/src/main/java/com/mybatisflex/core/keygen/RowKeyGenerator.java +++ b/mybatis-flex-core/src/main/java/com/mybatisflex/core/keygen/RowKeyGenerator.java @@ -1,17 +1,17 @@ -/** - * Copyright (c) 2022-2023, Mybatis-Flex (fuhai999@gmail.com). - *
- * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - *
- * http://www.apache.org/licenses/LICENSE-2.0 - *
- * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. +/* + * Copyright (c) 2022-2023, Mybatis-Flex (fuhai999@gmail.com). + *
+ * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + *
+ * http://www.apache.org/licenses/LICENSE-2.0 + *
+ * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.mybatisflex.core.keygen; @@ -128,7 +128,7 @@ public class RowKeyGenerator implements KeyGenerator, IMultiKeyGenerator { //看到有的框架把 keyGenerator 添加到 mybatis 的当前配置里去,其实是完全没必要的 //因为只有在 xml 解析的时候,才可能存在多一个 MappedStatement 拥有同一个 keyGenerator 的情况 //当前每个方法都拥有一个自己的 keyGenerator 了,没必要添加 - //this.addKeyGenerator(selectId, keyGenerator); + //addKeyGenerator(selectId, keyGenerator) return new SelectKeyGenerator(keyMappedStatement, rowKey.isBefore()); } diff --git a/mybatis-flex-core/src/main/java/com/mybatisflex/core/util/UpdateEntity.java b/mybatis-flex-core/src/main/java/com/mybatisflex/core/util/UpdateEntity.java index 1061cbd4..ece89e72 100644 --- a/mybatis-flex-core/src/main/java/com/mybatisflex/core/util/UpdateEntity.java +++ b/mybatis-flex-core/src/main/java/com/mybatisflex/core/util/UpdateEntity.java @@ -92,8 +92,8 @@ public class UpdateEntity { if (value != null) { reflector.getSetInvoker(propertyName).invoke(newEntity, new Object[]{value}); } - } catch (Exception e) { - //ignore; + } catch (Exception ignored) { + // do nothing here. } }