weather 20240922 改造成jpa
parent
51e892959d
commit
cf5a0e2000
@ -0,0 +1,33 @@
|
||||
HELP.md
|
||||
target/
|
||||
!.mvn/wrapper/maven-wrapper.jar
|
||||
!**/src/main/**/target/
|
||||
!**/src/test/**/target/
|
||||
|
||||
### STS ###
|
||||
.apt_generated
|
||||
.classpath
|
||||
.factorypath
|
||||
.project
|
||||
.settings
|
||||
.springBeans
|
||||
.sts4-cache
|
||||
|
||||
### IntelliJ IDEA ###
|
||||
.idea
|
||||
*.iws
|
||||
*.iml
|
||||
*.ipr
|
||||
|
||||
### NetBeans ###
|
||||
/nbproject/private/
|
||||
/nbbuild/
|
||||
/dist/
|
||||
/nbdist/
|
||||
/.nb-gradle/
|
||||
build/
|
||||
!**/src/main/**/build/
|
||||
!**/src/test/**/build/
|
||||
|
||||
### VS Code ###
|
||||
.vscode/
|
||||
@ -0,0 +1,118 @@
|
||||
/*
|
||||
* Copyright 2007-present the original author or authors.
|
||||
*
|
||||
* 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
|
||||
*
|
||||
* https://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.
|
||||
*/
|
||||
|
||||
import java.net.*;
|
||||
import java.io.*;
|
||||
import java.nio.channels.*;
|
||||
import java.util.Properties;
|
||||
|
||||
public class MavenWrapperDownloader {
|
||||
|
||||
private static final String WRAPPER_VERSION = "0.5.6";
|
||||
/**
|
||||
* Default URL to download the maven-wrapper.jar from, if no 'downloadUrl' is provided.
|
||||
*/
|
||||
private static final String DEFAULT_DOWNLOAD_URL = "https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/"
|
||||
+ WRAPPER_VERSION + "/maven-wrapper-" + WRAPPER_VERSION + ".jar";
|
||||
|
||||
/**
|
||||
* Path to the maven-wrapper.properties file, which might contain a downloadUrl property to
|
||||
* use instead of the default one.
|
||||
*/
|
||||
private static final String MAVEN_WRAPPER_PROPERTIES_PATH =
|
||||
".mvn/wrapper/maven-wrapper.properties";
|
||||
|
||||
/**
|
||||
* Path where the maven-wrapper.jar will be saved to.
|
||||
*/
|
||||
private static final String MAVEN_WRAPPER_JAR_PATH =
|
||||
".mvn/wrapper/maven-wrapper.jar";
|
||||
|
||||
/**
|
||||
* Name of the property which should be used to override the default download url for the wrapper.
|
||||
*/
|
||||
private static final String PROPERTY_NAME_WRAPPER_URL = "wrapperUrl";
|
||||
|
||||
public static void main(String args[]) {
|
||||
System.out.println("- Downloader started");
|
||||
File baseDirectory = new File(args[0]);
|
||||
System.out.println("- Using base directory: " + baseDirectory.getAbsolutePath());
|
||||
|
||||
// If the maven-wrapper.properties exists, read it and check if it contains a custom
|
||||
// wrapperUrl parameter.
|
||||
File mavenWrapperPropertyFile = new File(baseDirectory, MAVEN_WRAPPER_PROPERTIES_PATH);
|
||||
String url = DEFAULT_DOWNLOAD_URL;
|
||||
if (mavenWrapperPropertyFile.exists()) {
|
||||
FileInputStream mavenWrapperPropertyFileInputStream = null;
|
||||
try {
|
||||
mavenWrapperPropertyFileInputStream = new FileInputStream(mavenWrapperPropertyFile);
|
||||
Properties mavenWrapperProperties = new Properties();
|
||||
mavenWrapperProperties.load(mavenWrapperPropertyFileInputStream);
|
||||
url = mavenWrapperProperties.getProperty(PROPERTY_NAME_WRAPPER_URL, url);
|
||||
} catch (IOException e) {
|
||||
System.out.println("- ERROR loading '" + MAVEN_WRAPPER_PROPERTIES_PATH + "'");
|
||||
} finally {
|
||||
try {
|
||||
if (mavenWrapperPropertyFileInputStream != null) {
|
||||
mavenWrapperPropertyFileInputStream.close();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
// Ignore ...
|
||||
}
|
||||
}
|
||||
}
|
||||
System.out.println("- Downloading from: " + url);
|
||||
|
||||
File outputFile = new File(baseDirectory.getAbsolutePath(), MAVEN_WRAPPER_JAR_PATH);
|
||||
if (!outputFile.getParentFile().exists()) {
|
||||
if (!outputFile.getParentFile().mkdirs()) {
|
||||
System.out.println(
|
||||
"- ERROR creating output directory '" + outputFile.getParentFile().getAbsolutePath() + "'");
|
||||
}
|
||||
}
|
||||
System.out.println("- Downloading to: " + outputFile.getAbsolutePath());
|
||||
try {
|
||||
downloadFileFromURL(url, outputFile);
|
||||
System.out.println("Done");
|
||||
System.exit(0);
|
||||
} catch (Throwable e) {
|
||||
System.out.println("- Error downloading");
|
||||
e.printStackTrace();
|
||||
System.exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
private static void downloadFileFromURL(String urlString, File destination) throws Exception {
|
||||
if (System.getenv("MVNW_USERNAME") != null && System.getenv("MVNW_PASSWORD") != null) {
|
||||
String username = System.getenv("MVNW_USERNAME");
|
||||
char[] password = System.getenv("MVNW_PASSWORD").toCharArray();
|
||||
Authenticator.setDefault(new Authenticator() {
|
||||
@Override
|
||||
protected PasswordAuthentication getPasswordAuthentication() {
|
||||
return new PasswordAuthentication(username, password);
|
||||
}
|
||||
});
|
||||
}
|
||||
URL website = new URL(urlString);
|
||||
ReadableByteChannel rbc;
|
||||
rbc = Channels.newChannel(website.openStream());
|
||||
FileOutputStream fos = new FileOutputStream(destination);
|
||||
fos.getChannel().transferFrom(rbc, 0, Long.MAX_VALUE);
|
||||
fos.close();
|
||||
rbc.close();
|
||||
}
|
||||
|
||||
}
|
||||
Binary file not shown.
@ -0,0 +1,2 @@
|
||||
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.1/apache-maven-3.8.1-bin.zip
|
||||
wrapperUrl=https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar
|
||||
@ -0,0 +1,377 @@
|
||||
#
|
||||
# There is insufficient memory for the Java Runtime Environment to continue.
|
||||
# Native memory allocation (malloc) failed to allocate 40864 bytes for Chunk::new
|
||||
# Possible reasons:
|
||||
# The system is out of physical RAM or swap space
|
||||
# The process is running with CompressedOops enabled, and the Java Heap may be blocking the growth of the native heap
|
||||
# Possible solutions:
|
||||
# Reduce memory load on the system
|
||||
# Increase physical memory or swap space
|
||||
# Check if swap backing store is full
|
||||
# Decrease Java heap size (-Xmx/-Xms)
|
||||
# Decrease number of Java threads
|
||||
# Decrease Java thread stack sizes (-Xss)
|
||||
# Set larger code cache with -XX:ReservedCodeCacheSize=
|
||||
# JVM is running with Unscaled Compressed Oops mode in which the Java heap is
|
||||
# placed in the first 4GB address space. The Java Heap base address is the
|
||||
# maximum limit for the native heap growth. Please use -XX:HeapBaseMinAddress
|
||||
# to set the Java Heap base and to place the Java Heap above 4GB virtual address.
|
||||
# This output file may be truncated or incomplete.
|
||||
#
|
||||
# Out of Memory Error (allocation.cpp:389), pid=14080, tid=0x00000000000037a4
|
||||
#
|
||||
# JRE version: Java(TM) SE Runtime Environment (8.0_261-b12) (build 1.8.0_261-b12)
|
||||
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.261-b12 mixed mode windows-amd64 compressed oops)
|
||||
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
|
||||
#
|
||||
|
||||
--------------- T H R E A D ---------------
|
||||
|
||||
Current thread (0x0000017b9ed68800): JavaThread "C1 CompilerThread3" daemon [_thread_in_native, id=14244, stack(0x000000080f100000,0x000000080f200000)]
|
||||
|
||||
Stack: [0x000000080f100000,0x000000080f200000]
|
||||
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
|
||||
V [jvm.dll+0x33e5f9]
|
||||
V [jvm.dll+0x2850e2]
|
||||
V [jvm.dll+0x285d8d]
|
||||
V [jvm.dll+0x27c895]
|
||||
V [jvm.dll+0xe4d6c]
|
||||
V [jvm.dll+0xe556c]
|
||||
V [jvm.dll+0x53cf3]
|
||||
V [jvm.dll+0x50300]
|
||||
V [jvm.dll+0xc3140]
|
||||
V [jvm.dll+0xc2bad]
|
||||
V [jvm.dll+0x4ecc6]
|
||||
V [jvm.dll+0x3fe070]
|
||||
V [jvm.dll+0x3f22b4]
|
||||
V [jvm.dll+0x3f260e]
|
||||
V [jvm.dll+0x40562c]
|
||||
V [jvm.dll+0x4053a2]
|
||||
V [jvm.dll+0x3ef408]
|
||||
V [jvm.dll+0x3ef72e]
|
||||
V [jvm.dll+0x3ef99e]
|
||||
V [jvm.dll+0x3ef0f1]
|
||||
V [jvm.dll+0x3f0b2f]
|
||||
V [jvm.dll+0xbbbcb]
|
||||
V [jvm.dll+0xba22b]
|
||||
V [jvm.dll+0x24d962]
|
||||
V [jvm.dll+0x2a1cfc]
|
||||
C [ucrtbase.dll+0x210b2]
|
||||
C [KERNEL32.DLL+0x17c24]
|
||||
C [ntdll.dll+0x6d721]
|
||||
|
||||
|
||||
Current CompileTask:
|
||||
C1: 7646 3645 1 org.springframework.asm.ClassReader::readCode (5105 bytes)
|
||||
|
||||
|
||||
--------------- P R O C E S S ---------------
|
||||
|
||||
Java Threads: ( => current thread )
|
||||
0x0000017b9efb6800 JavaThread "RMI TCP Connection(3)-192.168.2.161" daemon [_thread_in_native, id=4700, stack(0x000000080fc00000,0x000000080fd00000)]
|
||||
0x0000017b9ecbc000 JavaThread "lettuce-timer-3-1" daemon [_thread_blocked, id=4264, stack(0x000000080fb00000,0x000000080fc00000)]
|
||||
0x0000017ba0d6d800 JavaThread "container-0" [_thread_blocked, id=10844, stack(0x000000080fa00000,0x000000080fb00000)]
|
||||
0x0000017ba0d6c800 JavaThread "Catalina-utility-2" [_thread_blocked, id=6088, stack(0x000000080f900000,0x000000080fa00000)]
|
||||
0x0000017ba0d59000 JavaThread "Catalina-utility-1" [_thread_blocked, id=11644, stack(0x000000080f800000,0x000000080f900000)]
|
||||
0x0000017ba0be8800 JavaThread "mysql-cj-abandoned-connection-cleanup" daemon [_thread_blocked, id=9752, stack(0x000000080f700000,0x000000080f800000)]
|
||||
0x0000017b9f479000 JavaThread "RMI Scheduler(0)" daemon [_thread_blocked, id=14300, stack(0x000000080f600000,0x000000080f700000)]
|
||||
0x0000017b9f426800 JavaThread "RMI TCP Connection(2)-192.168.2.161" daemon [_thread_in_native, id=14288, stack(0x000000080f500000,0x000000080f600000)]
|
||||
0x0000017b9f0ab800 JavaThread "RMI TCP Accept-0" daemon [_thread_in_native, id=14260, stack(0x000000080f300000,0x000000080f400000)]
|
||||
0x0000017b9edb2800 JavaThread "Service Thread" daemon [_thread_blocked, id=14248, stack(0x000000080f200000,0x000000080f300000)]
|
||||
=>0x0000017b9ed68800 JavaThread "C1 CompilerThread3" daemon [_thread_in_native, id=14244, stack(0x000000080f100000,0x000000080f200000)]
|
||||
0x0000017b9ed65800 JavaThread "C2 CompilerThread2" daemon [_thread_blocked, id=14240, stack(0x000000080f000000,0x000000080f100000)]
|
||||
0x0000017b9ece8000 JavaThread "C2 CompilerThread1" daemon [_thread_blocked, id=14236, stack(0x000000080ef00000,0x000000080f000000)]
|
||||
0x0000017b9ed5a000 JavaThread "C2 CompilerThread0" daemon [_thread_blocked, id=14232, stack(0x000000080ee00000,0x000000080ef00000)]
|
||||
0x0000017b9e9ee800 JavaThread "JDWP Command Reader" daemon [_thread_in_native, id=14212, stack(0x000000080ed00000,0x000000080ee00000)]
|
||||
0x0000017b9e9e9800 JavaThread "JDWP Event Helper Thread" daemon [_thread_blocked, id=14208, stack(0x000000080ec00000,0x000000080ed00000)]
|
||||
0x0000017b9ccb9800 JavaThread "JDWP Transport Listener: dt_socket" daemon [_thread_blocked, id=14204, stack(0x000000080eb00000,0x000000080ec00000)]
|
||||
0x0000017b9cc5c000 JavaThread "Attach Listener" daemon [_thread_blocked, id=14200, stack(0x000000080ea00000,0x000000080eb00000)]
|
||||
0x0000017b9cc5b000 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=14196, stack(0x000000080e900000,0x000000080ea00000)]
|
||||
0x0000017b9cc26000 JavaThread "Finalizer" daemon [_thread_blocked, id=14192, stack(0x000000080e800000,0x000000080e900000)]
|
||||
0x0000017b9cc1e000 JavaThread "Reference Handler" daemon [_thread_blocked, id=14188, stack(0x000000080e700000,0x000000080e800000)]
|
||||
0x0000017b86adf800 JavaThread "main" [_thread_in_native, id=14148, stack(0x000000080dd00000,0x000000080de00000)]
|
||||
|
||||
Other Threads:
|
||||
0x0000017b9cbf2800 VMThread [stack: 0x000000080e600000,0x000000080e700000] [id=14184]
|
||||
0x0000017b9f0c3800 WatcherThread [stack: 0x000000080f400000,0x000000080f500000] [id=14264]
|
||||
|
||||
VM state:not at safepoint (normal execution)
|
||||
|
||||
VM Mutex/Monitor currently owned by a thread: None
|
||||
|
||||
heap address: 0x0000000083200000, size: 1998 MB, Compressed Oops mode: 32-bit
|
||||
Narrow klass base: 0x0000000000000000, Narrow klass shift: 3
|
||||
Compressed class space size: 1073741824 Address: 0x0000000100000000
|
||||
|
||||
Heap:
|
||||
PSYoungGen total 112640K, used 10623K [0x00000000d6600000, 0x00000000dde80000, 0x0000000100000000)
|
||||
eden space 103936K, 1% used [0x00000000d6600000,0x00000000d67e14a8,0x00000000dcb80000)
|
||||
from space 8704K, 99% used [0x00000000dd580000,0x00000000dddfe888,0x00000000dde00000)
|
||||
to space 9728K, 0% used [0x00000000dcb80000,0x00000000dcb80000,0x00000000dd500000)
|
||||
ParOldGen total 89088K, used 15509K [0x0000000083200000, 0x0000000088900000, 0x00000000d6600000)
|
||||
object space 89088K, 17% used [0x0000000083200000,0x00000000841257b8,0x0000000088900000)
|
||||
Metaspace used 39433K, capacity 42024K, committed 42152K, reserved 1087488K
|
||||
class space used 5278K, capacity 5771K, committed 5808K, reserved 1048576K
|
||||
|
||||
Card table byte_map: [0x0000017b979d0000,0x0000017b97dc0000] byte_map_base: 0x0000017b975b7000
|
||||
|
||||
Marking Bits: (ParMarkBitMap*) 0x0000000071474fb0
|
||||
Begin Bits: [0x0000017b98060000, 0x0000017b99f98000)
|
||||
End Bits: [0x0000017b99f98000, 0x0000017b9bed0000)
|
||||
|
||||
Polling page: 0x0000017b86a80000
|
||||
|
||||
CodeCache: size=245760Kb used=7673Kb max_used=7673Kb free=238086Kb
|
||||
bounds [0x0000017b88610000, 0x0000017b88d90000, 0x0000017b97610000]
|
||||
total_blobs=4111 nmethods=3644 adapters=387
|
||||
compilation: enabled
|
||||
|
||||
Compilation events (10 events):
|
||||
Event: 7.610 Thread 0x0000017b9ed68800 nmethod 3641 0x0000017b88d8c250 code [0x0000017b88d8c3a0, 0x0000017b88d8c4f0]
|
||||
Event: 7.610 Thread 0x0000017b9ed68800 3642 1 org.springframework.data.mapping.model.SimpleTypeHolder::isSimpleType (180 bytes)
|
||||
Event: 7.611 Thread 0x0000017b9ed68800 nmethod 3642 0x0000017b88d8c590 code [0x0000017b88d8c8a0, 0x0000017b88d8d280]
|
||||
Event: 7.611 Thread 0x0000017b9ed68800 3639 1 org.springframework.data.convert.CustomConversions$$Lambda$766/1605741888::test (12 bytes)
|
||||
Event: 7.611 Thread 0x0000017b9ed68800 nmethod 3639 0x0000017b88d8dbd0 code [0x0000017b88d8dd40, 0x0000017b88d8ded0]
|
||||
Event: 7.611 Thread 0x0000017b9ed68800 3643 1 org.springframework.beans.factory.support.AbstractBeanFactory::getBean (9 bytes)
|
||||
Event: 7.611 Thread 0x0000017b9ed68800 nmethod 3643 0x0000017b88d8df90 code [0x0000017b88d8e100, 0x0000017b88d8e270]
|
||||
Event: 7.612 Thread 0x0000017b9ed68800 3644 1 org.springframework.core.convert.TypeDescriptor$AnnotatedElementAdapter::<init> (15 bytes)
|
||||
Event: 7.612 Thread 0x0000017b9ed68800 nmethod 3644 0x0000017b88d8e310 code [0x0000017b88d8e460, 0x0000017b88d8e598]
|
||||
Event: 7.613 Thread 0x0000017b9ed68800 3645 1 org.springframework.asm.ClassReader::readCode (5105 bytes)
|
||||
|
||||
GC Heap History (10 events):
|
||||
Event: 3.400 GC heap before
|
||||
{Heap before GC invocations=5 (full 1):
|
||||
PSYoungGen total 70656K, used 5101K [0x00000000d6600000, 0x00000000db000000, 0x0000000100000000)
|
||||
eden space 65536K, 0% used [0x00000000d6600000,0x00000000d6600000,0x00000000da600000)
|
||||
from space 5120K, 99% used [0x00000000dab00000,0x00000000daffb6c8,0x00000000db000000)
|
||||
to space 5120K, 0% used [0x00000000da600000,0x00000000da600000,0x00000000dab00000)
|
||||
ParOldGen total 86016K, used 5431K [0x0000000083200000, 0x0000000088600000, 0x00000000d6600000)
|
||||
object space 86016K, 6% used [0x0000000083200000,0x000000008374de70,0x0000000088600000)
|
||||
Metaspace used 20424K, capacity 21224K, committed 21296K, reserved 1067008K
|
||||
class space used 2634K, capacity 2838K, committed 2864K, reserved 1048576K
|
||||
Event: 3.438 GC heap after
|
||||
Heap after GC invocations=5 (full 1):
|
||||
PSYoungGen total 70656K, used 0K [0x00000000d6600000, 0x00000000db000000, 0x0000000100000000)
|
||||
eden space 65536K, 0% used [0x00000000d6600000,0x00000000d6600000,0x00000000da600000)
|
||||
from space 5120K, 0% used [0x00000000dab00000,0x00000000dab00000,0x00000000db000000)
|
||||
to space 5120K, 0% used [0x00000000da600000,0x00000000da600000,0x00000000dab00000)
|
||||
ParOldGen total 54784K, used 5903K [0x0000000083200000, 0x0000000086780000, 0x00000000d6600000)
|
||||
object space 54784K, 10% used [0x0000000083200000,0x00000000837c3dc8,0x0000000086780000)
|
||||
Metaspace used 20424K, capacity 21224K, committed 21296K, reserved 1067008K
|
||||
class space used 2634K, capacity 2838K, committed 2864K, reserved 1048576K
|
||||
}
|
||||
Event: 4.281 GC heap before
|
||||
{Heap before GC invocations=6 (full 1):
|
||||
PSYoungGen total 70656K, used 65536K [0x00000000d6600000, 0x00000000db000000, 0x0000000100000000)
|
||||
eden space 65536K, 100% used [0x00000000d6600000,0x00000000da600000,0x00000000da600000)
|
||||
from space 5120K, 0% used [0x00000000dab00000,0x00000000dab00000,0x00000000db000000)
|
||||
to space 5120K, 0% used [0x00000000da600000,0x00000000da600000,0x00000000dab00000)
|
||||
ParOldGen total 54784K, used 5903K [0x0000000083200000, 0x0000000086780000, 0x00000000d6600000)
|
||||
object space 54784K, 10% used [0x0000000083200000,0x00000000837c3dc8,0x0000000086780000)
|
||||
Metaspace used 24016K, capacity 25162K, committed 25520K, reserved 1071104K
|
||||
class space used 3148K, capacity 3397K, committed 3504K, reserved 1048576K
|
||||
Event: 4.290 GC heap after
|
||||
Heap after GC invocations=6 (full 1):
|
||||
PSYoungGen total 70656K, used 5104K [0x00000000d6600000, 0x00000000dde00000, 0x0000000100000000)
|
||||
eden space 65536K, 0% used [0x00000000d6600000,0x00000000d6600000,0x00000000da600000)
|
||||
from space 5120K, 99% used [0x00000000da600000,0x00000000daafc1f8,0x00000000dab00000)
|
||||
to space 8704K, 0% used [0x00000000dd580000,0x00000000dd580000,0x00000000dde00000)
|
||||
ParOldGen total 54784K, used 7533K [0x0000000083200000, 0x0000000086780000, 0x00000000d6600000)
|
||||
object space 54784K, 13% used [0x0000000083200000,0x000000008395b7a0,0x0000000086780000)
|
||||
Metaspace used 24016K, capacity 25162K, committed 25520K, reserved 1071104K
|
||||
class space used 3148K, capacity 3397K, committed 3504K, reserved 1048576K
|
||||
}
|
||||
Event: 5.489 GC heap before
|
||||
{Heap before GC invocations=7 (full 1):
|
||||
PSYoungGen total 70656K, used 70640K [0x00000000d6600000, 0x00000000dde00000, 0x0000000100000000)
|
||||
eden space 65536K, 100% used [0x00000000d6600000,0x00000000da600000,0x00000000da600000)
|
||||
from space 5120K, 99% used [0x00000000da600000,0x00000000daafc1f8,0x00000000dab00000)
|
||||
to space 8704K, 0% used [0x00000000dd580000,0x00000000dd580000,0x00000000dde00000)
|
||||
ParOldGen total 54784K, used 7533K [0x0000000083200000, 0x0000000086780000, 0x00000000d6600000)
|
||||
object space 54784K, 13% used [0x0000000083200000,0x000000008395b7a0,0x0000000086780000)
|
||||
Metaspace used 28489K, capacity 29978K, committed 30256K, reserved 1075200K
|
||||
class space used 3782K, capacity 4093K, committed 4144K, reserved 1048576K
|
||||
Event: 5.502 GC heap after
|
||||
Heap after GC invocations=7 (full 1):
|
||||
PSYoungGen total 112640K, used 8682K [0x00000000d6600000, 0x00000000dde80000, 0x0000000100000000)
|
||||
eden space 103936K, 0% used [0x00000000d6600000,0x00000000d6600000,0x00000000dcb80000)
|
||||
from space 8704K, 99% used [0x00000000dd580000,0x00000000dddfa938,0x00000000dde00000)
|
||||
to space 9728K, 0% used [0x00000000dcb80000,0x00000000dcb80000,0x00000000dd500000)
|
||||
ParOldGen total 54784K, used 7701K [0x0000000083200000, 0x0000000086780000, 0x00000000d6600000)
|
||||
object space 54784K, 14% used [0x0000000083200000,0x00000000839855b0,0x0000000086780000)
|
||||
Metaspace used 28489K, capacity 29978K, committed 30256K, reserved 1075200K
|
||||
class space used 3782K, capacity 4093K, committed 4144K, reserved 1048576K
|
||||
}
|
||||
Event: 6.395 GC heap before
|
||||
{Heap before GC invocations=8 (full 1):
|
||||
PSYoungGen total 112640K, used 72337K [0x00000000d6600000, 0x00000000dde80000, 0x0000000100000000)
|
||||
eden space 103936K, 61% used [0x00000000d6600000,0x00000000da429c58,0x00000000dcb80000)
|
||||
from space 8704K, 99% used [0x00000000dd580000,0x00000000dddfa938,0x00000000dde00000)
|
||||
to space 9728K, 0% used [0x00000000dcb80000,0x00000000dcb80000,0x00000000dd500000)
|
||||
ParOldGen total 54784K, used 7701K [0x0000000083200000, 0x0000000086780000, 0x00000000d6600000)
|
||||
object space 54784K, 14% used [0x0000000083200000,0x00000000839855b0,0x0000000086780000)
|
||||
Metaspace used 33467K, capacity 35388K, committed 35496K, reserved 1079296K
|
||||
class space used 4429K, capacity 4772K, committed 4784K, reserved 1048576K
|
||||
Event: 6.406 GC heap after
|
||||
Heap after GC invocations=8 (full 1):
|
||||
PSYoungGen total 113664K, used 9708K [0x00000000d6600000, 0x00000000dde80000, 0x0000000100000000)
|
||||
eden space 103936K, 0% used [0x00000000d6600000,0x00000000d6600000,0x00000000dcb80000)
|
||||
from space 9728K, 99% used [0x00000000dcb80000,0x00000000dd4fb3f8,0x00000000dd500000)
|
||||
to space 8704K, 0% used [0x00000000dd580000,0x00000000dd580000,0x00000000dde00000)
|
||||
ParOldGen total 54784K, used 8197K [0x0000000083200000, 0x0000000086780000, 0x00000000d6600000)
|
||||
object space 54784K, 14% used [0x0000000083200000,0x0000000083a01718,0x0000000086780000)
|
||||
Metaspace used 33467K, capacity 35388K, committed 35496K, reserved 1079296K
|
||||
class space used 4429K, capacity 4772K, committed 4784K, reserved 1048576K
|
||||
}
|
||||
Event: 6.406 GC heap before
|
||||
{Heap before GC invocations=9 (full 2):
|
||||
PSYoungGen total 113664K, used 9708K [0x00000000d6600000, 0x00000000dde80000, 0x0000000100000000)
|
||||
eden space 103936K, 0% used [0x00000000d6600000,0x00000000d6600000,0x00000000dcb80000)
|
||||
from space 9728K, 99% used [0x00000000dcb80000,0x00000000dd4fb3f8,0x00000000dd500000)
|
||||
to space 8704K, 0% used [0x00000000dd580000,0x00000000dd580000,0x00000000dde00000)
|
||||
ParOldGen total 54784K, used 8197K [0x0000000083200000, 0x0000000086780000, 0x00000000d6600000)
|
||||
object space 54784K, 14% used [0x0000000083200000,0x0000000083a01718,0x0000000086780000)
|
||||
Metaspace used 33467K, capacity 35388K, committed 35496K, reserved 1079296K
|
||||
class space used 4429K, capacity 4772K, committed 4784K, reserved 1048576K
|
||||
Event: 6.489 GC heap after
|
||||
Heap after GC invocations=9 (full 2):
|
||||
PSYoungGen total 113664K, used 0K [0x00000000d6600000, 0x00000000dde80000, 0x0000000100000000)
|
||||
eden space 103936K, 0% used [0x00000000d6600000,0x00000000d6600000,0x00000000dcb80000)
|
||||
from space 9728K, 0% used [0x00000000dcb80000,0x00000000dcb80000,0x00000000dd500000)
|
||||
to space 8704K, 0% used [0x00000000dd580000,0x00000000dd580000,0x00000000dde00000)
|
||||
ParOldGen total 89088K, used 14457K [0x0000000083200000, 0x0000000088900000, 0x00000000d6600000)
|
||||
object space 89088K, 16% used [0x0000000083200000,0x000000008401e648,0x0000000088900000)
|
||||
Metaspace used 33467K, capacity 35388K, committed 35496K, reserved 1079296K
|
||||
class space used 4429K, capacity 4772K, committed 4784K, reserved 1048576K
|
||||
}
|
||||
|
||||
Deoptimization events (0 events):
|
||||
No events
|
||||
|
||||
Classes redefined (0 events):
|
||||
No events
|
||||
|
||||
Internal exceptions (10 events):
|
||||
Event: 7.606 Thread 0x0000017b86adf800 Exception <a 'java/lang/ArrayIndexOutOfBoundsException'> (0x00000000dc9a7778) thrown at [C:\jenkins\workspace\8-2-build-windows-amd64-cygwin\jdk8u261\295\hotspot\src\share\vm\runtime\sharedRuntime.cpp, line 605]
|
||||
Event: 7.606 Thread 0x0000017b86adf800 Exception <a 'java/lang/ArrayIndexOutOfBoundsException'> (0x00000000dc9a8e70) thrown at [C:\jenkins\workspace\8-2-build-windows-amd64-cygwin\jdk8u261\295\hotspot\src\share\vm\runtime\sharedRuntime.cpp, line 605]
|
||||
Event: 7.606 Thread 0x0000017b86adf800 Exception <a 'java/lang/ArrayIndexOutOfBoundsException'> (0x00000000dc9aafe8) thrown at [C:\jenkins\workspace\8-2-build-windows-amd64-cygwin\jdk8u261\295\hotspot\src\share\vm\runtime\sharedRuntime.cpp, line 605]
|
||||
Event: 7.606 Thread 0x0000017b86adf800 Exception <a 'java/lang/ArrayIndexOutOfBoundsException'> (0x00000000dc9acd68) thrown at [C:\jenkins\workspace\8-2-build-windows-amd64-cygwin\jdk8u261\295\hotspot\src\share\vm\runtime\sharedRuntime.cpp, line 605]
|
||||
Event: 7.606 Thread 0x0000017b86adf800 Exception <a 'java/lang/ArrayIndexOutOfBoundsException'> (0x00000000dc9ae650) thrown at [C:\jenkins\workspace\8-2-build-windows-amd64-cygwin\jdk8u261\295\hotspot\src\share\vm\runtime\sharedRuntime.cpp, line 605]
|
||||
Event: 7.606 Thread 0x0000017b86adf800 Exception <a 'java/lang/ArrayIndexOutOfBoundsException'> (0x00000000dc9b0120) thrown at [C:\jenkins\workspace\8-2-build-windows-amd64-cygwin\jdk8u261\295\hotspot\src\share\vm\runtime\sharedRuntime.cpp, line 605]
|
||||
Event: 7.606 Thread 0x0000017b86adf800 Exception <a 'java/lang/ArrayIndexOutOfBoundsException'> (0x00000000dc9b15c0) thrown at [C:\jenkins\workspace\8-2-build-windows-amd64-cygwin\jdk8u261\295\hotspot\src\share\vm\runtime\sharedRuntime.cpp, line 605]
|
||||
Event: 7.606 Thread 0x0000017b86adf800 Exception <a 'java/lang/ArrayIndexOutOfBoundsException'> (0x00000000dc9b2500) thrown at [C:\jenkins\workspace\8-2-build-windows-amd64-cygwin\jdk8u261\295\hotspot\src\share\vm\runtime\sharedRuntime.cpp, line 605]
|
||||
Event: 7.611 Thread 0x0000017b86adf800 Exception <a 'java/lang/ArrayIndexOutOfBoundsException'> (0x00000000dca50620) thrown at [C:\jenkins\workspace\8-2-build-windows-amd64-cygwin\jdk8u261\295\hotspot\src\share\vm\runtime\sharedRuntime.cpp, line 605]
|
||||
Event: 7.611 Thread 0x0000017b86adf800 Exception <a 'java/lang/ArrayIndexOutOfBoundsException'> (0x00000000dca517d0) thrown at [C:\jenkins\workspace\8-2-build-windows-amd64-cygwin\jdk8u261\295\hotspot\src\share\vm\runtime\sharedRuntime.cpp, line 605]
|
||||
|
||||
Events (10 events):
|
||||
Event: 7.612 Thread 0x0000017b86adf800 DEOPT PACKING pc=0x0000017b889be6dc sp=0x000000080ddfdda0
|
||||
Event: 7.612 Thread 0x0000017b86adf800 DEOPT UNPACKING pc=0x0000017b88657898 sp=0x000000080ddfdb58 mode 1
|
||||
Event: 7.612 Thread 0x0000017b86adf800 DEOPT PACKING pc=0x0000017b889be6dc sp=0x000000080ddfde10
|
||||
Event: 7.612 Thread 0x0000017b86adf800 DEOPT UNPACKING pc=0x0000017b88657898 sp=0x000000080ddfdbc8 mode 1
|
||||
Event: 7.612 Thread 0x0000017b86adf800 DEOPT PACKING pc=0x0000017b889be6dc sp=0x000000080ddfde10
|
||||
Event: 7.612 Thread 0x0000017b86adf800 DEOPT UNPACKING pc=0x0000017b88657898 sp=0x000000080ddfdbc8 mode 1
|
||||
Event: 7.612 Thread 0x0000017b86adf800 DEOPT PACKING pc=0x0000017b889be6dc sp=0x000000080ddfde10
|
||||
Event: 7.612 Thread 0x0000017b86adf800 DEOPT UNPACKING pc=0x0000017b88657898 sp=0x000000080ddfdbc8 mode 1
|
||||
Event: 7.612 Thread 0x0000017b86adf800 DEOPT PACKING pc=0x0000017b8894f11c sp=0x000000080ddfdda0
|
||||
Event: 7.612 Thread 0x0000017b86adf800 DEOPT UNPACKING pc=0x0000017b88657898 sp=0x000000080ddfdb58 mode 1
|
||||
|
||||
|
||||
Dynamic libraries:
|
||||
0x00007ff7fa630000 - 0x00007ff7fa677000 C:\Program Files\Java\jdk1.8.0_261\bin\java.exe
|
||||
0x00007ffd315a0000 - 0x00007ffd31790000 C:\Windows\SYSTEM32\ntdll.dll
|
||||
0x00007ffd30770000 - 0x00007ffd30822000 C:\Windows\System32\KERNEL32.DLL
|
||||
0x00007ffd2e9a0000 - 0x00007ffd2ec45000 C:\Windows\System32\KERNELBASE.dll
|
||||
0x00007ffd2fd30000 - 0x00007ffd2fdd3000 C:\Windows\System32\ADVAPI32.dll
|
||||
0x00007ffd2f950000 - 0x00007ffd2f9ee000 C:\Windows\System32\msvcrt.dll
|
||||
0x00007ffd2f650000 - 0x00007ffd2f6e7000 C:\Windows\System32\sechost.dll
|
||||
0x00007ffd31160000 - 0x00007ffd3127f000 C:\Windows\System32\RPCRT4.dll
|
||||
0x00007ffd2f7a0000 - 0x00007ffd2f934000 C:\Windows\System32\USER32.dll
|
||||
0x00007ffd2eda0000 - 0x00007ffd2edc1000 C:\Windows\System32\win32u.dll
|
||||
0x00007ffd308d0000 - 0x00007ffd308f6000 C:\Windows\System32\GDI32.dll
|
||||
0x00007ffd2e510000 - 0x00007ffd2e6a8000 C:\Windows\System32\gdi32full.dll
|
||||
0x00007ffd2ec50000 - 0x00007ffd2ecee000 C:\Windows\System32\msvcp_win.dll
|
||||
0x00007ffd2edd0000 - 0x00007ffd2eeca000 C:\Windows\System32\ucrtbase.dll
|
||||
0x00007ffd18d40000 - 0x00007ffd18fc4000 C:\Windows\WinSxS\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.18362.1500_none_9e79be6de462295c\COMCTL32.dll
|
||||
0x00007ffd2f9f0000 - 0x00007ffd2fd26000 C:\Windows\System32\combase.dll
|
||||
0x00007ffd2e910000 - 0x00007ffd2e991000 C:\Windows\System32\bcryptPrimitives.dll
|
||||
0x00007ffd31120000 - 0x00007ffd3114e000 C:\Windows\System32\IMM32.DLL
|
||||
0x00007ffd17310000 - 0x00007ffd17325000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\vcruntime140.dll
|
||||
0x00007ffd128b0000 - 0x00007ffd1294b000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\msvcp140.dll
|
||||
0x0000000070c80000 - 0x00000000714ec000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\server\jvm.dll
|
||||
0x00007ffd30e20000 - 0x00007ffd30e28000 C:\Windows\System32\PSAPI.DLL
|
||||
0x00007ffd2e030000 - 0x00007ffd2e03a000 C:\Windows\SYSTEM32\VERSION.dll
|
||||
0x00007ffd13d40000 - 0x00007ffd13d49000 C:\Windows\SYSTEM32\WSOCK32.dll
|
||||
0x00007ffd30700000 - 0x00007ffd3076f000 C:\Windows\System32\WS2_32.dll
|
||||
0x00007ffd28910000 - 0x00007ffd28934000 C:\Windows\SYSTEM32\WINMM.dll
|
||||
0x00007ffd288e0000 - 0x00007ffd2890d000 C:\Windows\SYSTEM32\winmmbase.dll
|
||||
0x00007ffd2e730000 - 0x00007ffd2e77a000 C:\Windows\System32\cfgmgr32.dll
|
||||
0x00007ffd2e4d0000 - 0x00007ffd2e4e1000 C:\Windows\System32\kernel.appcore.dll
|
||||
0x00007ffd243d0000 - 0x00007ffd243e0000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\verify.dll
|
||||
0x00007ffd16d50000 - 0x00007ffd16d7b000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\java.dll
|
||||
0x00007ffd14080000 - 0x00007ffd140b6000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\jdwp.dll
|
||||
0x00007ffd1b930000 - 0x00007ffd1b939000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\npt.dll
|
||||
0x00007ffd05f80000 - 0x00007ffd05fb2000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\instrument.dll
|
||||
0x00007ffd16d30000 - 0x00007ffd16d48000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\zip.dll
|
||||
0x00007ffd2ff40000 - 0x00007ffd30628000 C:\Windows\System32\SHELL32.dll
|
||||
0x00007ffd2f6f0000 - 0x00007ffd2f797000 C:\Windows\System32\shcore.dll
|
||||
0x00007ffd2eed0000 - 0x00007ffd2f64b000 C:\Windows\System32\windows.storage.dll
|
||||
0x00007ffd2e4b0000 - 0x00007ffd2e4ce000 C:\Windows\System32\profapi.dll
|
||||
0x00007ffd2e460000 - 0x00007ffd2e4aa000 C:\Windows\System32\powrprof.dll
|
||||
0x00007ffd2e450000 - 0x00007ffd2e460000 C:\Windows\System32\UMPDC.dll
|
||||
0x00007ffd310c0000 - 0x00007ffd31112000 C:\Windows\System32\shlwapi.dll
|
||||
0x00007ffd2e710000 - 0x00007ffd2e727000 C:\Windows\System32\cryptsp.dll
|
||||
0x00007ffd17a40000 - 0x00007ffd17a4a000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\dt_socket.dll
|
||||
0x00007ffd2dc20000 - 0x00007ffd2dc87000 C:\Windows\system32\mswsock.dll
|
||||
0x00007ffd166e0000 - 0x00007ffd166fc000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\net.dll
|
||||
0x00007ffd11d20000 - 0x00007ffd11d53000 C:\Program Files (x86)\Sangfor\SSL\ClientComponent\SangforNspX64.dll
|
||||
0x00007ffd2fde0000 - 0x00007ffd2ff37000 C:\Windows\System32\ole32.dll
|
||||
0x00007ffd30630000 - 0x00007ffd306f5000 C:\Windows\System32\OLEAUT32.dll
|
||||
0x00007ffd2d970000 - 0x00007ffd2da3b000 C:\Windows\SYSTEM32\DNSAPI.dll
|
||||
0x00007ffd2f940000 - 0x00007ffd2f948000 C:\Windows\System32\NSI.dll
|
||||
0x00007ffd2d930000 - 0x00007ffd2d96a000 C:\Windows\SYSTEM32\IPHLPAPI.DLL
|
||||
0x00007ffd1b4a0000 - 0x00007ffd1b4aa000 C:\Windows\System32\rasadhlp.dll
|
||||
0x00007ffd1e3d0000 - 0x00007ffd1e447000 C:\Windows\System32\fwpuclnt.dll
|
||||
0x00007ffd2e780000 - 0x00007ffd2e7a6000 C:\Windows\System32\bcrypt.dll
|
||||
0x00007ffd12a30000 - 0x00007ffd12a3d000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\management.dll
|
||||
0x00007ffd15830000 - 0x00007ffd15843000 C:\Program Files\Java\jdk1.8.0_261\jre\bin\nio.dll
|
||||
0x00007ffd2d7a0000 - 0x00007ffd2d7d3000 C:\Windows\system32\rsaenh.dll
|
||||
0x00007ffd2e370000 - 0x00007ffd2e395000 C:\Windows\SYSTEM32\USERENV.dll
|
||||
0x00007ffd2ddf0000 - 0x00007ffd2ddfc000 C:\Windows\SYSTEM32\CRYPTBASE.dll
|
||||
0x00007ffd21280000 - 0x00007ffd21296000 C:\Windows\SYSTEM32\dhcpcsvc6.DLL
|
||||
0x00007ffd21330000 - 0x00007ffd2134c000 C:\Windows\SYSTEM32\dhcpcsvc.DLL
|
||||
0x00007ffd10f50000 - 0x00007ffd10f66000 C:\Windows\system32\napinsp.dll
|
||||
0x00007ffd0fac0000 - 0x00007ffd0fada000 C:\Windows\system32\pnrpnsp.dll
|
||||
0x00007ffd11d10000 - 0x00007ffd11d1e000 C:\Windows\System32\winrnr.dll
|
||||
0x00007ffd275e0000 - 0x00007ffd275fc000 C:\Windows\system32\NLAapi.dll
|
||||
0x00007ffd0f5b0000 - 0x00007ffd0f5c5000 C:\Windows\system32\wshbth.dll
|
||||
0x00007ffd29c70000 - 0x00007ffd29e64000 C:\Windows\SYSTEM32\dbghelp.dll
|
||||
|
||||
VM Arguments:
|
||||
jvm_args: -agentlib:jdwp=transport=dt_socket,address=127.0.0.1:50843,suspend=y,server=n -XX:TieredStopAtLevel=1 -Xverify:none -Dspring.output.ansi.enabled=always -javaagent:C:\Users\yyf\AppData\Local\JetBrains\IntelliJIdea2021.1\captureAgent\debugger-agent.jar -Dcom.sun.management.jmxremote -Dspring.jmx.enabled=true -Dspring.liveBeansView.mbeanDomain -Dspring.application.admin.enabled=true -Dfile.encoding=UTF-8
|
||||
java_command: com.rehome.weather.WeatherApplication
|
||||
java_class_path (initial): C:\Program Files\Java\jdk1.8.0_261\jre\lib\charsets.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\deploy.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\access-bridge-64.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\cldrdata.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\dnsns.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\jaccess.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\jfxrt.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\localedata.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\nashorn.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\sunec.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\sunjce_provider.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\sunmscapi.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\sunpkcs11.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\ext\zipfs.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\javaws.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\jce.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\jfr.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\jfxswt.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\jsse.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\management-agent.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\plugin.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\resources.jar;C:\Program Files\Java\jdk1.8.0_261\jre\lib\rt.jar;D:\svn\WeatherService\weather\target\classes;D:\.m2\repos\org\springframework\boot\spring-boot-starter-web\2.4.5\spring-boot-starter-web-2.4.5.jar;D:\.m2\repos\org\springframework\boot\spring-boot-starter\2.4.5\spring-boot-starter-2.4.5.jar;D:\.m2\repos\org\springframework\boot\spring-boot\2.4.5\spring-boot-2.4.5.jar;D:\.m2\repos\org\springframework\boot\spring-boot-autoconfigure\2.4.5\spring-boot-autoconfigure-2.4.5.jar;D:\.m2\repos\org\springframework\boot\spring-boot-starter-logging\2.4.5\spring-boot-starter-logging-2.4.5.jar;D:\.m2\repos\ch\qos\logback\logback-classic\1.2.3\logback-classic-1.2.3.jar;D:\.m2\repos\ch\qos\logback\logback-co
|
||||
Launcher Type: SUN_STANDARD
|
||||
|
||||
Environment Variables:
|
||||
JAVA_HOME=C:\Program Files\Java\jdk1.8.0_261
|
||||
PATH=C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\app\yyf\product\11.2.0\client_1\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\dotnet\;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files (x86)\VisualSVN\bin;"C:\Program Files\Java\jdk1.8.0_261\bin;C:\Program Files\Java\jdk1.8.0_261\jre\bin";%MYSQL_HOME%\bin;%CATALINA_HOME%\lib;%CATALINA_HOME%\lib\servlet-api.jar;%CATALINA_HOME%\lib\jsp-api.jar;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Program Files\nodejs\;C:\ProgramData\chocolatey\bin;d:\Program Files\Git\cmd;C:\Program Files\TortoiseSVN\bin;C:\Users\yyf\AppData\Local\Android\Sdk\platform-tools;C:\Program Files\Redis\;C:\Program Files\MySQL\MySQL Shell 8.0\bin\;C:\Program Files\Java\jdk1.8.0_261\bin;C:\Users\yyf\AppData\Local\Programs\Microsoft VS Code\bin;D:\DevEco Studio\bin;;E:\IntelliJ IDEA 2020.3\bin;;C:\Users\yyf\AppData\Roaming\npm
|
||||
USERNAME=admin
|
||||
OS=Windows_NT
|
||||
PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 142 Stepping 12, GenuineIntel
|
||||
|
||||
|
||||
|
||||
--------------- S Y S T E M ---------------
|
||||
|
||||
OS: Windows 10.0 , 64 bit Build 18362 (10.0.18362.1500)
|
||||
|
||||
CPU:total 8 (initial active 8) (4 cores per cpu, 2 threads per core) family 6 model 142 stepping 12, cmov, cx8, fxsr, mmx, sse, sse2, sse3, ssse3, sse4.1, sse4.2, popcnt, avx, avx2, aes, clmul, erms, 3dnowpref, lzcnt, ht, tsc, tscinvbit, bmi1, bmi2, adx
|
||||
|
||||
Memory: 4k page, physical 8180216k(44692k free), swap 16568824k(2108k free)
|
||||
|
||||
vm_info: Java HotSpot(TM) 64-Bit Server VM (25.261-b12) for windows-amd64 JRE (1.8.0_261-b12), built on Jun 18 2020 06:56:32 by "" with unknown MS VC++:1916
|
||||
|
||||
time: Tue May 11 16:45:33 2021
|
||||
timezone: ?D1¨²¡À¨º¡Á?¨º¡À??
|
||||
elapsed time: 7 seconds (0d 0h 0m 7s)
|
||||
|
||||
@ -0,0 +1,310 @@
|
||||
#!/bin/sh
|
||||
# ----------------------------------------------------------------------------
|
||||
# Licensed to the Apache Software Foundation (ASF) under one
|
||||
# or more contributor license agreements. See the NOTICE file
|
||||
# distributed with this work for additional information
|
||||
# regarding copyright ownership. The ASF licenses this file
|
||||
# to you 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
|
||||
#
|
||||
# https://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.
|
||||
# ----------------------------------------------------------------------------
|
||||
|
||||
# ----------------------------------------------------------------------------
|
||||
# Maven Start Up Batch script
|
||||
#
|
||||
# Required ENV vars:
|
||||
# ------------------
|
||||
# JAVA_HOME - location of a JDK home dir
|
||||
#
|
||||
# Optional ENV vars
|
||||
# -----------------
|
||||
# M2_HOME - location of maven2's installed home dir
|
||||
# MAVEN_OPTS - parameters passed to the Java VM when running Maven
|
||||
# e.g. to debug Maven itself, use
|
||||
# set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
|
||||
# MAVEN_SKIP_RC - flag to disable loading of mavenrc files
|
||||
# ----------------------------------------------------------------------------
|
||||
|
||||
if [ -z "$MAVEN_SKIP_RC" ] ; then
|
||||
|
||||
if [ -f /etc/mavenrc ] ; then
|
||||
. /etc/mavenrc
|
||||
fi
|
||||
|
||||
if [ -f "$HOME/.mavenrc" ] ; then
|
||||
. "$HOME/.mavenrc"
|
||||
fi
|
||||
|
||||
fi
|
||||
|
||||
# OS specific support. $var _must_ be set to either true or false.
|
||||
cygwin=false;
|
||||
darwin=false;
|
||||
mingw=false
|
||||
case "`uname`" in
|
||||
CYGWIN*) cygwin=true ;;
|
||||
MINGW*) mingw=true;;
|
||||
Darwin*) darwin=true
|
||||
# Use /usr/libexec/java_home if available, otherwise fall back to /Library/Java/Home
|
||||
# See https://developer.apple.com/library/mac/qa/qa1170/_index.html
|
||||
if [ -z "$JAVA_HOME" ]; then
|
||||
if [ -x "/usr/libexec/java_home" ]; then
|
||||
export JAVA_HOME="`/usr/libexec/java_home`"
|
||||
else
|
||||
export JAVA_HOME="/Library/Java/Home"
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -z "$JAVA_HOME" ] ; then
|
||||
if [ -r /etc/gentoo-release ] ; then
|
||||
JAVA_HOME=`java-config --jre-home`
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -z "$M2_HOME" ] ; then
|
||||
## resolve links - $0 may be a link to maven's home
|
||||
PRG="$0"
|
||||
|
||||
# need this for relative symlinks
|
||||
while [ -h "$PRG" ] ; do
|
||||
ls=`ls -ld "$PRG"`
|
||||
link=`expr "$ls" : '.*-> \(.*\)$'`
|
||||
if expr "$link" : '/.*' > /dev/null; then
|
||||
PRG="$link"
|
||||
else
|
||||
PRG="`dirname "$PRG"`/$link"
|
||||
fi
|
||||
done
|
||||
|
||||
saveddir=`pwd`
|
||||
|
||||
M2_HOME=`dirname "$PRG"`/..
|
||||
|
||||
# make it fully qualified
|
||||
M2_HOME=`cd "$M2_HOME" && pwd`
|
||||
|
||||
cd "$saveddir"
|
||||
# echo Using m2 at $M2_HOME
|
||||
fi
|
||||
|
||||
# For Cygwin, ensure paths are in UNIX format before anything is touched
|
||||
if $cygwin ; then
|
||||
[ -n "$M2_HOME" ] &&
|
||||
M2_HOME=`cygpath --unix "$M2_HOME"`
|
||||
[ -n "$JAVA_HOME" ] &&
|
||||
JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
|
||||
[ -n "$CLASSPATH" ] &&
|
||||
CLASSPATH=`cygpath --path --unix "$CLASSPATH"`
|
||||
fi
|
||||
|
||||
# For Mingw, ensure paths are in UNIX format before anything is touched
|
||||
if $mingw ; then
|
||||
[ -n "$M2_HOME" ] &&
|
||||
M2_HOME="`(cd "$M2_HOME"; pwd)`"
|
||||
[ -n "$JAVA_HOME" ] &&
|
||||
JAVA_HOME="`(cd "$JAVA_HOME"; pwd)`"
|
||||
fi
|
||||
|
||||
if [ -z "$JAVA_HOME" ]; then
|
||||
javaExecutable="`which javac`"
|
||||
if [ -n "$javaExecutable" ] && ! [ "`expr \"$javaExecutable\" : '\([^ ]*\)'`" = "no" ]; then
|
||||
# readlink(1) is not available as standard on Solaris 10.
|
||||
readLink=`which readlink`
|
||||
if [ ! `expr "$readLink" : '\([^ ]*\)'` = "no" ]; then
|
||||
if $darwin ; then
|
||||
javaHome="`dirname \"$javaExecutable\"`"
|
||||
javaExecutable="`cd \"$javaHome\" && pwd -P`/javac"
|
||||
else
|
||||
javaExecutable="`readlink -f \"$javaExecutable\"`"
|
||||
fi
|
||||
javaHome="`dirname \"$javaExecutable\"`"
|
||||
javaHome=`expr "$javaHome" : '\(.*\)/bin'`
|
||||
JAVA_HOME="$javaHome"
|
||||
export JAVA_HOME
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -z "$JAVACMD" ] ; then
|
||||
if [ -n "$JAVA_HOME" ] ; then
|
||||
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
||||
# IBM's JDK on AIX uses strange locations for the executables
|
||||
JAVACMD="$JAVA_HOME/jre/sh/java"
|
||||
else
|
||||
JAVACMD="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
else
|
||||
JAVACMD="`which java`"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ ! -x "$JAVACMD" ] ; then
|
||||
echo "Error: JAVA_HOME is not defined correctly." >&2
|
||||
echo " We cannot execute $JAVACMD" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "$JAVA_HOME" ] ; then
|
||||
echo "Warning: JAVA_HOME environment variable is not set."
|
||||
fi
|
||||
|
||||
CLASSWORLDS_LAUNCHER=org.codehaus.plexus.classworlds.launcher.Launcher
|
||||
|
||||
# traverses directory structure from process work directory to filesystem root
|
||||
# first directory with .mvn subdirectory is considered project base directory
|
||||
find_maven_basedir() {
|
||||
|
||||
if [ -z "$1" ]
|
||||
then
|
||||
echo "Path not specified to find_maven_basedir"
|
||||
return 1
|
||||
fi
|
||||
|
||||
basedir="$1"
|
||||
wdir="$1"
|
||||
while [ "$wdir" != '/' ] ; do
|
||||
if [ -d "$wdir"/.mvn ] ; then
|
||||
basedir=$wdir
|
||||
break
|
||||
fi
|
||||
# workaround for JBEAP-8937 (on Solaris 10/Sparc)
|
||||
if [ -d "${wdir}" ]; then
|
||||
wdir=`cd "$wdir/.."; pwd`
|
||||
fi
|
||||
# end of workaround
|
||||
done
|
||||
echo "${basedir}"
|
||||
}
|
||||
|
||||
# concatenates all lines of a file
|
||||
concat_lines() {
|
||||
if [ -f "$1" ]; then
|
||||
echo "$(tr -s '\n' ' ' < "$1")"
|
||||
fi
|
||||
}
|
||||
|
||||
BASE_DIR=`find_maven_basedir "$(pwd)"`
|
||||
if [ -z "$BASE_DIR" ]; then
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
##########################################################################################
|
||||
# Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
|
||||
# This allows using the maven wrapper in projects that prohibit checking in binary data.
|
||||
##########################################################################################
|
||||
if [ -r "$BASE_DIR/.mvn/wrapper/maven-wrapper.jar" ]; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Found .mvn/wrapper/maven-wrapper.jar"
|
||||
fi
|
||||
else
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Couldn't find .mvn/wrapper/maven-wrapper.jar, downloading it ..."
|
||||
fi
|
||||
if [ -n "$MVNW_REPOURL" ]; then
|
||||
jarUrl="$MVNW_REPOURL/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar"
|
||||
else
|
||||
jarUrl="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar"
|
||||
fi
|
||||
while IFS="=" read key value; do
|
||||
case "$key" in (wrapperUrl) jarUrl="$value"; break ;;
|
||||
esac
|
||||
done < "$BASE_DIR/.mvn/wrapper/maven-wrapper.properties"
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Downloading from: $jarUrl"
|
||||
fi
|
||||
wrapperJarPath="$BASE_DIR/.mvn/wrapper/maven-wrapper.jar"
|
||||
if $cygwin; then
|
||||
wrapperJarPath=`cygpath --path --windows "$wrapperJarPath"`
|
||||
fi
|
||||
|
||||
if command -v wget > /dev/null; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Found wget ... using wget"
|
||||
fi
|
||||
if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
|
||||
wget "$jarUrl" -O "$wrapperJarPath"
|
||||
else
|
||||
wget --http-user=$MVNW_USERNAME --http-password=$MVNW_PASSWORD "$jarUrl" -O "$wrapperJarPath"
|
||||
fi
|
||||
elif command -v curl > /dev/null; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Found curl ... using curl"
|
||||
fi
|
||||
if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
|
||||
curl -o "$wrapperJarPath" "$jarUrl" -f
|
||||
else
|
||||
curl --user $MVNW_USERNAME:$MVNW_PASSWORD -o "$wrapperJarPath" "$jarUrl" -f
|
||||
fi
|
||||
|
||||
else
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Falling back to using Java to download"
|
||||
fi
|
||||
javaClass="$BASE_DIR/.mvn/wrapper/MavenWrapperDownloader.java"
|
||||
# For Cygwin, switch paths to Windows format before running javac
|
||||
if $cygwin; then
|
||||
javaClass=`cygpath --path --windows "$javaClass"`
|
||||
fi
|
||||
if [ -e "$javaClass" ]; then
|
||||
if [ ! -e "$BASE_DIR/.mvn/wrapper/MavenWrapperDownloader.class" ]; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo " - Compiling MavenWrapperDownloader.java ..."
|
||||
fi
|
||||
# Compiling the Java class
|
||||
("$JAVA_HOME/bin/javac" "$javaClass")
|
||||
fi
|
||||
if [ -e "$BASE_DIR/.mvn/wrapper/MavenWrapperDownloader.class" ]; then
|
||||
# Running the downloader
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo " - Running MavenWrapperDownloader.java ..."
|
||||
fi
|
||||
("$JAVA_HOME/bin/java" -cp .mvn/wrapper MavenWrapperDownloader "$MAVEN_PROJECTBASEDIR")
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
##########################################################################################
|
||||
# End of extension
|
||||
##########################################################################################
|
||||
|
||||
export MAVEN_PROJECTBASEDIR=${MAVEN_BASEDIR:-"$BASE_DIR"}
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo $MAVEN_PROJECTBASEDIR
|
||||
fi
|
||||
MAVEN_OPTS="$(concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config") $MAVEN_OPTS"
|
||||
|
||||
# For Cygwin, switch paths to Windows format before running java
|
||||
if $cygwin; then
|
||||
[ -n "$M2_HOME" ] &&
|
||||
M2_HOME=`cygpath --path --windows "$M2_HOME"`
|
||||
[ -n "$JAVA_HOME" ] &&
|
||||
JAVA_HOME=`cygpath --path --windows "$JAVA_HOME"`
|
||||
[ -n "$CLASSPATH" ] &&
|
||||
CLASSPATH=`cygpath --path --windows "$CLASSPATH"`
|
||||
[ -n "$MAVEN_PROJECTBASEDIR" ] &&
|
||||
MAVEN_PROJECTBASEDIR=`cygpath --path --windows "$MAVEN_PROJECTBASEDIR"`
|
||||
fi
|
||||
|
||||
# Provide a "standardized" way to retrieve the CLI args that will
|
||||
# work with both Windows and non-Windows executions.
|
||||
MAVEN_CMD_LINE_ARGS="$MAVEN_CONFIG $@"
|
||||
export MAVEN_CMD_LINE_ARGS
|
||||
|
||||
WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
|
||||
|
||||
exec "$JAVACMD" \
|
||||
$MAVEN_OPTS \
|
||||
-classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \
|
||||
"-Dmaven.home=${M2_HOME}" "-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \
|
||||
${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@"
|
||||
@ -0,0 +1,182 @@
|
||||
@REM ----------------------------------------------------------------------------
|
||||
@REM Licensed to the Apache Software Foundation (ASF) under one
|
||||
@REM or more contributor license agreements. See the NOTICE file
|
||||
@REM distributed with this work for additional information
|
||||
@REM regarding copyright ownership. The ASF licenses this file
|
||||
@REM to you under the Apache License, Version 2.0 (the
|
||||
@REM "License"); you may not use this file except in compliance
|
||||
@REM with the License. You may obtain a copy of the License at
|
||||
@REM
|
||||
@REM https://www.apache.org/licenses/LICENSE-2.0
|
||||
@REM
|
||||
@REM Unless required by applicable law or agreed to in writing,
|
||||
@REM software distributed under the License is distributed on an
|
||||
@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
@REM KIND, either express or implied. See the License for the
|
||||
@REM specific language governing permissions and limitations
|
||||
@REM under the License.
|
||||
@REM ----------------------------------------------------------------------------
|
||||
|
||||
@REM ----------------------------------------------------------------------------
|
||||
@REM Maven Start Up Batch script
|
||||
@REM
|
||||
@REM Required ENV vars:
|
||||
@REM JAVA_HOME - location of a JDK home dir
|
||||
@REM
|
||||
@REM Optional ENV vars
|
||||
@REM M2_HOME - location of maven2's installed home dir
|
||||
@REM MAVEN_BATCH_ECHO - set to 'on' to enable the echoing of the batch commands
|
||||
@REM MAVEN_BATCH_PAUSE - set to 'on' to wait for a keystroke before ending
|
||||
@REM MAVEN_OPTS - parameters passed to the Java VM when running Maven
|
||||
@REM e.g. to debug Maven itself, use
|
||||
@REM set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
|
||||
@REM MAVEN_SKIP_RC - flag to disable loading of mavenrc files
|
||||
@REM ----------------------------------------------------------------------------
|
||||
|
||||
@REM Begin all REM lines with '@' in case MAVEN_BATCH_ECHO is 'on'
|
||||
@echo off
|
||||
@REM set title of command window
|
||||
title %0
|
||||
@REM enable echoing by setting MAVEN_BATCH_ECHO to 'on'
|
||||
@if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO%
|
||||
|
||||
@REM set %HOME% to equivalent of $HOME
|
||||
if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%")
|
||||
|
||||
@REM Execute a user defined script before this one
|
||||
if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre
|
||||
@REM check for pre script, once with legacy .bat ending and once with .cmd ending
|
||||
if exist "%HOME%\mavenrc_pre.bat" call "%HOME%\mavenrc_pre.bat"
|
||||
if exist "%HOME%\mavenrc_pre.cmd" call "%HOME%\mavenrc_pre.cmd"
|
||||
:skipRcPre
|
||||
|
||||
@setlocal
|
||||
|
||||
set ERROR_CODE=0
|
||||
|
||||
@REM To isolate internal variables from possible post scripts, we use another setlocal
|
||||
@setlocal
|
||||
|
||||
@REM ==== START VALIDATION ====
|
||||
if not "%JAVA_HOME%" == "" goto OkJHome
|
||||
|
||||
echo.
|
||||
echo Error: JAVA_HOME not found in your environment. >&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the >&2
|
||||
echo location of your Java installation. >&2
|
||||
echo.
|
||||
goto error
|
||||
|
||||
:OkJHome
|
||||
if exist "%JAVA_HOME%\bin\java.exe" goto init
|
||||
|
||||
echo.
|
||||
echo Error: JAVA_HOME is set to an invalid directory. >&2
|
||||
echo JAVA_HOME = "%JAVA_HOME%" >&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the >&2
|
||||
echo location of your Java installation. >&2
|
||||
echo.
|
||||
goto error
|
||||
|
||||
@REM ==== END VALIDATION ====
|
||||
|
||||
:init
|
||||
|
||||
@REM Find the project base dir, i.e. the directory that contains the folder ".mvn".
|
||||
@REM Fallback to current working directory if not found.
|
||||
|
||||
set MAVEN_PROJECTBASEDIR=%MAVEN_BASEDIR%
|
||||
IF NOT "%MAVEN_PROJECTBASEDIR%"=="" goto endDetectBaseDir
|
||||
|
||||
set EXEC_DIR=%CD%
|
||||
set WDIR=%EXEC_DIR%
|
||||
:findBaseDir
|
||||
IF EXIST "%WDIR%"\.mvn goto baseDirFound
|
||||
cd ..
|
||||
IF "%WDIR%"=="%CD%" goto baseDirNotFound
|
||||
set WDIR=%CD%
|
||||
goto findBaseDir
|
||||
|
||||
:baseDirFound
|
||||
set MAVEN_PROJECTBASEDIR=%WDIR%
|
||||
cd "%EXEC_DIR%"
|
||||
goto endDetectBaseDir
|
||||
|
||||
:baseDirNotFound
|
||||
set MAVEN_PROJECTBASEDIR=%EXEC_DIR%
|
||||
cd "%EXEC_DIR%"
|
||||
|
||||
:endDetectBaseDir
|
||||
|
||||
IF NOT EXIST "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadAdditionalConfig
|
||||
|
||||
@setlocal EnableExtensions EnableDelayedExpansion
|
||||
for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a
|
||||
@endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS%
|
||||
|
||||
:endReadAdditionalConfig
|
||||
|
||||
SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe"
|
||||
set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar"
|
||||
set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
|
||||
|
||||
set DOWNLOAD_URL="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar"
|
||||
|
||||
FOR /F "tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO (
|
||||
IF "%%A"=="wrapperUrl" SET DOWNLOAD_URL=%%B
|
||||
)
|
||||
|
||||
@REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
|
||||
@REM This allows using the maven wrapper in projects that prohibit checking in binary data.
|
||||
if exist %WRAPPER_JAR% (
|
||||
if "%MVNW_VERBOSE%" == "true" (
|
||||
echo Found %WRAPPER_JAR%
|
||||
)
|
||||
) else (
|
||||
if not "%MVNW_REPOURL%" == "" (
|
||||
SET DOWNLOAD_URL="%MVNW_REPOURL%/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar"
|
||||
)
|
||||
if "%MVNW_VERBOSE%" == "true" (
|
||||
echo Couldn't find %WRAPPER_JAR%, downloading it ...
|
||||
echo Downloading from: %DOWNLOAD_URL%
|
||||
)
|
||||
|
||||
powershell -Command "&{"^
|
||||
"$webclient = new-object System.Net.WebClient;"^
|
||||
"if (-not ([string]::IsNullOrEmpty('%MVNW_USERNAME%') -and [string]::IsNullOrEmpty('%MVNW_PASSWORD%'))) {"^
|
||||
"$webclient.Credentials = new-object System.Net.NetworkCredential('%MVNW_USERNAME%', '%MVNW_PASSWORD%');"^
|
||||
"}"^
|
||||
"[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; $webclient.DownloadFile('%DOWNLOAD_URL%', '%WRAPPER_JAR%')"^
|
||||
"}"
|
||||
if "%MVNW_VERBOSE%" == "true" (
|
||||
echo Finished downloading %WRAPPER_JAR%
|
||||
)
|
||||
)
|
||||
@REM End of extension
|
||||
|
||||
@REM Provide a "standardized" way to retrieve the CLI args that will
|
||||
@REM work with both Windows and non-Windows executions.
|
||||
set MAVEN_CMD_LINE_ARGS=%*
|
||||
|
||||
%MAVEN_JAVA_EXE% %JVM_CONFIG_MAVEN_PROPS% %MAVEN_OPTS% %MAVEN_DEBUG_OPTS% -classpath %WRAPPER_JAR% "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %*
|
||||
if ERRORLEVEL 1 goto error
|
||||
goto end
|
||||
|
||||
:error
|
||||
set ERROR_CODE=1
|
||||
|
||||
:end
|
||||
@endlocal & set ERROR_CODE=%ERROR_CODE%
|
||||
|
||||
if not "%MAVEN_SKIP_RC%" == "" goto skipRcPost
|
||||
@REM check for post script, once with legacy .bat ending and once with .cmd ending
|
||||
if exist "%HOME%\mavenrc_post.bat" call "%HOME%\mavenrc_post.bat"
|
||||
if exist "%HOME%\mavenrc_post.cmd" call "%HOME%\mavenrc_post.cmd"
|
||||
:skipRcPost
|
||||
|
||||
@REM pause the script if MAVEN_BATCH_PAUSE is set to 'on'
|
||||
if "%MAVEN_BATCH_PAUSE%" == "on" pause
|
||||
|
||||
if "%MAVEN_TERMINATE_CMD%" == "on" exit %ERROR_CODE%
|
||||
|
||||
exit /B %ERROR_CODE%
|
||||
@ -0,0 +1,118 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-parent</artifactId>
|
||||
<version>2.4.5</version>
|
||||
<relativePath/> <!-- lookup parent from repository -->
|
||||
</parent>
|
||||
<groupId>com.rehome</groupId>
|
||||
<artifactId>weather</artifactId>
|
||||
<version>1.0.1</version>
|
||||
<packaging>war</packaging>
|
||||
<name>weather</name>
|
||||
<description>weather and storm interface</description>
|
||||
<properties>
|
||||
<java.version>1.8</java.version>
|
||||
</properties>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-data-jpa</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-web</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.mybatis.spring.boot</groupId>
|
||||
<artifactId>mybatis-spring-boot-starter</artifactId>
|
||||
<version>2.1.4</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-test</artifactId>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<!--线程池-->
|
||||
<dependency>
|
||||
<groupId>com.mchange</groupId>
|
||||
<artifactId>c3p0</artifactId>
|
||||
<version>0.9.5.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>1.18.20</version>
|
||||
<optional>true</optional>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.alibaba</groupId>
|
||||
<artifactId>fastjson</artifactId>
|
||||
<version>1.2.30</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.google.code.gson</groupId>
|
||||
<artifactId>gson</artifactId>
|
||||
<version>2.8.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-io</groupId>
|
||||
<artifactId>commons-io</artifactId>
|
||||
<version>2.4</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.validation</groupId>
|
||||
<artifactId>validation-api</artifactId>
|
||||
<version>2.0.1.Final</version>
|
||||
</dependency>
|
||||
<!-- https://mvnrepository.com/artifact/org.apache.logging.log4j/log4j-api -->
|
||||
<dependency>
|
||||
<groupId>org.apache.logging.log4j</groupId>
|
||||
<artifactId>log4j-api</artifactId>
|
||||
<version>2.17.1</version>
|
||||
</dependency>
|
||||
<!-- https://mvnrepository.com/artifact/org.apache.logging.log4j/log4j-core -->
|
||||
<dependency>
|
||||
<groupId>org.apache.logging.log4j</groupId>
|
||||
<artifactId>log4j-core</artifactId>
|
||||
<version>2.17.1</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.oracle</groupId>
|
||||
<artifactId>ojdbc6</artifactId>
|
||||
<version>11.2.0.1.0</version>
|
||||
<!-- <artifactId>ojdbc8</artifactId>-->
|
||||
<!-- <version>19.3.0.0.0</version>-->
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-annotations</artifactId>
|
||||
<version>1.5.20</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.squareup.okhttp3</groupId>
|
||||
<artifactId>okhttp</artifactId>
|
||||
<version>3.6.0</version>
|
||||
</dependency>
|
||||
<!--sqlserver驱动 -->
|
||||
<dependency>
|
||||
<groupId>com.microsoft.sqlserver</groupId>
|
||||
<artifactId>mssql-jdbc</artifactId>
|
||||
<version>11.2.0.jre8</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<!-- <finalName>${project.artifactId}</finalName>-->
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
</project>
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,32 @@
|
||||
package com.rehome.weather.dao;
|
||||
|
||||
import com.rehome.weather.entity.StormData;
|
||||
import com.rehome.weather.entity.StormForecast;
|
||||
import com.rehome.weather.entity.StormTrack;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 功能描述 台风Dao层
|
||||
* @author huangwenfei
|
||||
* Created DateTime 2021-05-08 14:08
|
||||
*/
|
||||
|
||||
public interface StormDao {
|
||||
//插入台风数据
|
||||
int insertStorm(StormData stormEntity);
|
||||
//更新台风数据
|
||||
int updateStorm(StormData stormEntity);
|
||||
//根据id查台风数据
|
||||
StormData getStormById(String id);
|
||||
//查本地库台风列表数据
|
||||
List<StormData> getLocalStorms(String year);
|
||||
//插入台风预报数据
|
||||
int insertStormForecast(StormForecast stormForecast);
|
||||
//根据stormid查台风预报数据
|
||||
StormForecast getStormForecastById(String stormid);
|
||||
//插入台风实况和路径数据
|
||||
int insertStormTrack(StormTrack stormTrack);
|
||||
//根据stormid查台风实况和路径数据
|
||||
StormTrack getStormTrackById(String stormid);
|
||||
}
|
||||
@ -0,0 +1,7 @@
|
||||
package com.rehome.weather.dao;
|
||||
|
||||
import com.rehome.weather.entity.WeatherCity;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
public interface WeatherCityRepository extends JpaRepository<WeatherCity,Integer> {
|
||||
}
|
||||
@ -0,0 +1,34 @@
|
||||
package com.rehome.weather.dao;
|
||||
|
||||
import com.rehome.weather.entity.WeatherCity;
|
||||
import com.rehome.weather.entity.WeatherFuture;
|
||||
import com.rehome.weather.entity.WeatherRealtime;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-25 14:35
|
||||
* @description: 天气Dao层
|
||||
*/
|
||||
|
||||
public interface WeatherDao {
|
||||
//根据id查城市
|
||||
WeatherCity getById(Integer id);
|
||||
//插入支持天气查询的城市列表数据
|
||||
int insertCitys(List<WeatherCity> list);
|
||||
//插入实时天气数据
|
||||
int insertRealtimeWeather(WeatherRealtime weatherRealtime);
|
||||
//插入预报天气数据
|
||||
int insertFutrueWeather(WeatherFuture weatherFuture);
|
||||
//更新预报天气数据
|
||||
int updateFutrueWeather(WeatherFuture weatherFuture);
|
||||
//根据日期查预报天气数据
|
||||
WeatherFuture getFutrueByDate(String date);
|
||||
//查本地库实时天气数据
|
||||
WeatherRealtime getLocalWeatherRealtime(String city);
|
||||
//查本地库未来五天预报天气数据
|
||||
List<WeatherFuture> getLocalWeatherFuture(String city);
|
||||
}
|
||||
@ -0,0 +1,13 @@
|
||||
package com.rehome.weather.dao;
|
||||
|
||||
import com.rehome.weather.entity.WeatherRealtime;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
|
||||
public interface WeatherRealtimeRepository extends JpaRepository<WeatherRealtime, Integer> {
|
||||
Optional<List<WeatherRealtime>> findAllByCityContainingOrderByIdDesc(String city);
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,19 @@
|
||||
package com.rehome.weather.dao;
|
||||
|
||||
import com.rehome.weather.entity.WeatherType;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-25 14:35
|
||||
* @description: 天气种类Dao层
|
||||
*/
|
||||
|
||||
public interface WeatherTypeDao {
|
||||
//根据天气种类标识查天气种类数据
|
||||
WeatherType getByWid(String wid);
|
||||
//插入天气种类列表数据
|
||||
int insertWeatherTypes(List<WeatherType> list);
|
||||
}
|
||||
@ -0,0 +1,7 @@
|
||||
package com.rehome.weather.dao;
|
||||
|
||||
import com.rehome.weather.entity.WeatherType;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
public interface WeatherTypeRepository extends JpaRepository<WeatherType, Integer> {
|
||||
}
|
||||
@ -0,0 +1,20 @@
|
||||
package com.rehome.weather.dto;
|
||||
|
||||
import com.rehome.weather.entity.StormData;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-05-08 11:49
|
||||
* @description: 获取台风列表接口Dto
|
||||
*/
|
||||
@Setter
|
||||
@Getter
|
||||
public class StormDto extends BaseStormDto implements Serializable {
|
||||
//台风列表
|
||||
private List<StormData> storm;
|
||||
}
|
||||
@ -0,0 +1,21 @@
|
||||
package com.rehome.weather.dto;
|
||||
|
||||
import com.rehome.weather.entity.WeatherCity;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-29 14:42
|
||||
* @description:
|
||||
*/
|
||||
@Setter
|
||||
@Getter
|
||||
public class WeatherCityListDto extends BaseDto implements Serializable {
|
||||
//支持天气查询的城市列表
|
||||
private List<WeatherCity> result;
|
||||
}
|
||||
@ -0,0 +1,19 @@
|
||||
package com.rehome.weather.dto;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-29 14:47
|
||||
* @description: 天气查询接口Dto
|
||||
*/
|
||||
@Setter
|
||||
@Getter
|
||||
public class WeatherQueryDto extends BaseDto implements Serializable {
|
||||
//天气查询结果,包含实时天气和天气预报
|
||||
private WeatherQueryResultDto result;
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
package com.rehome.weather.dto;
|
||||
|
||||
import com.rehome.weather.entity.WeatherFuture;
|
||||
import com.rehome.weather.entity.WeatherRealtime;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-29 14:52
|
||||
* @description: 天气查询结果,包含实时天气和天气预报
|
||||
*/
|
||||
@Setter
|
||||
@Getter
|
||||
public class WeatherQueryResultDto implements Serializable {
|
||||
//城市
|
||||
private String city ;
|
||||
//实时天气
|
||||
private WeatherRealtime realtime;
|
||||
//天气预报
|
||||
private List<WeatherFuture> future;
|
||||
}
|
||||
@ -0,0 +1,21 @@
|
||||
package com.rehome.weather.dto;
|
||||
|
||||
import com.rehome.weather.entity.WeatherType;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-29 14:36
|
||||
* @description: 天气种类列表接口Dto
|
||||
*/
|
||||
@Setter
|
||||
@Getter
|
||||
public class WeatherTypeListDto extends BaseDto implements Serializable {
|
||||
//天气种类列表
|
||||
private List<WeatherType> result;
|
||||
}
|
||||
@ -0,0 +1,76 @@
|
||||
package com.rehome.weather.entity;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.hibernate.annotations.Proxy;
|
||||
import org.springframework.data.jpa.domain.support.AuditingEntityListener;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.sql.Timestamp;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-05-08 11:53
|
||||
* @description: 台风列表
|
||||
*/
|
||||
@EntityListeners(AuditingEntityListener.class)
|
||||
@Proxy(lazy = false)
|
||||
@Data
|
||||
@Entity
|
||||
public class StormData implements Serializable {
|
||||
|
||||
@Id
|
||||
@ApiModelProperty(value = "主键")
|
||||
private String id ;
|
||||
|
||||
//台风名称
|
||||
@ApiModelProperty(value = "台风名称")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(length=150,nullable = false)// 在数据库中该字段也不允许为null
|
||||
private String name ;
|
||||
|
||||
//台风所处流域
|
||||
@ApiModelProperty(value = "台风所处流域")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(length=20,nullable = false)// 在数据库中该字段也不允许为null
|
||||
private String basin ;
|
||||
|
||||
//台风所处年份
|
||||
@ApiModelProperty(value = "台风所处年份")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(length=20,nullable = false)//在数据库中该字段也不允许为null
|
||||
private String year ;
|
||||
|
||||
//台风接入平台
|
||||
@ApiModelProperty(value = "台风接入平台")
|
||||
@Column(length=30)
|
||||
private String platform;
|
||||
|
||||
//平台描述
|
||||
@ApiModelProperty(value = "平台描述")
|
||||
@Column(length=50)
|
||||
private String platformdesc;
|
||||
|
||||
//是否为活跃台风 1:活跃台风 0:台风已停止
|
||||
@ApiModelProperty(value = "是否为活跃台风 1:活跃台风 0:台风已停止")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(length=10,nullable = false)// 在数据库中该字段也不允许为null
|
||||
private String isActive ;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
|
||||
@Column(updatable = false) //确保这个字段不能更新
|
||||
private Date createtime = new Date();
|
||||
|
||||
@ApiModelProperty(value = "最后更新时间")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
|
||||
private Date updatetime = new Date();
|
||||
|
||||
}
|
||||
@ -0,0 +1,58 @@
|
||||
package com.rehome.weather.entity;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import org.hibernate.annotations.Proxy;
|
||||
import org.springframework.data.jpa.domain.support.AuditingEntityListener;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.sql.Timestamp;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-05-10 11:04
|
||||
* @description: 台风预报
|
||||
*/
|
||||
@EntityListeners(AuditingEntityListener.class)
|
||||
@Proxy(lazy = false)
|
||||
@Data
|
||||
@Entity
|
||||
public class StormForecast implements Serializable {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
@ApiModelProperty(value = "主键")
|
||||
private Integer id ;
|
||||
|
||||
//台风id
|
||||
@ApiModelProperty(value = "台风id")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(length=20,nullable = false)//在数据库中该字段也不允许为null
|
||||
private String stormid ;
|
||||
|
||||
//台风预报源数据
|
||||
//存放长文本
|
||||
@ApiModelProperty(value = "台风预报源数据")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(nullable = false)//在数据库中该字段也不允许为null
|
||||
@Lob
|
||||
@Basic(fetch = FetchType.LAZY)
|
||||
private String forecast ;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
|
||||
private Date createtime;
|
||||
|
||||
@ApiModelProperty(value = "最后更新时间")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
|
||||
private Date updatetime;
|
||||
}
|
||||
@ -0,0 +1,59 @@
|
||||
package com.rehome.weather.entity;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import org.hibernate.annotations.Proxy;
|
||||
import org.springframework.data.jpa.domain.support.AuditingEntityListener;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.sql.Timestamp;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-05-10 11:04
|
||||
* @description: 台风路径
|
||||
*/
|
||||
@EntityListeners(AuditingEntityListener.class)
|
||||
@Proxy(lazy = false)
|
||||
@Data
|
||||
@Entity
|
||||
public class StormTrack implements Serializable {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
@ApiModelProperty(value = "主键")
|
||||
private Integer id ;
|
||||
|
||||
//台风id
|
||||
@ApiModelProperty(value = "台风id")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(length=20,nullable = false)//在数据库中该字段也不允许为null
|
||||
private String stormid ;
|
||||
|
||||
//台风实况和路径源数据
|
||||
//存放长文本
|
||||
@ApiModelProperty(value = "台风实况和路径源数据")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(nullable = false)//在数据库中该字段也不允许为null
|
||||
@Lob
|
||||
@Basic(fetch = FetchType.LAZY)
|
||||
private String track ;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
private Date createtime;
|
||||
|
||||
@ApiModelProperty(value = "最后更新时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
private Date updatetime;
|
||||
|
||||
}
|
||||
@ -0,0 +1,44 @@
|
||||
package com.rehome.weather.entity;
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 支持天气查询的城市
|
||||
*/
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 城市标识
|
||||
*/
|
||||
|
||||
@Data
|
||||
@Entity
|
||||
//@Table(name = "weather_city")
|
||||
public class WeatherCity implements Serializable {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
@ApiModelProperty(value = "主键")
|
||||
private Integer id;
|
||||
|
||||
@ApiModelProperty(value = "省份")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(length=255,nullable = false)
|
||||
private String province ;
|
||||
|
||||
@ApiModelProperty(value = "城市")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(length=255,nullable = false)
|
||||
private String city ;
|
||||
|
||||
@ApiModelProperty(value = "区")
|
||||
@Column(length=255)
|
||||
private String district ;
|
||||
|
||||
}
|
||||
@ -0,0 +1,75 @@
|
||||
package com.rehome.weather.entity;
|
||||
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.hibernate.annotations.Proxy;
|
||||
import org.springframework.data.jpa.domain.support.AuditingEntityListener;
|
||||
import javax.persistence.*;
|
||||
import java.io.Serializable;
|
||||
import java.sql.Timestamp;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 天气预报
|
||||
*/
|
||||
@EntityListeners(AuditingEntityListener.class)
|
||||
@Proxy(lazy = false)
|
||||
@Data
|
||||
@Entity
|
||||
public class WeatherFuture implements Serializable{
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
@ApiModelProperty(value = "主键")
|
||||
private Integer id ;
|
||||
//预报日期
|
||||
@ApiModelProperty(value = "预报日期")
|
||||
@Column(length=20)
|
||||
private String date ;
|
||||
//温度
|
||||
@ApiModelProperty(value = "温度")
|
||||
@Column(length=50)
|
||||
private String temperature ;
|
||||
//天气情况
|
||||
@ApiModelProperty(value = "天气情况")
|
||||
@Column(length=255)
|
||||
private String weather ;
|
||||
//白天天气标识id
|
||||
@ApiModelProperty(value = "白天天气标识id")
|
||||
@Column(length=11)
|
||||
private String widday ;
|
||||
//晚上天气标识id
|
||||
@ApiModelProperty(value = "晚上天气标识id")
|
||||
@Column(length=11)
|
||||
private String widnight ;
|
||||
//白天天气情况
|
||||
@ApiModelProperty(value = "白天天气情况")
|
||||
@Column(length=255)
|
||||
private String widdayDesc ;
|
||||
//晚上天气情况
|
||||
@ApiModelProperty(value = "晚上天气情况")
|
||||
@Column(length=255)
|
||||
private String widnightDesc ;
|
||||
//风向
|
||||
@ApiModelProperty(value = "风向")
|
||||
@Column(length=255)
|
||||
private String direct ;
|
||||
//城市
|
||||
@ApiModelProperty(value = "城市")
|
||||
@Column(length=255)
|
||||
private String city ;
|
||||
|
||||
@Transient
|
||||
WidEntity wid;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
private Date createtime;
|
||||
|
||||
@ApiModelProperty(value = "最后更新时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
private Date updatetime;
|
||||
}
|
||||
@ -0,0 +1,69 @@
|
||||
package com.rehome.weather.entity;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import org.hibernate.annotations.Proxy;
|
||||
import org.springframework.data.jpa.domain.support.AuditingEntityListener;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.io.Serializable;
|
||||
import java.sql.Timestamp;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 实时天气
|
||||
*/
|
||||
@EntityListeners(AuditingEntityListener.class)
|
||||
@Proxy(lazy = false)
|
||||
@Data
|
||||
@Entity
|
||||
public class WeatherRealtime implements Serializable{
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
@ApiModelProperty(value = "主键")
|
||||
private Integer id ;
|
||||
|
||||
@ApiModelProperty(value = "温度,可能为空")
|
||||
@Column(length=255)
|
||||
private String temperature ;
|
||||
|
||||
@ApiModelProperty(value = "湿度,可能为空")
|
||||
@Column(length=255)
|
||||
private String humidity ;
|
||||
|
||||
@ApiModelProperty(value = "天气情况")
|
||||
@Column(length=255)
|
||||
private String info ;
|
||||
|
||||
@ApiModelProperty(value = "天气标识id")
|
||||
@Column(length=11)
|
||||
private String wid ;
|
||||
|
||||
@ApiModelProperty(value = "风向,可能为空")
|
||||
@Column(length=255)
|
||||
private String direct ;
|
||||
|
||||
@ApiModelProperty(value = "风力,可能为空")
|
||||
@Column(length=255)
|
||||
private String power ;
|
||||
|
||||
@ApiModelProperty(value = "空气质量指数,可能为空")
|
||||
@Column(length=255)
|
||||
private String aqi ;
|
||||
|
||||
@ApiModelProperty(value = "城市")
|
||||
@Column(length=255)
|
||||
private String city ;
|
||||
|
||||
@ApiModelProperty(value = "日期")
|
||||
@Column(length=30)
|
||||
private String date;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
private Date createtime;
|
||||
}
|
||||
@ -0,0 +1,32 @@
|
||||
package com.rehome.weather.entity;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 天气种类
|
||||
*/
|
||||
@Data
|
||||
@Entity
|
||||
public class WeatherType implements Serializable{WeatherTypeRepository
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
@ApiModelProperty(value = "主键")
|
||||
private Integer id;
|
||||
|
||||
@ApiModelProperty(value = "天气标识id")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(length=255,nullable = false)
|
||||
private String wid ;
|
||||
|
||||
@ApiModelProperty(value = "天气种类说明")
|
||||
@NotNull // 确保这个字段在插入时不为null
|
||||
@Column(length=255,nullable = false)
|
||||
private String weather ;
|
||||
}
|
||||
@ -0,0 +1,24 @@
|
||||
package com.rehome.weather.entity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import org.hibernate.annotations.Proxy;
|
||||
import org.springframework.data.jpa.domain.support.AuditingEntityListener;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 天气预报标识
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class WidEntity implements Serializable{
|
||||
|
||||
@ApiModelProperty(value = "白天天气标识id")
|
||||
private String day ;
|
||||
|
||||
@ApiModelProperty(value = "晚上天气标识id")
|
||||
private String night ;
|
||||
}
|
||||
@ -0,0 +1,24 @@
|
||||
package com.rehome.weather.service;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-26 14:35
|
||||
* @description: 台风服务接口
|
||||
*/
|
||||
public interface StormService {
|
||||
//从和风天气开发平台获取台风列表数据并入库
|
||||
public Map getStormListByScheduled(String year);
|
||||
//从和风天气开发平台获取台风预报并入库
|
||||
public String getStormForecastByScheduled(String stormid);
|
||||
//从和风天气开发平台获取台风实况和路径并入库
|
||||
public String getStormTrackByScheduled(String stormid);
|
||||
//从本地数据库查台风列表
|
||||
public Map getLocalStormList(String year);
|
||||
//从本地数据库查台风预报
|
||||
public String getLocalStormForecastByStormId(String stormid);
|
||||
//从本地数据库查台风实况和路径
|
||||
public String getLocalStormTrackByStormId(String stormid);
|
||||
}
|
||||
@ -0,0 +1,30 @@
|
||||
package com.rehome.weather.service;
|
||||
|
||||
import com.rehome.weather.entity.WeatherCity;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-26 14:35
|
||||
* @description: 天气服务接口
|
||||
*/
|
||||
public interface WeatherService {
|
||||
//根据城市id查询城市数据
|
||||
public WeatherCity getById(Integer id);
|
||||
//直接向聚合数据查询天气数据
|
||||
public String getJuheWeather();
|
||||
//获取支持天气查询的城市列表数据,同时入库
|
||||
public String getWeatherCitySupporList();
|
||||
//根据城市查询天气数据,然后把获取到的实时天气和预报天气入库
|
||||
public Map getJuheWeatherByScheduled(String cityInput);
|
||||
//从本地数据库查实时天气和预报天气数据,然后返回给前端
|
||||
public Map getLocalWeatherByCity(String city);
|
||||
}
|
||||
|
||||
/**
|
||||
* 从mysql数据库中查询最新的一条数据的方法
|
||||
* SELECT * from a where id = (SELECT max(id) FROM a);
|
||||
* select * FROM 表名 ORDER BY id DESC LIMIT 0,1 ;
|
||||
* SELECT * from a where id = (SELECT max(id) FROM a) and city = 珠海;
|
||||
*/
|
||||
@ -0,0 +1,16 @@
|
||||
package com.rehome.weather.service;
|
||||
|
||||
import com.rehome.weather.entity.WeatherType;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-26 14:35
|
||||
* @description: 天气种类服务接口
|
||||
*/
|
||||
public interface WeatherTypeService {
|
||||
//根据天气标识ID查天气种类数据
|
||||
public WeatherType getByWId(String wid);
|
||||
//获取天气种类列表,然后入库
|
||||
public String getWeatherTypeList();
|
||||
}
|
||||
@ -0,0 +1,231 @@
|
||||
package com.rehome.weather.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.rehome.weather.config.dao.JuheWeatherProperties;
|
||||
import com.rehome.weather.dao.StormDao;
|
||||
import com.rehome.weather.dto.BaseStormDto;
|
||||
import com.rehome.weather.dto.StormDto;
|
||||
import com.rehome.weather.entity.*;
|
||||
import com.rehome.weather.service.StormService;
|
||||
import com.rehome.weather.utils.WeatherUtil;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.boot.context.properties.EnableConfigurationProperties;
|
||||
import org.springframework.cache.annotation.CacheConfig;
|
||||
import org.springframework.cache.annotation.CacheEvict;
|
||||
import org.springframework.cache.annotation.Cacheable;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.sql.Timestamp;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-05-08 13:54
|
||||
* @description: 台风服务接口实现类
|
||||
*/
|
||||
|
||||
@Service
|
||||
@EnableConfigurationProperties(JuheWeatherProperties.class)
|
||||
@CacheConfig(cacheNames = "com.rehome.weather.service.impl.StormServiceImpl")
|
||||
public class StormServiceImpl implements StormService {
|
||||
private Logger log = LoggerFactory.getLogger(this.getClass());
|
||||
|
||||
//台风dao
|
||||
@Resource
|
||||
private StormDao stormDao ;
|
||||
//聚合数据 配置文件相关参数
|
||||
@Resource
|
||||
JuheWeatherProperties juheWeatherProperties;
|
||||
|
||||
/**
|
||||
* 功能描述 从和风天气开发平台查询台风列表数据并入库
|
||||
* @author huangwenfei
|
||||
* Created DateTime 2021-05-08 17:29
|
||||
*/
|
||||
@Override
|
||||
@CacheEvict(cacheNames = "com.rehome.weather.service.impl.StormServiceImpl",allEntries = true)
|
||||
public Map getStormListByScheduled(String year) {
|
||||
String stormListUrl = juheWeatherProperties.getStormListUrl();
|
||||
String heFengStormKey=juheWeatherProperties.getHeFengStormKey();
|
||||
String url=stormListUrl+"?key="+heFengStormKey+"&basin=NP&year="+year;
|
||||
String stormJson = WeatherUtil.analysisUrlGzip(url);
|
||||
log.info(url);
|
||||
log.info(stormJson);
|
||||
StormDto stormDto = JSON.parseObject(stormJson, StormDto.class);
|
||||
Map map = new HashMap<String,Object>();
|
||||
if(stormDto!=null&&stormDto.getCode().equals("200")){
|
||||
List<StormData> storm=stormDto.getStorm();
|
||||
if(storm.size()>0){
|
||||
for (StormData stormEntity : storm) {
|
||||
stormEntity.setPlatform("hefeng");
|
||||
stormEntity.setPlatformdesc("和风天气开发平台");
|
||||
StormData stormEntityDb=stormDao.getStormById(stormEntity.getId());
|
||||
if(stormEntityDb==null){
|
||||
//数据库不存在这条台风数据 插入这条台风数据,
|
||||
//同时调用台风预报接口数据并入库,
|
||||
//同时调用台风实况和路径接口数据并入库,
|
||||
log.info("数据库不存在这条台风数据 插入这条台风数据,");
|
||||
int resultId=stormDao.insertStorm(stormEntity);
|
||||
log.info("插入台风数据成功,id:"+String.valueOf(resultId));
|
||||
this.getStormForecastByScheduled(stormEntity.getId());
|
||||
this.getStormTrackByScheduled(stormEntity.getId());
|
||||
|
||||
}else{
|
||||
//数据库存在这条台风数据
|
||||
if(stormEntity.getIsActive().equals("1")){
|
||||
//台风处于活跃状态
|
||||
//同时调用台风预报接口数据并入库,
|
||||
//同时调用台风实况和路径接口数据并入库
|
||||
log.info("台风处于活跃状态");
|
||||
this.getStormForecastByScheduled(stormEntity.getId());
|
||||
this.getStormTrackByScheduled(stormEntity.getId());
|
||||
}
|
||||
if(stormEntity.getIsActive().equals("0")){
|
||||
//台风已停止状态
|
||||
if(stormEntityDb.getIsActive().equals("1")){
|
||||
//数据库里台风还处于活跃状态,更新台风状态
|
||||
//同时调用台风预报接口数据并入库,
|
||||
//同时调用台风实况和路径接口数据并入库
|
||||
log.info("数据库里台风还处于活跃状态,更新台风状态");
|
||||
//获得系统时间.
|
||||
Date date = new Date();
|
||||
//将时间格式转换成符合Timestamp要求的格式.
|
||||
String nowTime = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(date);
|
||||
//把时间转换
|
||||
Timestamp updatetime =Timestamp.valueOf(nowTime);
|
||||
stormEntity.setUpdatetime(updatetime);
|
||||
int resultId=stormDao.updateStorm(stormEntity);
|
||||
log.info("更新台风数据成功,id:"+String.valueOf(resultId));
|
||||
this.getStormForecastByScheduled(stormEntity.getId());
|
||||
this.getStormTrackByScheduled(stormEntity.getId());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
map.put("reason","从和风天气开发平台查询台风列表数据成功!");
|
||||
map.put("code","200");
|
||||
map.put("storm",storm);
|
||||
}else{
|
||||
if(stormDto!=null){
|
||||
map.put("code",stormDto.getCode());
|
||||
}else{
|
||||
map.put("code","10000");
|
||||
map.put("reason","从和风天气开发平台获取台风列表数据失败!");
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/**
|
||||
* 功能描述 从和风天气开发平台获取台风预报并入库
|
||||
* @author huangwenfei
|
||||
* Created DateTime 2021-05-10 16:02
|
||||
*/
|
||||
@Override
|
||||
public String getStormForecastByScheduled(String stormid) {
|
||||
String stormForecastUrl = juheWeatherProperties.getStormForecastUrl();
|
||||
String heFengStormKey=juheWeatherProperties.getHeFengStormKey();
|
||||
String url=stormForecastUrl+"?key="+heFengStormKey+"&stormid="+stormid;
|
||||
String stormJson = WeatherUtil.analysisUrlGzip(url);
|
||||
log.info(url);
|
||||
log.info(stormJson);
|
||||
BaseStormDto baseStormDto = JSON.parseObject(stormJson, BaseStormDto.class);
|
||||
if(baseStormDto.getCode().equals("200")){
|
||||
StormForecast stormForecast = new StormForecast();
|
||||
stormForecast.setStormid(stormid);
|
||||
stormForecast.setForecast(stormJson);
|
||||
int resultId=stormDao.insertStormForecast(stormForecast);
|
||||
log.info("插入台风预报数据成功,id:"+String.valueOf(resultId));
|
||||
}
|
||||
return stormJson;
|
||||
}
|
||||
|
||||
/**
|
||||
* 功能描述 从和风天气开发平台获取台风实况和路径并入库
|
||||
* @author huangwenfei
|
||||
* Created DateTime 2021-05-10 16:03
|
||||
*/
|
||||
@Override
|
||||
public String getStormTrackByScheduled(String stormid) {
|
||||
String stormTrackUrl = juheWeatherProperties.getStormTrackUrl();
|
||||
String heFengStormKey=juheWeatherProperties.getHeFengStormKey();
|
||||
String url=stormTrackUrl+"?key="+heFengStormKey+"&stormid="+stormid;
|
||||
String stormJson = WeatherUtil.analysisUrlGzip(url);
|
||||
log.info(url);
|
||||
log.info(stormJson);
|
||||
BaseStormDto baseStormDto = JSON.parseObject(stormJson, BaseStormDto.class);
|
||||
if(baseStormDto.getCode().equals("200")){
|
||||
StormTrack stormTrack = new StormTrack();
|
||||
stormTrack.setStormid(stormid);
|
||||
stormTrack.setTrack(stormJson);
|
||||
int resultId=stormDao.insertStormTrack(stormTrack);
|
||||
log.info("插入台风实况和路径数据成功,id:"+String.valueOf(resultId));
|
||||
}
|
||||
return stormJson;
|
||||
}
|
||||
|
||||
/**
|
||||
* 功能描述 从本地数据库查台风列表
|
||||
* @author huangwenfei
|
||||
* Created DateTime 2021-05-10 14:18
|
||||
*/
|
||||
@Override
|
||||
@Cacheable(cacheNames="com.rehome.weather.service.impl.StormServiceImpl",key="#year+'-getLocalStormList'")
|
||||
public Map getLocalStormList(String year) {
|
||||
Map map = new HashMap<String,Object>();
|
||||
List<StormData> storm=stormDao.getLocalStorms(year);
|
||||
List stormEmpty=new ArrayList<StormData>();
|
||||
if(storm==null){
|
||||
map.put("storm",stormEmpty);
|
||||
}else{
|
||||
map.put("storm",storm);
|
||||
}
|
||||
map.put("code","200");
|
||||
return map;
|
||||
}
|
||||
|
||||
/**
|
||||
* 功能描述 从本地数据库查台风预报
|
||||
* @author huangwenfei
|
||||
* Created DateTime 2021-05-10 14:17
|
||||
*/
|
||||
@Override
|
||||
@Cacheable(cacheNames="com.rehome.weather.service.impl.StormServiceImpl",key="#stormid+'-getLocalStormForecastByStormId'")
|
||||
public String getLocalStormForecastByStormId(String stormid) {
|
||||
StormForecast stormForecast = stormDao.getStormForecastById(stormid);
|
||||
if(stormForecast!=null){
|
||||
return stormForecast.getForecast();
|
||||
}
|
||||
Map map = new HashMap<String,Object>();
|
||||
map.put("code","10000");
|
||||
map.put("reason","查询不到数据");
|
||||
String jsonString = JSON.toJSONString(map);
|
||||
return jsonString;
|
||||
}
|
||||
|
||||
/**
|
||||
* 功能描述 从本地数据库查台风实况和路径
|
||||
* @author huangwenfei
|
||||
* Created DateTime 2021-05-10 14:18
|
||||
*/
|
||||
@Override
|
||||
@Cacheable(cacheNames="com.rehome.weather.service.impl.StormServiceImpl",key="#stormid+'-getLocalStormTrackByStormId'")
|
||||
public String getLocalStormTrackByStormId(String stormid) {
|
||||
StormTrack stormTrack = stormDao.getStormTrackById(stormid);
|
||||
if (stormTrack!=null){
|
||||
return stormTrack.getTrack();
|
||||
}
|
||||
Map map = new HashMap<String,Object>();
|
||||
map.put("code","10000");
|
||||
map.put("reason","查询不到数据");
|
||||
String jsonString = JSON.toJSONString(map);
|
||||
return jsonString;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,91 @@
|
||||
package com.rehome.weather.utils;
|
||||
|
||||
import java.io.BufferedReader;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.InputStreamReader;
|
||||
import java.net.HttpURLConnection;
|
||||
import java.net.URL;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-27 9:35
|
||||
* @description: http请求工具类
|
||||
*/
|
||||
public class HttpURLConnectionUtil {
|
||||
|
||||
/**
|
||||
* @date 2021-04-29 11:23
|
||||
* @description: get请求
|
||||
* @Param: urlStr get请求的url
|
||||
*/
|
||||
public static String getNetData(String urlStr) {
|
||||
HttpURLConnection conn = null;
|
||||
|
||||
//连接成功后我们是要读取数据的 所以要有一个输入流
|
||||
InputStream inputStream = null;
|
||||
|
||||
// 因为读取的都是文本信息 所以使用BufferedReader
|
||||
BufferedReader bufferedReader = null;
|
||||
|
||||
//StringBuilder来把接收到的数据拼接起来
|
||||
StringBuilder result = new StringBuilder();
|
||||
try {
|
||||
// 读取初始url 并且创建对象
|
||||
URL url = new URL(urlStr);
|
||||
//打开url连接
|
||||
conn = (HttpURLConnection) url.openConnection();
|
||||
//设置连接
|
||||
//请求的方法
|
||||
conn.setRequestMethod("GET");
|
||||
//设置主机连接超时(单位:毫秒)
|
||||
// 发送请求端 连接到 url目标地址端的时间 受距离长短和网络速度的影响
|
||||
conn.setConnectTimeout(15000);
|
||||
//设置从主机读取数据超时(单位:毫秒)
|
||||
// 连接成功后 获取数据的时间 受数据量和服务器处理数据的影响
|
||||
conn.setReadTimeout(60000);
|
||||
|
||||
//设置请求参数 可以指定接收json参数 服务端的key为content-type
|
||||
conn.setRequestProperty("Accept", "application/json");
|
||||
|
||||
//发送请求
|
||||
conn.connect();
|
||||
|
||||
//获取响应码 如果响应码不为200 表示请求不成功
|
||||
if (conn.getResponseCode() != 200) {
|
||||
//todo 此处应该增加异常处理手段
|
||||
return "请求失败!!!";
|
||||
}
|
||||
|
||||
//获取响应码 如果响应码为200 表示请求成功 然后可以读取数据
|
||||
//获取输入流 然后读取数据
|
||||
inputStream = conn.getInputStream();
|
||||
bufferedReader = new BufferedReader(new InputStreamReader(inputStream, "UTF-8"));
|
||||
|
||||
//逐行读取数据
|
||||
String line;//用来读取数据
|
||||
while ((line = bufferedReader.readLine()) != null) {
|
||||
result.append(line);
|
||||
//System.out.print(line);
|
||||
}
|
||||
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
} finally {
|
||||
//关闭各种流
|
||||
try {
|
||||
if (bufferedReader != null) {
|
||||
bufferedReader.close();
|
||||
}
|
||||
if (inputStream != null) {
|
||||
inputStream.close();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
return result.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,67 @@
|
||||
package com.rehome.weather.utils;
|
||||
|
||||
import org.apache.commons.io.IOUtils;
|
||||
import java.io.BufferedReader;
|
||||
import java.io.InputStream;
|
||||
import java.io.InputStreamReader;
|
||||
import java.net.HttpURLConnection;
|
||||
import java.net.URL;
|
||||
import java.util.zip.GZIPInputStream;
|
||||
|
||||
/**
|
||||
* @author huangwenfei
|
||||
* @version v1.0.0.0
|
||||
* Created DateTime 2021-04-26 9:35
|
||||
* @description: http请求工具类
|
||||
*/
|
||||
public class WeatherUtil {
|
||||
/**
|
||||
* @date 2021-04-29 11:23
|
||||
* @description: get请求
|
||||
* @Param: url get请求的url
|
||||
*/
|
||||
public static String analysisUrl(String url){
|
||||
HttpURLConnection httpConnection = null;
|
||||
String output = "";
|
||||
try {
|
||||
URL targetUrl = new URL(url);
|
||||
httpConnection = (HttpURLConnection) targetUrl.openConnection();
|
||||
httpConnection.setDoOutput(true);
|
||||
httpConnection.setRequestMethod("GET");
|
||||
httpConnection.setRequestProperty("Content-Type",
|
||||
"application/json");
|
||||
InputStreamReader isr = new InputStreamReader(httpConnection
|
||||
.getInputStream(),"utf-8");
|
||||
BufferedReader responseBuffer = new BufferedReader(isr);
|
||||
output = responseBuffer.readLine();
|
||||
} catch (Exception e) {
|
||||
|
||||
} finally {
|
||||
httpConnection.disconnect();
|
||||
}
|
||||
return output;
|
||||
}
|
||||
/**
|
||||
* @date 2021-04-29 11:23
|
||||
* @description: get请求
|
||||
* @Param: url get请求的url
|
||||
*/
|
||||
public static String analysisUrlGzip(String url){
|
||||
HttpURLConnection httpConnection = null;
|
||||
String output = "";
|
||||
try {
|
||||
URL targetUrl = new URL(url);
|
||||
httpConnection = (HttpURLConnection) targetUrl.openConnection();
|
||||
httpConnection.setDoOutput(true);
|
||||
httpConnection.setRequestMethod("GET");
|
||||
httpConnection.setRequestProperty("Content-Type", "application/json");
|
||||
InputStream stream = new GZIPInputStream(httpConnection.getInputStream());
|
||||
output = IOUtils.toString(stream,"utf-8");
|
||||
} catch (Exception e) {
|
||||
|
||||
} finally {
|
||||
httpConnection.disconnect();
|
||||
}
|
||||
return output;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,18 @@
|
||||
#要查询天气的城市,
|
||||
weather.city=珠海
|
||||
#聚合数据查询天气url
|
||||
weather.weatherQueryUrl=http://apis.juhe.cn/simpleWeather/query
|
||||
#聚合数据天气API key,天气接口共用
|
||||
weather.weatherKey=cd830a007997cde26a730bfcb0c9069d
|
||||
#聚合数据 支持天气查询的城市列表url
|
||||
weather.cityListUrl=http://apis.juhe.cn/simpleWeather/cityList
|
||||
#聚合数据 获取天气种类的url
|
||||
weather.weatherTypeUrl=http://apis.juhe.cn/simpleWeather/wids
|
||||
#和风天气开发平台 台风key
|
||||
weather.heFengStormKey=c06d26b86ff9424688b45f45906cab1d
|
||||
#和风天气开发平台 台风列表url
|
||||
weather.stormListUrl=https://api.qweather.com/v7/tropical/storm-list
|
||||
#和风天气开发平台 台风预报url
|
||||
weather.stormForecastUrl=https://api.qweather.com/v7/tropical/storm-forecast
|
||||
#和风天气开发平台 台风实况和路径url
|
||||
weather.stormTrackUrl=https://api.qweather.com/v7/tropical/storm-track
|
||||
@ -0,0 +1,40 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||
<mapper namespace="com.rehome.weather.dao.StormDao">
|
||||
<!-- 根据主键查询-->
|
||||
<select id="getStormById" resultType="com.rehome.weather.entity.StormData" parameterType="java.lang.String" >
|
||||
select *
|
||||
from storm_data
|
||||
where id = #{id}
|
||||
</select>
|
||||
<insert id="insertStorm" parameterType="com.rehome.weather.entity.StormData">
|
||||
insert into storm_data (id,name,basin,year,platform,platformdesc,isActive)
|
||||
values (#{id},#{name},#{basin},#{year},#{platform},#{platformdesc},#{isActive});
|
||||
</insert>
|
||||
<update id="updateStorm" parameterType="com.rehome.weather.entity.StormData">
|
||||
update storm_data set isActive=#{isActive},updatetime=#{updatetime} where id=#{id}
|
||||
</update>
|
||||
<select id="getLocalStorms" resultType="com.rehome.weather.entity.StormData" parameterType="java.lang.String" >
|
||||
select *
|
||||
from storm_data
|
||||
where year = #{year} ORDER BY id DESC
|
||||
</select>
|
||||
<insert id="insertStormForecast" parameterType="com.rehome.weather.entity.StormForecast">
|
||||
insert into storm_forecast (stormid,forecast)
|
||||
values (#{stormid}, #{forecast});
|
||||
</insert>
|
||||
<select id="getStormForecastById" resultType="com.rehome.weather.entity.StormForecast" parameterType="java.lang.String" >
|
||||
select *
|
||||
from storm_forecast
|
||||
where stormid = #{stormid} ORDER BY id DESC LIMIT 0,1
|
||||
</select>
|
||||
<insert id="insertStormTrack" parameterType="com.rehome.weather.entity.StormTrack">
|
||||
insert into storm_track (stormid,track)
|
||||
values (#{stormid}, #{track});
|
||||
</insert>
|
||||
<select id="getStormTrackById" resultType="com.rehome.weather.entity.StormTrack" parameterType="java.lang.String" >
|
||||
select *
|
||||
from storm_track
|
||||
where stormid = #{stormid} ORDER BY id DESC LIMIT 0,1
|
||||
</select>
|
||||
</mapper>
|
||||
@ -0,0 +1,44 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||
<mapper namespace="com.rehome.weather.dao.WeatherDao">
|
||||
<!-- 根据主键查询-->
|
||||
<select id="getById" resultType="com.rehome.weather.entity.WeatherCity" parameterType="java.lang.Integer" >
|
||||
select *
|
||||
from weather_city
|
||||
where id = #{id}
|
||||
</select>
|
||||
<insert id="insertCitys" parameterType="com.rehome.weather.entity.WeatherCity">
|
||||
insert into weather_city (id, province, city,district)
|
||||
values
|
||||
<foreach collection="list" item="city" index="index" separator=",">
|
||||
(#{city.id,jdbcType=INTEGER}, #{city.province,jdbcType=VARCHAR}, #{city.city,jdbcType=VARCHAR},
|
||||
#{city.district,jdbcType=VARCHAR})
|
||||
</foreach>
|
||||
</insert>
|
||||
<insert id="insertRealtimeWeather" parameterType="com.rehome.weather.entity.WeatherRealtime">
|
||||
insert into weather_realtime (temperature,humidity,info,wid,direct,power,aqi,city,date)
|
||||
values (#{temperature}, #{humidity}, #{info},#{wid},#{direct},#{power},#{aqi},#{city},#{date});
|
||||
</insert>
|
||||
<select id="getLocalWeatherRealtime" resultType="com.rehome.weather.entity.WeatherRealtime" parameterType="java.lang.String" >
|
||||
select *
|
||||
from weather_realtime
|
||||
where city = #{city} and id = (SELECT max(id) FROM weather_realtime)
|
||||
</select>
|
||||
<insert id="insertFutrueWeather" parameterType="com.rehome.weather.entity.WeatherFuture">
|
||||
insert into weather_future (date,temperature,weather,widday,widnight,widdayDesc,widnightDesc,direct,city)
|
||||
values (#{date},#{temperature}, #{weather}, #{widday},#{widnight},#{widnightDesc},#{widnightDesc},#{direct},#{city});
|
||||
</insert>
|
||||
<update id="updateFutrueWeather" parameterType="com.rehome.weather.entity.WeatherFuture">
|
||||
update weather_future set temperature=#{temperature},weather=#{weather},widday=#{widday},widnight=#{widnight},widdayDesc=#{widdayDesc},widnightDesc=#{widnightDesc},direct=#{direct},updatetime=#{updatetime} where date=#{date}
|
||||
</update>
|
||||
<select id="getFutrueByDate" resultType="com.rehome.weather.entity.WeatherFuture" parameterType="java.lang.String" >
|
||||
select *
|
||||
from weather_future
|
||||
where date = #{date}
|
||||
</select>
|
||||
<select id="getLocalWeatherFuture" resultType="com.rehome.weather.entity.WeatherFuture" parameterType="java.lang.String" >
|
||||
select *
|
||||
from weather_future
|
||||
where city = #{city} ORDER BY id DESC LIMIT 0,5
|
||||
</select>
|
||||
</mapper>
|
||||
@ -0,0 +1,18 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||
<mapper namespace="com.rehome.weather.dao.WeatherTypeDao">
|
||||
<!-- 根据主键查询-->
|
||||
<select id="getByWid" resultType="com.rehome.weather.entity.WeatherType" parameterType="java.lang.String" >
|
||||
select *
|
||||
from weather_type
|
||||
where wid = #{wid}
|
||||
</select>
|
||||
<insert id="insertWeatherTypes" parameterType="com.rehome.weather.entity.WeatherType">
|
||||
insert into weather_type (wid, weather)
|
||||
values
|
||||
<foreach collection="list" item="weatherType" index="index" separator=",">
|
||||
(#{weatherType.wid,jdbcType=VARCHAR}, #{weatherType.weather,jdbcType=VARCHAR})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
</mapper>
|
||||
@ -0,0 +1,61 @@
|
||||
/*
|
||||
Navicat MySQL Data Transfer
|
||||
|
||||
Source Server : 本地mysql
|
||||
Source Server Version : 50734
|
||||
Source Host : localhost:3306
|
||||
Source Database : weather
|
||||
|
||||
Target Server Type : MYSQL
|
||||
Target Server Version : 50734
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 2021-05-11 16:04:46
|
||||
*/
|
||||
|
||||
SET FOREIGN_KEY_CHECKS=0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for storm_data
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `storm_data`;
|
||||
CREATE TABLE `storm_data` (
|
||||
`id` varchar(20) NOT NULL COMMENT '平台描述',
|
||||
`name` varchar(150) NOT NULL,
|
||||
`basin` varchar(20) NOT NULL,
|
||||
`year` varchar(20) NOT NULL,
|
||||
`platform` varchar(30) DEFAULT NULL COMMENT '台风接入平台',
|
||||
`platformdesc` varchar(50) DEFAULT NULL COMMENT '平台描述',
|
||||
`isActive` varchar(10) NOT NULL,
|
||||
`createtime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
`updatetime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='台风列表';
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for storm_forecast
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `storm_forecast`;
|
||||
CREATE TABLE `storm_forecast` (
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`stormid` varchar(20) NOT NULL,
|
||||
`forecast` mediumtext NOT NULL,
|
||||
`createtime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
`updatetime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 COMMENT='台风预报';
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for storm_track
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `storm_track`;
|
||||
CREATE TABLE `storm_track` (
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`stormid` varbinary(20) NOT NULL,
|
||||
`track` mediumtext NOT NULL,
|
||||
`createtime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
`updatetime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4 COMMENT='台风实况和路径';
|
||||
|
||||
|
||||
@ -0,0 +1,61 @@
|
||||
/*
|
||||
Navicat MySQL Data Transfer
|
||||
|
||||
Source Server : 本地mysql
|
||||
Source Server Version : 50734
|
||||
Source Host : localhost:3306
|
||||
Source Database : weather
|
||||
|
||||
Target Server Type : MYSQL
|
||||
Target Server Version : 50734
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 2021-05-11 16:04:46
|
||||
*/
|
||||
|
||||
SET FOREIGN_KEY_CHECKS=0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for storm_data
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `storm_data`;
|
||||
CREATE TABLE `storm_data` (
|
||||
`id` varchar(20) NOT NULL COMMENT '平台描述',
|
||||
`name` varchar(150) NOT NULL,
|
||||
`basin` varchar(20) NOT NULL,
|
||||
`year` varchar(20) NOT NULL,
|
||||
`platform` varchar(30) DEFAULT NULL COMMENT '台风接入平台',
|
||||
`platformdesc` varchar(50) DEFAULT NULL COMMENT '平台描述',
|
||||
`isActive` varchar(10) NOT NULL,
|
||||
`createtime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
`updatetime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='台风列表';
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for storm_forecast
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `storm_forecast`;
|
||||
CREATE TABLE `storm_forecast` (
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`stormid` varchar(20) NOT NULL,
|
||||
`forecast` mediumtext NOT NULL,
|
||||
`createtime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
`updatetime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 COMMENT='台风预报';
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for storm_track
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `storm_track`;
|
||||
CREATE TABLE `storm_track` (
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`stormid` varbinary(20) NOT NULL,
|
||||
`track` mediumtext NOT NULL,
|
||||
`createtime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
`updatetime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4 COMMENT='台风实况和路径';
|
||||
|
||||
|
||||
@ -0,0 +1,33 @@
|
||||
/*
|
||||
Navicat MySQL Data Transfer
|
||||
|
||||
Source Server : 本地mysql
|
||||
Source Server Version : 50734
|
||||
Source Host : localhost:3306
|
||||
Source Database : weather
|
||||
|
||||
Target Server Type : MYSQL
|
||||
Target Server Version : 50734
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 2021-05-11 16:09:19
|
||||
*/
|
||||
|
||||
SET FOREIGN_KEY_CHECKS=0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for storm_data
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `storm_data`;
|
||||
CREATE TABLE `storm_data` (
|
||||
`id` varchar(20) NOT NULL COMMENT '平台描述',
|
||||
`name` varchar(150) NOT NULL,
|
||||
`basin` varchar(20) NOT NULL,
|
||||
`year` varchar(20) NOT NULL,
|
||||
`platform` varchar(30) DEFAULT NULL COMMENT '台风接入平台',
|
||||
`platformdesc` varchar(50) DEFAULT NULL COMMENT '平台描述',
|
||||
`isActive` varchar(10) NOT NULL,
|
||||
`createtime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
`updatetime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='台风列表';
|
||||
@ -0,0 +1,29 @@
|
||||
/*
|
||||
Navicat MySQL Data Transfer
|
||||
|
||||
Source Server : 本地mysql
|
||||
Source Server Version : 50734
|
||||
Source Host : localhost:3306
|
||||
Source Database : weather
|
||||
|
||||
Target Server Type : MYSQL
|
||||
Target Server Version : 50734
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 2021-05-11 16:04:53
|
||||
*/
|
||||
|
||||
SET FOREIGN_KEY_CHECKS=0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for storm_forecast
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `storm_forecast`;
|
||||
CREATE TABLE `storm_forecast` (
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`stormid` varchar(20) NOT NULL,
|
||||
`forecast` mediumtext NOT NULL,
|
||||
`createtime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
`updatetime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 COMMENT='台风预报';
|
||||
@ -0,0 +1,29 @@
|
||||
/*
|
||||
Navicat MySQL Data Transfer
|
||||
|
||||
Source Server : 本地mysql
|
||||
Source Server Version : 50734
|
||||
Source Host : localhost:3306
|
||||
Source Database : weather
|
||||
|
||||
Target Server Type : MYSQL
|
||||
Target Server Version : 50734
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 2021-05-11 16:05:02
|
||||
*/
|
||||
|
||||
SET FOREIGN_KEY_CHECKS=0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for storm_track
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `storm_track`;
|
||||
CREATE TABLE `storm_track` (
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`stormid` varbinary(20) NOT NULL,
|
||||
`track` mediumtext NOT NULL,
|
||||
`createtime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
`updatetime` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4 COMMENT='台风实况和路径';
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,13 @@
|
||||
package com.rehome.weather;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
|
||||
@SpringBootTest
|
||||
class WeatherApplicationTests {
|
||||
|
||||
@Test
|
||||
void contextLoads() {
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Reference in New Issue