HttpJobHandler优化,响应数据指定UTF-8格式,避免中文乱码;

master
xuxueli 5 years ago
parent 09afb8800e
commit a5cf6c61b9
  1. 1
      doc/XXL-JOB官方文档.md
  2. 2
      xxl-job-executor-samples/xxl-job-executor-sample-frameless/src/main/java/com/xuxueli/executor/sample/frameless/jobhandler/HttpJobHandler.java
  3. 2
      xxl-job-executor-samples/xxl-job-executor-sample-jboot/src/main/java/com/xuxueli/executor/sample/jboot/jobhandler/HttpJobHandler.java
  4. 2
      xxl-job-executor-samples/xxl-job-executor-sample-jfinal/src/main/java/com/xuxueli/executor/sample/jfinal/jobhandler/HttpJobHandler.java
  5. 2
      xxl-job-executor-samples/xxl-job-executor-sample-nutz/src/main/java/com/xuxueli/executor/sample/nutz/jobhandler/HttpJobHandler.java
  6. 2
      xxl-job-executor-samples/xxl-job-executor-sample-spring/src/main/java/com/xxl/job/executor/service/jobhandler/HttpJobHandler.java
  7. 2
      xxl-job-executor-samples/xxl-job-executor-sample-springboot/src/main/java/com/xxl/job/executor/service/jobhandler/HttpJobHandler.java

@ -1502,6 +1502,7 @@ Tips: 历史版本(V1.3.x)目前已经Release至稳定版本, 进入维护阶段
- 15、执行器回调线程优化,回调地址为空时销毁问题修复; - 15、执行器回调线程优化,回调地址为空时销毁问题修复;
- 16、任务日志主键调整为long,防止海量日志情况下数据溢出; - 16、任务日志主键调整为long,防止海量日志情况下数据溢出;
- 17、任务日志列表交互优化,操作按钮合并为分割按钮; - 17、任务日志列表交互优化,操作按钮合并为分割按钮;
- 18、HttpJobHandler优化,响应数据指定UTF-8格式,避免中文乱码;
### 6.26 版本 v2.1.1 Release Notes[规划中] ### 6.26 版本 v2.1.1 Release Notes[规划中]

@ -56,7 +56,7 @@ public class HttpJobHandler extends IJobHandler {
} }
// result // result
bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream())); bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream(), "UTF-8"));
StringBuilder result = new StringBuilder(); StringBuilder result = new StringBuilder();
String line; String line;
while ((line = bufferedReader.readLine()) != null) { while ((line = bufferedReader.readLine()) != null) {

@ -50,7 +50,7 @@ public class HttpJobHandler extends IJobHandler {
} }
// result // result
bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream())); bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream(), "UTF-8"));
StringBuilder result = new StringBuilder(); StringBuilder result = new StringBuilder();
String line; String line;
while ((line = bufferedReader.readLine()) != null) { while ((line = bufferedReader.readLine()) != null) {

@ -50,7 +50,7 @@ public class HttpJobHandler extends IJobHandler {
} }
// result // result
bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream())); bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream(), "UTF-8"));
StringBuilder result = new StringBuilder(); StringBuilder result = new StringBuilder();
String line; String line;
while ((line = bufferedReader.readLine()) != null) { while ((line = bufferedReader.readLine()) != null) {

@ -54,7 +54,7 @@ public class HttpJobHandler extends IJobHandler {
} }
// result // result
bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream())); bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream(), "UTF-8"));
StringBuilder result = new StringBuilder(); StringBuilder result = new StringBuilder();
String line; String line;
while ((line = bufferedReader.readLine()) != null) { while ((line = bufferedReader.readLine()) != null) {

@ -54,7 +54,7 @@ public class HttpJobHandler extends IJobHandler {
} }
// result // result
bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream())); bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream(), "UTF-8"));
StringBuilder result = new StringBuilder(); StringBuilder result = new StringBuilder();
String line; String line;
while ((line = bufferedReader.readLine()) != null) { while ((line = bufferedReader.readLine()) != null) {

@ -54,7 +54,7 @@ public class HttpJobHandler extends IJobHandler {
} }
// result // result
bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream())); bufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream(), "UTF-8"));
StringBuilder result = new StringBuilder(); StringBuilder result = new StringBuilder();
String line; String line;
while ((line = bufferedReader.readLine()) != null) { while ((line = bufferedReader.readLine()) != null) {

Loading…
Cancel
Save