赞
踩
- <profiles>
- <profile>
- <id>jdk-17</id>
- <activation>
- <activeByDefault>true</activeByDefault>
- <jdk>17</jdk>
- </activation>
- <properties>
- <maven.compiler.source>17</maven.compiler.source>
- <maven.compiler.target>17</maven.compiler.target>
- <maven.compiler.compilerVersion>17</maven.compiler.compilerVersion>
- </properties>
- </profile>
- </profiles>
- <mirror>
- <id>
- alimaven
- </id>
- <mirrorOf>
- central
- </mirrorOf>
- <name>
- aliyun maven
- </name>
- <url>
- https://maven.aliyun.com/repository/central
- </url>
- </mirror>
jdk版本选择选择本地的jdk17 然后后面的java选项选17 如果17没出来要再点下 (idea bug或者是网的问题)
目前初步创建 父工程 名:juegejava
子模块名 :jjorder jjproduct jjuser
父工程 pom
- <?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>3.0.0-SNAPSHOT</version>
- <relativePath/> <!-- lookup parent from repository -->
- </parent>
- <groupId>com.juege.java</groupId>
- <artifactId>juejue-user</artifactId>
- <version>0.0.1-SNAPSHOT</version>
- <name>juegejava</name>
- <description>聚合服务</description>
- <packaging>pom</packaging>
-
- <modules>
- <module>jjuser</module>
- <module>jjproduct</module>
- <module>jjorder</module>
- </modules>
- </project>
子模块pom,不断更新中,springboot 3.0正式发布版还没出来 现在用的snapshot版本,springcloud
中的组件都是用的最新版本 (注释了某些组件的依赖 后面用到时再引入)
- <?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>3.0.0-SNAPSHOT</version>
- <relativePath/> <!-- lookup parent from repository -->
- </parent>
- <groupId>com.juege.java</groupId>
- <artifactId>juejue-order</artifactId>
- <version>0.0.1-SNAPSHOT</version>
- <name>jjorder</name>
- <description>juegejava</description>
- <properties>
- <java.version>17</java.version>
- <spring-cloud.version>2022.0.0-RC1</spring-cloud.version>
- <cloud-component.version>3.1.4</cloud-component.version>
- </properties>
- <dependencies>
- <dependency>
- <groupId>org.springframework.boot</groupId>
- <artifactId>spring-boot-starter-amqp</artifactId>
- </dependency>
- <!-- <dependency>-->
- <!-- <groupId>org.springframework.boot</groupId>-->
- <!-- <artifactId>spring-boot-starter-data-elasticsearch</artifactId>-->
- <!-- </dependency>-->
- <!-- <dependency>-->
- <!-- <groupId>org.springframework.boot</groupId>-->
- <!-- <artifactId>spring-boot-starter-data-jpa</artifactId>-->
- <!-- </dependency>-->
- <!-- <dependency>-->
- <!-- <groupId>org.springframework.boot</groupId>-->
- <!-- <artifactId>spring-boot-starter-data-mongodb</artifactId>-->
- <!-- </dependency>-->
- <!-- <dependency>-->
- <!-- <groupId>org.springframework.boot</groupId>-->
- <!-- <artifactId>spring-boot-starter-data-redis</artifactId>-->
- <!-- </dependency>-->
- <dependency>
- <groupId>org.springframework.boot</groupId>
- <artifactId>spring-boot-starter-quartz</artifactId>
- </dependency>
- <dependency>
- <groupId>mysql</groupId>
- <artifactId>mysql-connector-java</artifactId>
- </dependency>
- <dependency>
- <groupId>org.springframework.boot</groupId>
- <artifactId>spring-boot-starter-security</artifactId>
- </dependency>
- <dependency>
- <groupId>org.apache.kafka</groupId>
- <artifactId>kafka-streams</artifactId>
- </dependency>
- <!-- <dependency>-->
- <!-- <groupId>org.springframework.cloud</groupId>-->
- <!-- <artifactId>spring-cloud-starter-gateway</artifactId>-->
- <!-- <version>${cloud-component.version}</version>-->
- <!-- </dependency>-->
- <!-- <dependency>-->
- <!-- <groupId>org.springframework.cloud</groupId>-->
- <!-- <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>-->
- <!-- <version>${cloud-component.version}</version>-->
- <!-- </dependency>-->
- <!-- <dependency>-->
- <!-- <groupId>org.springframework.cloud</groupId>-->
- <!-- <artifactId>spring-cloud-starter-netflix-eureka-server</artifactId>-->
- <!-- <version>${cloud-component.version}</version>-->
- <!-- </dependency>-->
- <dependency>
- <groupId>org.springframework.cloud</groupId>
- <artifactId>spring-cloud-starter-openfeign</artifactId>
- <version>${cloud-component.version}</version>
- </dependency>
- <dependency>
- <groupId>org.springframework.kafka</groupId>
- <artifactId>spring-kafka</artifactId>
- </dependency>
-
- <dependency>
- <groupId>org.springframework.boot</groupId>
- <artifactId>spring-boot-devtools</artifactId>
- <scope>runtime</scope>
- <optional>true</optional>
- </dependency>
- <dependency>
- <groupId>org.springframework.boot</groupId>
- <artifactId>spring-boot-configuration-processor</artifactId>
- <optional>true</optional>
- </dependency>
- <dependency>
- <groupId>org.projectlombok</groupId>
- <artifactId>lombok</artifactId>
- <optional>true</optional>
- </dependency>
- <dependency>
- <groupId>org.springframework.boot</groupId>
- <artifactId>spring-boot-starter-test</artifactId>
- <scope>test</scope>
- </dependency>
- <!-- <dependency>-->
- <!-- <groupId>org.springframework.amqp</groupId>-->
- <!-- <artifactId>spring-rabbit-test</artifactId>-->
- <!-- <scope>test</scope>-->
- <!-- </dependency>-->
- <dependency>
- <groupId>org.springframework.kafka</groupId>
- <artifactId>spring-kafka-test</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.springframework.security</groupId>
- <artifactId>spring-security-test</artifactId>
- <scope>test</scope>
- </dependency>
- </dependencies>
- <dependencyManagement>
- <dependencies>
- <dependency>
- <groupId>org.springframework.cloud</groupId>
- <artifactId>spring-cloud-dependencies</artifactId>
- <version>${spring-cloud.version}</version>
- <type>pom</type>
- <scope>import</scope>
- </dependency>
- </dependencies>
- </dependencyManagement>
-
- <!-- <build>-->
- <!-- <plugins>-->
- <!-- <plugin>-->
- <!-- <groupId>org.springframework.boot</groupId>-->
- <!-- <artifactId>spring-boot-maven-plugin</artifactId>-->
- <!-- <version>2.7.5</version>-->
- <!-- <configuration>-->
- <!-- <excludes>-->
- <!-- <exclude>-->
- <!-- <groupId>org.projectlombok</groupId>-->
- <!-- <artifactId>lombok</artifactId>-->
- <!-- </exclude>-->
- <!-- </excludes>-->
- <!-- </configuration>-->
- <!-- </plugin>-->
- <!-- </plugins>-->
- <!-- </build>-->
- <repositories>
- <repository>
- <id>spring-milestones</id>
- <name>Spring Milestones</name>
- <url>https://repo.spring.io/milestone</url>
- <snapshots>
- <enabled>false</enabled>
- </snapshots>
- </repository>
- <repository>
- <id>spring-snapshots</id>
- <name>Spring Snapshots</name>
- <url>https://repo.spring.io/snapshot</url>
- <releases>
- <enabled>false</enabled>
- </releases>
- </repository>
- <repository>
- <id>netflix-candidates</id>
- <name>Netflix Candidates</name>
- <url>https://artifactory-oss.prod.netflix.net/artifactory/maven-oss-candidates</url>
- <snapshots>
- <enabled>false</enabled>
- </snapshots>
- </repository>
- </repositories>
- <pluginRepositories>
- <pluginRepository>
- <id>spring-milestones</id>
- <name>Spring Milestones</name>
- <url>https://repo.spring.io/milestone</url>
- <snapshots>
- <enabled>false</enabled>
- </snapshots>
- </pluginRepository>
- <pluginRepository>
- <id>spring-snapshots</id>
- <name>Spring Snapshots</name>
- <url>https://repo.spring.io/snapshot</url>
- <releases>
- <enabled>false</enabled>
- </releases>
- </pluginRepository>
- </pluginRepositories>
-
- </project>
密钥,一般默认就有
- docker update mysql --restart=always
-
- docker update redis --restart=always
- [root@localhost ~]# docker exec -it mysqlaa bash
-
- root@31e36f35d688:/# mysql -uroot -p
-
- 输入密码root
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。