mirror of
https://github.com/qaiu/netdisk-fast-download.git
synced 2025-12-17 12:53:02 +00:00
jdk11兼容
This commit is contained in:
@@ -12,7 +12,6 @@
|
||||
|
||||
<properties>
|
||||
<packageDirectory>${project.basedir}/target/package</packageDirectory>
|
||||
<java.version>17</java.version>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<finalName>netdisk-fast-download</finalName>
|
||||
</properties>
|
||||
|
||||
@@ -47,12 +47,10 @@ public class DbServiceImpl implements DbService {
|
||||
public Future<StatisticsInfo> getStatisticsInfo() {
|
||||
JDBCPool client = JDBCPoolInit.instance().getPool();
|
||||
Promise<StatisticsInfo> promise = Promise.promise();
|
||||
String sql = """
|
||||
select COUNT(CASE "code" WHEN 500 THEN "code" END ) "fail",
|
||||
COUNT(CASE "code" WHEN 200 THEN "code" END ) "success",
|
||||
count(1) "total"
|
||||
from "t_parser_log_info"
|
||||
""";
|
||||
String sql = "select COUNT(CASE \"code\" WHEN 500 THEN \"code\" END ) \"fail\",\n" +
|
||||
" COUNT(CASE \"code\" WHEN 200 THEN \"code\" END ) \"success\",\n" +
|
||||
" count(1) \"total\"\n" +
|
||||
" from \"t_parser_log_info\"";
|
||||
SqlTemplate.forQuery(client, sql).mapTo(StatisticsInfo.class).execute(new HashMap<>()).onSuccess(row -> {
|
||||
StatisticsInfo info;
|
||||
if ((info = row.iterator().next()) != null) {
|
||||
|
||||
@@ -9,10 +9,9 @@ public class TestRegex {
|
||||
|
||||
@Test
|
||||
public void regexYFC() {
|
||||
String html = """
|
||||
<input type="hidden" id="typed_id" value="file_559003251828">
|
||||
<input type="hidden" id="share_link_token" value="9cbe4b73521ba4d65a8cd38a8c">
|
||||
""";
|
||||
String html = "<input type=\"hidden\" id=\"typed_id\" value=\"file_559003251828\">\n" +
|
||||
" <input type=\"hidden\" id=\"share_link_token\" " +
|
||||
"value=\"9cbe4b73521ba4d65a8cd38a8c\">";
|
||||
|
||||
Pattern compile = Pattern.compile("id=\"typed_id\"\\s+value=\"file_(\\d+)\"");
|
||||
Matcher matcher = compile.matcher(html);
|
||||
|
||||
@@ -154,14 +154,14 @@ public class WebProxyExamples {
|
||||
|
||||
public static void main(String[] args) {
|
||||
final WebProxyExamples examples = new WebProxyExamples();
|
||||
examples.vertx.executeBlocking(rs -> {
|
||||
rs.complete();
|
||||
examples.origin();
|
||||
});
|
||||
examples.vertx.executeBlocking(rs -> {
|
||||
rs.complete();
|
||||
examples.route();
|
||||
});
|
||||
// examples.vertx.executeBlocking(rs -> {
|
||||
// rs.complete();
|
||||
// examples.origin();
|
||||
// });
|
||||
// examples.vertx.executeBlocking(rs -> {
|
||||
// rs.complete();
|
||||
// examples.route();
|
||||
// });
|
||||
System.out.println("ok");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user