Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ jobs:
build:
strategy:
matrix:
java: [ '11', '17', '21' ]
java: [ '17', '21' ]
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v6
- name: Set up JDK ${{ matrix.Java }}
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@v5
with:
java-version: ${{ matrix.java }}
Expand All @@ -36,5 +36,4 @@ jobs:
- name: Build with Maven
run: mvn -B package --file pom.xml '-Dmaven.test.skip=true'
- name: Check spring-javaformat
if: matrix.java != '11'
run: mvn spring-javaformat:validate
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
## 项目介绍

当前项目基于java17, 1.8版本请查看分支genCode-3.3, 11版本请查看分支genCode-4.1
当前项目基于java17与Spring Boot 3,1.8版本请查看分支genCode-3.3, 11版本请查看分支genCode-4.1

本项目功能:

Expand Down
49 changes: 25 additions & 24 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,23 @@
<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.18</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>3.3.5</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<groupId>com.tlcsdm</groupId>
<artifactId>genCode</artifactId>
<version>4.1</version>
<version>5.0</version>
<packaging>jar</packaging>
<name>genCode</name>
<description>代码生成</description>
<properties>
<java.version>11</java.version>
<java.version>17</java.version>
<maven.build.timestamp.format>yyyy-MM-dd</maven.build.timestamp.format>
<log4j2.version>2.17.0</log4j2.version>
<druid-spring-boot-starter.version>1.2.27</druid-spring-boot-starter.version>
<druid-spring-boot-starter.version>1.2.23</druid-spring-boot-starter.version>
<mysql-connector-java.version>5.1.49</mysql-connector-java.version>
<mariadb-java-client.version>3.5.6</mariadb-java-client.version>
<ojdbc7.version>12.1.0.2</ojdbc7.version>
Expand All @@ -44,23 +44,20 @@
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-freemarker</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<exclusions>
<exclusion>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-undertow</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<!-- tlcsdm-common still depends on javax.servlet packages; include runtime API to keep those classes available -->
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>4.0.1</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>com.alibaba</groupId>
<artifactId>druid-spring-boot-starter</artifactId>
<artifactId>druid-spring-boot-3-starter</artifactId>
<version>${druid-spring-boot-starter.version}</version>
</dependency>
<dependency>
Expand Down Expand Up @@ -120,6 +117,10 @@
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>
</dependencies>

<build>
Expand Down
8 changes: 4 additions & 4 deletions src/main/java/com/tlcsdm/gen/base/BaseUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
import com.alibaba.druid.util.StringUtils;
import lombok.Cleanup;

import javax.servlet.ServletOutputStream;
import javax.servlet.http.Cookie;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import jakarta.servlet.ServletOutputStream;
import jakarta.servlet.http.Cookie;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import java.io.*;
import java.net.InetAddress;
import java.net.URLEncoder;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tlcsdm/gen/config/GenAutoConfig.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.tlcsdm.gen.config;

import com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure;
import com.alibaba.druid.spring.boot3.autoconfigure.DruidDataSourceAutoConfigure;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
Expand Down
8 changes: 5 additions & 3 deletions src/main/java/com/tlcsdm/gen/config/RemoveDruidAdConfig.java
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
package com.tlcsdm.gen.config;

import com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure;
import com.alibaba.druid.spring.boot.autoconfigure.properties.DruidStatProperties;
import com.alibaba.druid.spring.boot3.autoconfigure.DruidDataSourceAutoConfigure;
import com.alibaba.druid.spring.boot3.autoconfigure.properties.DruidStatProperties;
import com.alibaba.druid.util.Utils;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.boot.web.servlet.FilterRegistrationBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import javax.servlet.*;
import jakarta.servlet.*;
import java.io.IOException;

/**
Expand All @@ -31,6 +32,7 @@ public class RemoveDruidAdConfig {
* 方法名: removeDruidAdFilterRegistrationBean 方法描述: 除去页面底部的广告
* @return org.springframework.boot.web.servlet.FilterRegistrationBean
*/
@ConditionalOnBean(DruidStatProperties.class)
@Bean
public FilterRegistrationBean removeDruidAdFilterRegistrationBean(DruidStatProperties properties) {
// 获取web监控页面的参数
Expand Down
93 changes: 0 additions & 93 deletions src/main/java/com/tlcsdm/gen/config/RpcConfig.java

This file was deleted.

29 changes: 0 additions & 29 deletions src/main/java/com/tlcsdm/gen/config/UndertowPoolCustomizer.java

This file was deleted.

4 changes: 2 additions & 2 deletions src/main/java/com/tlcsdm/gen/controller/CommonController.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.servlet.ModelAndView;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.servlet.ModelAndView;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.view.freemarker.FreeMarkerConfigurer;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.view.freemarker.FreeMarkerConfigurer;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
Expand Down
35 changes: 0 additions & 35 deletions src/main/java/com/tlcsdm/gen/controller/GitInfoController.java

This file was deleted.

17 changes: 0 additions & 17 deletions src/main/java/com/tlcsdm/gen/domain/GenProperty.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,25 +26,8 @@ public class GenProperty {

private Boolean async;

private GenRpc rpc = new GenRpc();

private GenShutDown shutdown = new GenShutDown();

@Data
private static class GenRpc {

private Boolean enabled;

private Boolean rmi;

private int rmiPort;

private String rmiServiceName;

private Boolean httpInvoker;

}

@Data
private static class GenShutDown {

Expand Down
Loading