QiuSW 3 năm trước cách đây
commit
eecb1fdc49

+ 28 - 0
codes.py

@@ -0,0 +1,28 @@
+# coding:utf-8
+# author:ila
+normal_code = 0  # 正常
+redirect_code = 301  # 跳转
+temporary_redirect_code = 302  # 暂时跳转
+
+empty_param_code = 10001  # 请求参数为空或错误
+validate_param_code = 10002  # 请求参数不规范
+is_not_json_code = 10003  # 数据格式不是json
+
+other_code = 10020  # 其它错误
+crud_error_code = 10021  # 数据库操作失败
+header_error_code = 10023  # 头部错误
+captcha_error_code = 10024  # 验证码错误
+id_exist_code = 10025  # id或用户名已存在
+id_notexist_code = 10026  # id或用户名不存在
+username_error_code = 10027  # 用户名错误
+password_error_code = 10028  # 密码错误
+file_notexist_code = 10029  # 上传文件不存在
+code_expired_code = 10030  # 验证码等错误
+
+token_error_code = 20001  # token错误
+token_expired_code = 20002  # token错误
+non_authorized_code = 20003  # 无权限
+
+system_error_code = 40001  # 系统级错误
+request_expired_code = 40002  # 请求已过期
+repeated_request_code = 40003  # 重复请求

+ 27 - 0
message.py

@@ -0,0 +1,27 @@
+# coding:utf-8
+# author:ila
+normal_message = "正常"
+redirect_message = "跳转"
+temporary_redirect_message = "暂时跳转"
+
+empty_param_message = "请求参数为空或错误"
+validate_param_message = "请求参数不规范"
+is_not_json_message = "数据格式不是json"
+
+other_message = "其它错误"
+crud_error_message = "数据库操作失败"
+header_error_message = "头部错误"
+captcha_error_message = "验证码错误"
+id_exist_message = "id或记录已存在"
+id_notexist_message = "id或记录不存在"
+file_notexist_message = "上传文件不存在"
+username_error_message = "用户名错误"
+password_error_message = "密码错误"
+
+token_error_message = "token错误"
+token_expired_message = "token错误"
+non_authorized_message = "无权限"
+
+system_error_message = "系统级错误"
+request_expired_message = "请求已过期"
+repeated_request_message = "重复请求"

+ 316 - 0
mvnw

@@ -0,0 +1,316 @@
+#!/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 /usr/local/etc/mavenrc ] ; then
+    . /usr/local/etc/mavenrc
+  fi
+
+  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="`\\unset -f command; \\command -v 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/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar"
+    else
+      jarUrl="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.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" || rm -f "$wrapperJarPath"
+        else
+            wget --http-user=$MVNW_USERNAME --http-password=$MVNW_PASSWORD "$jarUrl" -O "$wrapperJarPath" || rm -f "$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 \
+  $MAVEN_DEBUG_OPTS \
+  -classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \
+  "-Dmaven.home=${M2_HOME}" \
+  "-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \
+  ${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@"

+ 188 - 0
mvnw.cmd

@@ -0,0 +1,188 @@
+@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 "%USERPROFILE%\mavenrc_pre.bat" call "%USERPROFILE%\mavenrc_pre.bat" %*
+if exist "%USERPROFILE%\mavenrc_pre.cmd" call "%USERPROFILE%\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/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar"
+
+FOR /F "usebackq 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%/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.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 "%USERPROFILE%\mavenrc_post.bat" call "%USERPROFILE%\mavenrc_post.bat"
+if exist "%USERPROFILE%\mavenrc_post.cmd" call "%USERPROFILE%\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%
+
+cmd /C exit /B %ERROR_CODE%

+ 88 - 0
pom.xml

@@ -0,0 +1,88 @@
+<?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.7.3</version>
+        <relativePath/> <!-- lookup parent from repository -->
+    </parent>
+    <groupId>com.edu</groupId>
+    <artifactId>library</artifactId>
+    <version>0.0.1-SNAPSHOT</version>
+    <name>library</name>
+    <description>library</description>
+    <properties>
+        <java.version>11</java.version>
+    </properties>
+    <dependencies>
+        <dependency>
+            <groupId>org.springframework.boot</groupId>
+            <artifactId>spring-boot-starter-jdbc</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.springframework.boot</groupId>
+            <artifactId>spring-boot-starter-thymeleaf</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.2.2</version>
+        </dependency>
+
+        <dependency>
+            <groupId>mysql</groupId>
+            <artifactId>mysql-connector-java</artifactId>
+            <scope>runtime</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.springframework.boot</groupId>
+            <artifactId>spring-boot-starter-test</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>com.github.pagehelper</groupId>
+            <artifactId>pagehelper</artifactId>
+            <version>4.1.6</version>
+        </dependency>
+        <dependency>
+            <groupId>net.sf.json-lib</groupId>
+            <artifactId>json-lib</artifactId>
+            <version>2.4</version>
+            <classifier>jdk15</classifier>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.springframework.boot</groupId>
+                <artifactId>spring-boot-maven-plugin</artifactId>
+            </plugin>
+        </plugins>
+        <resources>
+            <resource>
+                <directory>src/main/java</directory>
+                <includes>
+                    <include>**/*.properties</include>
+                    <include>**/*.xml</include>
+                </includes>
+                <filtering>false</filtering>
+            </resource>
+            <resource>
+                <directory>src/main/resources</directory>
+                <includes>
+                    <include>**/*.properties</include>
+                    <include>**/*.xml</include>
+                </includes>
+                <filtering>false</filtering>
+            </resource>
+        </resources>
+    </build>
+
+</project>

+ 1 - 0
run.bat

@@ -0,0 +1 @@
+mvn spring-boot:run

+ 345 - 0
spring.log

@@ -0,0 +1,345 @@
+2022-09-02 09:26:15.551  INFO 17136 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 17136 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 09:26:15.562  INFO 17136 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 09:26:16.709  INFO 17136 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 09:26:16.709  INFO 17136 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 09:26:16.709  INFO 17136 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 09:26:16.709  INFO 17136 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 09:26:16.724  INFO 17136 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 09:26:16.724  INFO 17136 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 09:26:16.724  INFO 17136 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 09:26:16.864  INFO 17136 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 09:26:16.864  INFO 17136 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1244 ms
+2022-09-02 09:26:17.464  WARN 17136 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 09:26:17.594  INFO 17136 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 09:26:17.609  INFO 17136 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.648 seconds (JVM running for 3.8)
+2022-09-02 09:26:45.990  INFO 17136 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 09:26:45.992  INFO 17136 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 09:26:45.994  INFO 17136 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 10:35:05.722  INFO 9324 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 9324 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 10:35:05.722  INFO 9324 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 10:35:06.638  INFO 9324 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 10:35:06.638  INFO 9324 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 10:35:06.638  INFO 9324 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 10:35:06.638  INFO 9324 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 10:35:06.638  INFO 9324 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 10:35:06.653  INFO 9324 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 10:35:06.653  INFO 9324 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 10:35:06.743  INFO 9324 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 10:35:06.743  INFO 9324 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 977 ms
+2022-09-02 10:35:07.253  WARN 9324 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 10:35:07.328  WARN 9324 --- [main] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.context.ApplicationContextException: Failed to start bean 'webServerStartStop'; nested exception is org.springframework.boot.web.server.PortInUseException: Port 8888 is already in use
+2022-09-02 10:35:07.343  INFO 9324 --- [main] o.apache.catalina.core.StandardService   : Stopping service [Tomcat]
+2022-09-02 10:35:07.343  INFO 9324 --- [main] ConditionEvaluationReportLoggingListener : 
+
+Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
+2022-09-02 10:35:07.358 ERROR 9324 --- [main] o.s.b.d.LoggingFailureAnalysisReporter   : 
+
+***************************
+APPLICATION FAILED TO START
+***************************
+
+Description:
+
+Web server failed to start. Port 8888 was already in use.
+
+Action:
+
+Identify and stop the process that's listening on port 8888 or configure this application to listen on another port.
+
+2022-09-02 10:40:07.306  INFO 19520 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 19520 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 10:40:07.306  INFO 19520 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 10:40:08.763  INFO 19520 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 10:40:08.765  INFO 19520 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 10:40:08.767  INFO 19520 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 10:40:08.767  INFO 19520 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 10:40:08.774  INFO 19520 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 10:40:08.790  INFO 19520 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 10:40:08.791  INFO 19520 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 10:40:08.921  INFO 19520 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 10:40:08.922  INFO 19520 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1551 ms
+2022-09-02 10:40:09.472  WARN 19520 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 10:40:09.564  INFO 19520 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 10:40:09.575  INFO 19520 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.715 seconds (JVM running for 3.077)
+2022-09-02 10:40:41.227  INFO 19520 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 10:40:41.229  INFO 19520 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 10:40:41.232  INFO 19520 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 10:41:38.490  INFO 14552 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 14552 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 10:41:38.493  INFO 14552 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 10:41:39.592  INFO 14552 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 10:41:39.594  INFO 14552 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 10:41:39.594  INFO 14552 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 10:41:39.595  INFO 14552 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 10:41:39.598  INFO 14552 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 10:41:39.609  INFO 14552 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 10:41:39.610  INFO 14552 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 10:41:39.698  INFO 14552 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 10:41:39.699  INFO 14552 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1157 ms
+2022-09-02 10:41:40.210  WARN 14552 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 10:41:40.303  INFO 14552 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 10:41:40.314  INFO 14552 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.279 seconds (JVM running for 2.77)
+2022-09-02 10:41:43.220  INFO 14552 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 10:41:43.221  INFO 14552 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 10:41:43.223  INFO 14552 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 10:46:58.442  INFO 10320 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 10320 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 10:46:58.444  INFO 10320 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 10:46:59.461  INFO 10320 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 10:46:59.469  INFO 10320 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 10:46:59.469  INFO 10320 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 10:46:59.470  INFO 10320 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 10:46:59.473  INFO 10320 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 10:46:59.484  INFO 10320 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 10:46:59.485  INFO 10320 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 10:46:59.583  INFO 10320 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 10:46:59.583  INFO 10320 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1093 ms
+2022-09-02 10:47:00.097  WARN 10320 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 10:47:00.208  INFO 10320 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 10:47:00.220  INFO 10320 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.42 seconds (JVM running for 3.84)
+2022-09-02 10:51:32.594  INFO 10320 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 10:51:32.595  INFO 10320 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 10:51:32.598  INFO 10320 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 10:54:11.598  INFO 4296 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 4296 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 10:54:11.604  INFO 4296 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 10:54:13.001  INFO 4296 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 10:54:13.002  INFO 4296 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 10:54:13.003  INFO 4296 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 10:54:13.003  INFO 4296 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 10:54:13.008  INFO 4296 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 10:54:13.018  INFO 4296 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 10:54:13.018  INFO 4296 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 10:54:13.115  INFO 4296 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 10:54:13.115  INFO 4296 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1413 ms
+2022-09-02 10:54:13.713  WARN 4296 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 10:54:13.830  INFO 4296 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 10:54:13.845  INFO 4296 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 3.111 seconds (JVM running for 4.163)
+2022-09-02 10:54:56.414  INFO 21836 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 21836 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 10:54:56.417  INFO 21836 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 10:54:57.378  INFO 21836 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 10:54:57.380  INFO 21836 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 10:54:57.381  INFO 21836 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 10:54:57.381  INFO 21836 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 10:54:57.385  INFO 21836 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 10:54:57.393  INFO 21836 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 10:54:57.393  INFO 21836 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 10:54:57.473  INFO 21836 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 10:54:57.474  INFO 21836 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 999 ms
+2022-09-02 10:54:57.953  WARN 21836 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 10:54:58.056  INFO 21836 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 10:54:58.067  INFO 21836 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.139 seconds (JVM running for 2.944)
+2022-09-02 10:55:01.514  INFO 21836 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 10:55:01.516  INFO 21836 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 10:55:01.517  INFO 21836 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 10:56:14.054  INFO 21372 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 21372 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 10:56:14.057  INFO 21372 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 10:56:14.959  INFO 21372 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 10:56:14.961  INFO 21372 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 10:56:14.961  INFO 21372 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 10:56:14.961  INFO 21372 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 10:56:14.964  INFO 21372 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 10:56:14.973  INFO 21372 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 10:56:14.974  INFO 21372 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 10:56:15.075  INFO 21372 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 10:56:15.076  INFO 21372 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 952 ms
+2022-09-02 10:56:15.556  WARN 21372 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 10:56:15.658  INFO 21372 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 10:56:15.671  INFO 21372 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.137 seconds (JVM running for 3.333)
+2022-09-02 10:56:20.506  INFO 21372 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 10:56:20.507  INFO 21372 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 10:56:20.509  INFO 21372 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 10:56:20.608  INFO 21372 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 10:56:21.014  INFO 21372 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.
+2022-09-02 10:58:30.358  INFO 21372 --- [SpringApplicationShutdownHook] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Shutdown initiated...
+2022-09-02 10:58:30.369  INFO 21372 --- [SpringApplicationShutdownHook] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Shutdown completed.
+2022-09-02 10:58:35.350  INFO 12952 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 12952 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 10:58:35.352  INFO 12952 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 10:58:36.261  INFO 12952 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 10:58:36.262  INFO 12952 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 10:58:36.262  INFO 12952 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 10:58:36.263  INFO 12952 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 10:58:36.266  INFO 12952 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 10:58:36.274  INFO 12952 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 10:58:36.275  INFO 12952 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 10:58:36.356  INFO 12952 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 10:58:36.356  INFO 12952 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 951 ms
+2022-09-02 10:58:36.829  WARN 12952 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 10:58:36.927  INFO 12952 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 10:58:36.939  INFO 12952 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.107 seconds (JVM running for 3.004)
+2022-09-02 11:00:19.789  INFO 12952 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 11:00:19.791  INFO 12952 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 11:00:19.792  INFO 12952 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 11:00:19.889  INFO 12952 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 11:00:20.218  INFO 12952 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.
+2022-09-02 11:00:29.358  INFO 12952 --- [SpringApplicationShutdownHook] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Shutdown initiated...
+2022-09-02 11:00:29.368  INFO 12952 --- [SpringApplicationShutdownHook] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Shutdown completed.
+2022-09-02 11:00:33.024  INFO 14628 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 14628 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 11:00:33.028  INFO 14628 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 11:00:33.914  INFO 14628 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 11:00:33.915  INFO 14628 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 11:00:33.915  INFO 14628 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 11:00:33.915  INFO 14628 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 11:00:33.918  INFO 14628 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 11:00:33.926  INFO 14628 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 11:00:33.927  INFO 14628 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 11:00:34.012  INFO 14628 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 11:00:34.013  INFO 14628 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 939 ms
+2022-09-02 11:00:34.495  WARN 14628 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 11:00:34.589  INFO 14628 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 11:00:34.600  INFO 14628 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.032 seconds (JVM running for 2.864)
+2022-09-02 11:00:39.000  INFO 14628 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 11:00:39.001  INFO 14628 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 11:00:39.002  INFO 14628 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 0 ms
+2022-09-02 11:00:39.108  INFO 14628 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 11:00:39.388  INFO 14628 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.
+2022-09-02 11:01:10.881  INFO 14628 --- [SpringApplicationShutdownHook] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Shutdown initiated...
+2022-09-02 11:01:10.899  INFO 14628 --- [SpringApplicationShutdownHook] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Shutdown completed.
+2022-09-02 11:01:19.090  INFO 15896 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 15896 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 11:01:19.092  INFO 15896 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 11:01:20.140  INFO 15896 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 11:01:20.141  INFO 15896 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 11:01:20.142  INFO 15896 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 11:01:20.143  INFO 15896 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 11:01:20.148  INFO 15896 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 11:01:20.158  INFO 15896 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 11:01:20.159  INFO 15896 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 11:01:20.240  INFO 15896 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 11:01:20.240  INFO 15896 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1100 ms
+2022-09-02 11:01:20.710  WARN 15896 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 11:01:20.840  INFO 15896 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 11:01:20.851  INFO 15896 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.174 seconds (JVM running for 2.54)
+2022-09-02 11:01:23.432  INFO 15896 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 11:01:23.433  INFO 15896 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 11:01:23.436  INFO 15896 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 11:01:23.534  INFO 15896 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 11:01:23.800  INFO 15896 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.
+2022-09-02 11:02:23.936  INFO 13856 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 13856 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 11:02:23.940  INFO 13856 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 11:02:24.977  INFO 13856 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 11:02:24.978  INFO 13856 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 11:02:24.979  INFO 13856 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 11:02:24.979  INFO 13856 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 11:02:24.982  INFO 13856 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 11:02:24.993  INFO 13856 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 11:02:24.993  INFO 13856 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 11:02:25.076  INFO 13856 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 11:02:25.077  INFO 13856 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1090 ms
+2022-09-02 11:02:25.562  WARN 13856 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 11:02:25.645  INFO 13856 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 11:02:25.654  INFO 13856 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.114 seconds (JVM running for 2.454)
+2022-09-02 11:02:31.175  INFO 13856 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 11:02:31.177  INFO 13856 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 11:02:31.178  INFO 13856 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 11:02:31.274  INFO 13856 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 11:02:31.529  INFO 13856 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.
+2022-09-02 11:03:34.734  INFO 5352 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 5352 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 11:03:34.736  INFO 5352 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 11:03:35.737  INFO 5352 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 11:03:35.739  INFO 5352 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 11:03:35.739  INFO 5352 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 11:03:35.739  INFO 5352 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 11:03:35.742  INFO 5352 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 11:03:35.753  INFO 5352 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 11:03:35.754  INFO 5352 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 11:03:35.847  INFO 5352 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 11:03:35.847  INFO 5352 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1066 ms
+2022-09-02 11:03:36.307  WARN 5352 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 11:03:36.387  INFO 5352 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 11:03:36.397  INFO 5352 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.067 seconds (JVM running for 2.433)
+2022-09-02 11:03:42.517  INFO 5352 --- [http-nio-8888-exec-2] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 11:03:42.519  INFO 5352 --- [http-nio-8888-exec-2] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 11:03:42.520  INFO 5352 --- [http-nio-8888-exec-2] o.s.web.servlet.DispatcherServlet        : Completed initialization in 0 ms
+2022-09-02 11:03:42.618  INFO 5352 --- [http-nio-8888-exec-2] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 11:03:42.882  INFO 5352 --- [http-nio-8888-exec-2] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.
+2022-09-02 11:05:52.786  INFO 9640 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 9640 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 11:05:52.788  INFO 9640 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 11:05:53.810  INFO 9640 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 11:05:53.812  INFO 9640 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 11:05:53.813  INFO 9640 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 11:05:53.813  INFO 9640 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 11:05:53.816  INFO 9640 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 11:05:53.833  INFO 9640 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 11:05:53.834  INFO 9640 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 11:05:53.913  INFO 9640 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 11:05:53.913  INFO 9640 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1077 ms
+2022-09-02 11:05:54.363  WARN 9640 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 11:05:54.445  INFO 9640 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 11:05:54.455  INFO 9640 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.072 seconds (JVM running for 2.402)
+2022-09-02 11:05:59.508  INFO 9640 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 11:05:59.509  INFO 9640 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 11:05:59.511  INFO 9640 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 11:05:59.612  INFO 9640 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 11:05:59.884  INFO 9640 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.
+2022-09-02 11:07:30.401  INFO 14308 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 14308 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 11:07:30.403  INFO 14308 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 11:07:31.402  INFO 14308 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 11:07:31.404  INFO 14308 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 11:07:31.404  INFO 14308 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 11:07:31.405  INFO 14308 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 11:07:31.408  INFO 14308 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 11:07:31.418  INFO 14308 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 11:07:31.419  INFO 14308 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 11:07:31.509  INFO 14308 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 11:07:31.510  INFO 14308 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1059 ms
+2022-09-02 11:07:31.972  WARN 14308 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 11:07:32.054  INFO 14308 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 11:07:32.064  INFO 14308 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.082 seconds (JVM running for 2.437)
+2022-09-02 11:07:46.554  INFO 14308 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 11:07:46.556  INFO 14308 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 11:07:46.557  INFO 14308 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 11:07:46.654  INFO 14308 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 11:07:46.919  INFO 14308 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.
+2022-09-02 11:09:01.405  INFO 7860 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 7860 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 11:09:01.407  INFO 7860 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 11:09:02.413  INFO 7860 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 11:09:02.415  INFO 7860 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 11:09:02.416  INFO 7860 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 11:09:02.416  INFO 7860 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 11:09:02.419  INFO 7860 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 11:09:02.429  INFO 7860 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 11:09:02.430  INFO 7860 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 11:09:02.543  INFO 7860 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 11:09:02.544  INFO 7860 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1091 ms
+2022-09-02 11:09:03.004  WARN 7860 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 11:09:03.086  INFO 7860 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 11:09:03.096  INFO 7860 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.107 seconds (JVM running for 2.458)
+2022-09-02 11:09:05.954  INFO 7860 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 11:09:05.956  INFO 7860 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 11:09:05.959  INFO 7860 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 11:09:06.067  INFO 7860 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 11:09:06.336  INFO 7860 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.
+2022-09-02 11:10:03.008  INFO 11008 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 11008 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 11:10:03.011  INFO 11008 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 11:10:03.995  INFO 11008 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 11:10:03.997  INFO 11008 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 11:10:03.998  INFO 11008 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 11:10:03.998  INFO 11008 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 11:10:04.001  INFO 11008 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 11:10:04.011  INFO 11008 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 11:10:04.012  INFO 11008 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 11:10:04.101  INFO 11008 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 11:10:04.101  INFO 11008 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1045 ms
+2022-09-02 11:10:04.555  WARN 11008 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 11:10:04.636  INFO 11008 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 11:10:04.645  INFO 11008 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.044 seconds (JVM running for 2.427)
+2022-09-02 11:10:13.876  INFO 11008 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 11:10:13.878  INFO 11008 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 11:10:13.879  INFO 11008 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 11:10:13.978  INFO 11008 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 11:10:14.242  INFO 11008 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.
+2022-09-02 11:12:20.855  INFO 5412 --- [main] com.edu.library.LibraryApplication       : Starting LibraryApplication using Java 11 on mi with PID 5412 (E:\laxr\library\target\classes started by Qiu in E:\laxr\library)
+2022-09-02 11:12:20.857  INFO 5412 --- [main] com.edu.library.LibraryApplication       : No active profile set, falling back to 1 default profile: "default"
+2022-09-02 11:12:21.906  INFO 5412 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8888 (http)
+2022-09-02 11:12:21.908  INFO 5412 --- [main] o.a.catalina.core.AprLifecycleListener   : Loaded Apache Tomcat Native library [1.2.33] using APR version [1.7.0].
+2022-09-02 11:12:21.909  INFO 5412 --- [main] o.a.catalina.core.AprLifecycleListener   : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true], UDS [true].
+2022-09-02 11:12:21.909  INFO 5412 --- [main] o.a.catalina.core.AprLifecycleListener   : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
+2022-09-02 11:12:21.913  INFO 5412 --- [main] o.a.catalina.core.AprLifecycleListener   : OpenSSL successfully initialized [OpenSSL 1.1.1o  3 May 2022]
+2022-09-02 11:12:21.923  INFO 5412 --- [main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
+2022-09-02 11:12:21.923  INFO 5412 --- [main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.65]
+2022-09-02 11:12:22.002  INFO 5412 --- [main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
+2022-09-02 11:12:22.003  INFO 5412 --- [main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 1097 ms
+2022-09-02 11:12:22.465  WARN 5412 --- [main] ion$DefaultTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
+2022-09-02 11:12:22.546  INFO 5412 --- [main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8888 (http) with context path ''
+2022-09-02 11:12:22.568  INFO 5412 --- [main] com.edu.library.LibraryApplication       : Started LibraryApplication in 2.129 seconds (JVM running for 2.473)
+2022-09-02 11:12:29.495  INFO 5412 --- [http-nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
+2022-09-02 11:12:29.496  INFO 5412 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
+2022-09-02 11:12:29.498  INFO 5412 --- [http-nio-8888-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
+2022-09-02 11:12:29.602  INFO 5412 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Starting...
+2022-09-02 11:12:29.858  INFO 5412 --- [http-nio-8888-exec-1] com.zaxxer.hikari.HikariDataSource       : defaultDataSource - Start completed.

+ 0 - 0
sql/library.sql


+ 16 - 0
src/main/java/com/edu/library/LibraryApplication.java

@@ -0,0 +1,16 @@
+package com.edu.library;
+
+import org.mybatis.spring.annotation.MapperScan;
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+
+@SpringBootApplication
+@MapperScan("com.edu.library.dao")
+public class LibraryApplication {
+
+
+    public static void main(String[] args) {
+        SpringApplication.run(LibraryApplication.class, args);
+    }
+
+}

+ 108 - 0
src/main/java/com/edu/library/controller/UserLoginController.java

@@ -0,0 +1,108 @@
+package com.edu.library.controller;
+
+import com.edu.library.entity.UserEntity;
+import net.sf.json.JSONObject;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import com.edu.library.service.UserService;
+
+import java.util.Objects;
+
+@RestController
+@RequestMapping(value = "/user")
+public class UserLoginController {
+    @Autowired
+    private UserService userService;
+
+
+    @RequestMapping(value = "/login", method = RequestMethod.POST)
+    private JSONObject login(@RequestBody UserEntity ul) {
+        var ret = userService.login(ul.getUsername(), ul.getPassword());
+
+        JSONObject resp = new JSONObject();
+        if (Objects.equals(ret, null)) {
+            resp.put("code", 500);
+            resp.put("msg", "username or password is wrong.");
+            return resp;
+        }
+
+        if (Objects.equals(ret.getUsername(), ul.getUsername())) {
+            resp.put("code", 200);
+            resp.put("msg", "Successed");
+        } else {
+            resp.put("code", 401);
+            resp.put("msg", "Failed");
+        }
+        return resp;
+    }
+
+    @RequestMapping(value = "/add", method = RequestMethod.POST)
+    private JSONObject add(@RequestBody UserEntity ue) {
+        JSONObject resp = new JSONObject();
+
+        try {
+            int insertId = userService.insert(ue.getUsername(), ue.getPassword());
+            if (insertId == 1) {
+                resp.put("code", 200);
+                resp.put("msg", "添加新用户成功.");
+
+            } else {
+                resp.put("code", 10021);
+                resp.put("msg", "添加新用户失败.");
+            }
+        } catch (Exception e) {
+            System.out.println(e);
+            resp.put("code", 10025);
+            resp.put("msg", "用户已存在.");
+        }
+        return resp;
+    }
+
+
+    @RequestMapping(value = "/update", method = RequestMethod.POST)
+    private JSONObject update(@RequestBody UserEntity ue) {
+        JSONObject resp = new JSONObject();
+//        System.out.println("id============>"+ue.getId());
+        try {
+
+            int insertId = userService.update(ue.getPassword(), ue.getId());
+            if (insertId == 1) {
+                resp.put("code", 200);
+                resp.put("msg", "更新用户成功.");
+
+            } else {
+                resp.put("code", 10021);
+                resp.put("msg", "更新新用户失败.");
+            }
+        } catch (Exception e) {
+            System.out.println(e);
+            resp.put("code", 10025);
+            resp.put("msg", "用户不存在.");
+        }
+        return resp;
+    }
+
+    @RequestMapping(value = "/delete", method = RequestMethod.POST)
+    private JSONObject delete(@RequestBody UserEntity ue) {
+        JSONObject resp = new JSONObject();
+
+        try {
+            int insertId = userService.delete(ue.getId());
+            if (insertId == 1) {
+                resp.put("code", 200);
+                resp.put("msg", "删除用户成功.");
+
+            } else {
+                resp.put("code", 10021);
+                resp.put("msg", "删除新用户失败.");
+            }
+        } catch (Exception e) {
+            resp.put("code", 10025);
+            resp.put("msg", "用户不存在.");
+        }
+        return resp;
+    }
+
+
+}

+ 24 - 0
src/main/java/com/edu/library/dao/UserDao.java

@@ -0,0 +1,24 @@
+package com.edu.library.dao;
+
+import com.edu.library.entity.UserEntity;
+import org.apache.catalina.User;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Repository;
+
+@Repository
+@Mapper
+public interface UserDao {
+    @Autowired(required = false)
+    UserEntity login(@Param("username") String username, @Param("password") String password);
+
+    int insert(@Param("username") String username, @Param("password") String password);
+
+    int update(@Param("password") String password, @Param("id") int id);
+
+    int delete(@Param("id") int id);
+
+    UserEntity select(@Param("id") int id);
+}
+

+ 35 - 0
src/main/java/com/edu/library/entity/UserEntity.java

@@ -0,0 +1,35 @@
+package com.edu.library.entity;
+
+public class UserEntity {
+    private int id;
+    private String username;
+    private String password;
+    private String gender;
+    private String email;
+    private String phone;
+
+
+    public void setId(int id) {
+        this.id = id;
+    }
+
+    public void setUsername(String username) {
+        this.username = username;
+    }
+
+    public void setPassword(String password) {
+        this.password = password;
+    }
+
+    public int getId() {
+        return id;
+    }
+
+    public String getUsername() {
+        return username;
+    }
+
+    public String getPassword() {
+        return password;
+    }
+}

+ 17 - 0
src/main/java/com/edu/library/service/IMPL/IUserService.java

@@ -0,0 +1,17 @@
+package com.edu.library.service.IMPL;
+
+import com.edu.library.entity.UserEntity;
+import org.apache.catalina.User;
+
+public interface IUserService {
+    int insert(String username, String password);
+
+    int update(String password, int id);
+
+    int delete(int id);
+
+    UserEntity select(int id);
+
+    UserEntity login(String username, String password);
+
+}

+ 45 - 0
src/main/java/com/edu/library/service/UserService.java

@@ -0,0 +1,45 @@
+package com.edu.library.service;
+
+import com.edu.library.dao.UserDao;
+import com.edu.library.entity.UserEntity;
+import com.edu.library.service.IMPL.IUserService;
+import org.apache.catalina.User;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+
+@Service
+public class UserService implements IUserService {
+    @Autowired
+    private final UserDao userDao;
+
+    public UserService(UserDao LoginDao) {
+        this.userDao = LoginDao;
+    }
+
+    @Override
+    public UserEntity login(String username, String password) {
+        return userDao.login(username, password);
+    }
+
+    @Override
+    public int insert(String username, String password) {
+        return userDao.insert(username, password);
+    }
+
+    @Override
+    public int update(String password, int id) {
+        return userDao.update(password, id);
+    }
+
+    @Override
+    public int delete(int id) {
+        return userDao.delete(id);
+    }
+
+    @Override
+    public UserEntity select(int id) {
+        return userDao.select(id);
+    }
+}
+

+ 7 - 0
src/main/resources/application.properties

@@ -0,0 +1,7 @@
+spring.application.name=library
+server.port=8888
+spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
+spring.datasource.name=defaultDataSource
+spring.datasource.url=jdbc:mysql://127.0.0.1:3306/library?serverTimezone=UTC
+spring.datasource.username=root
+spring.datasource.password=123456

+ 24 - 0
src/main/resources/application.yml

@@ -0,0 +1,24 @@
+spring:
+  datasource:
+    driver-class-name: com.mysql.cj.jdbc.Driver
+    url: jbbc:mysql://127.0.0.1:3306/library?useUnicode=true&characterEncoding=utf8&autoReconnect=true&failOverReadOnly=false&serverTimezone=Asia/Shanghai&useSSL=true
+
+    username: root
+    password: 123456
+  servlet:
+    multipart:
+      max-file-size: 10MB
+      max-request-size: 100MB
+
+mybatis:
+  mapper-locations: classpath:mapper/*.xml
+  type-aliases-package: com.example.demo.entity
+  configuration:
+    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
+
+logging:
+  file:
+    path: E:/laxr/library
+
+server:
+  port: 8888

+ 35 - 0
src/main/resources/mapper/UserMapper.xml

@@ -0,0 +1,35 @@
+<?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.edu.library.dao.UserDao">
+    <resultMap id="BaseResultMap" type="com.edu.library.entity.UserEntity">
+    </resultMap>
+
+    <select id="login" resultMap="BaseResultMap" parameterType="com.edu.library.entity.UserEntity">
+        SELECT *
+        from user
+        where username = #{username}
+          and password = #{password}
+    </select>
+
+    <insert id="insert" parameterType="com.edu.library.entity.UserEntity">
+        insert into user(username, password)
+        values (#{username}, #{password})
+    </insert>
+    <update id="update" parameterType="com.edu.library.entity.UserEntity">
+        update user
+        set password=#{password}
+        where id = #{id}
+    </update>
+
+    <delete id="delete" parameterType="com.edu.library.entity.UserEntity">
+        delete
+        from user
+        where id = #{id}
+    </delete>
+    <select id="select" resultMap="BaseResultMap" parameterType="com.edu.library.entity.UserEntity">
+
+        select *
+        from user
+        where id = #{id};
+    </select>
+</mapper>

+ 13 - 0
src/test/java/com/edu/library/LibraryApplicationTests.java

@@ -0,0 +1,13 @@
+package com.edu.library;
+
+import org.junit.jupiter.api.Test;
+import org.springframework.boot.test.context.SpringBootTest;
+
+@SpringBootTest
+class LibraryApplicationTests {
+
+    @Test
+    void contextLoads() {
+    }
+
+}

+ 1 - 0
test.txt

@@ -0,0 +1 @@
+curl -X POST -d "username=admin&password=admin" "http://127.0.0.1:8888/Login/login1?username=admin&password=admin"