This is an automated email from the ASF dual-hosted git repository.

jinsongzhou pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/amoro.git


The following commit(s) were added to refs/heads/master by this push:
     new 6285291ab [Improvement] Improve project build guide (#2860)
6285291ab is described below

commit 6285291ab83ea19c80a3e896fba8793ab59fe617
Author: ZhouJinsong <[email protected]>
AuthorDate: Thu May 23 20:15:50 2024 +0800

    [Improvement] Improve project build guide (#2860)
    
    * Improve project build guide
    
    * Link the build guide to project readme in CONTRIBUTING.md
    
    * Improve some description
---
 CONTRIBUTING.md                 | 32 +-------------------------------
 README.md                       | 23 +++++++++--------------
 docs/admin-guides/deployment.md |  2 +-
 3 files changed, 11 insertions(+), 46 deletions(-)

diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 07d7faf53..440186e78 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -80,37 +80,7 @@ for reference.
 
 ## Building the Project Locally
 
-Amoro is built using Maven with Java 1.8 and Java 17(only for 
`amoro-mixed-format/amoro-mixed-format-trino` module).
-
-* To build Trino module need config `toolchains.xml` in `${user.home}/.m2/` 
dir, the content is
-
-```
-<?xml version="1.0" encoding="UTF-8"?>
-<toolchains>
-    <toolchain>
-        <type>jdk</type>
-        <provides>
-            <version>17</version>
-            <vendor>sun</vendor>
-        </provides>
-        <configuration>
-            <jdkHome>${YourJDK17Home}</jdkHome>
-        </configuration>
-    </toolchain>
-</toolchains>
-```
-
-* To invoke a build and run tests: `mvn package -P toolchain`
-* To skip tests: `mvn -DskipTests package -P toolchain`
-* To package without trino module and JAVA 17 dependency: `mvn clean package 
-DskipTests`
-* To build with hadoop 2.x(the default is 3.x) `mvn clean package -DskipTests 
-Dhadoop=v2`
-* To indicate Flink version for optimizer (the default is 1.18.1): `mvn clean 
package -Dflink-optimizer.flink-version=1.15.4`. If the version of Flink is 
below 1.15.0, you also need to add the `-Pflink-pre-1.15` parameter: `mvn clean 
package -Pflink-pre-1.15 -Dflink-optimizer.flink-version=1.14.6`.
-  `mvn clean package -Pflink-pre-1.15 -Dflink-optimizer.flink-version=1.14.6 
-DskipTests`
-
->Spotless is skipped by default in `trino` module. So if you want to perform 
checkstyle when building `trino` module, you must be in a Java 17 environment.
-
-* To invoke a build include `amoro-mixed-format/amoro-mixed-format-trino` 
module in Java 17 environment: `mvn clean package -DskipTests -P 
trino-spotless,build-mixed-format-trino`
-* To only build `amoro-mixed-format/amoro-mixed-format-trino` and its 
dependent modules in Java 17 environment: `mvn clean package -DskipTests -P 
trino-spotless,build-mixed-format-trino -pl 
'amoro-mixed-format/amoro-mixed-format-trino' -am`
+[Build Guide](https://github.com/apache/amoro?tab=readme-ov-file#building) can 
be found in GitHub readme.
 
 ## Code suggestions
 
diff --git a/README.md b/README.md
index 41f158dce..af1d1ff2b 100644
--- a/README.md
+++ b/README.md
@@ -110,9 +110,16 @@ Amoro contains modules as below:
 
 ## Building
 
-Amoro is built using Maven with Java 1.8 and Java 17(only for 
`amoro-mixed-format/amoro-mixed-format-trino` module).
+Amoro is built using Maven with JDK 8 and JDK 17(only for 
`amoro-mixed-format/amoro-mixed-format-trino` module).
 
-* To build Trino module need config `toolchains.xml` in `${user.home}/.m2/` 
dir, the content is
+* Build all modules without `amoro-mixed-format-trino`: `mvn clean package`
+* Build and skip tests: `mvn clean package -DskipTests `
+* Build with hadoop 2.x(the default is 3.x) dependencies: `mvn clean package 
-DskipTests -Dhadoop=v2`
+* Specify Flink version for Flink optimizer(the default is 1.18.1): `mvn clean 
package -DskipTests -Dflink-optimizer.flink-version=1.15.4`
+  * If the version of Flink is below 1.15.0, you also need to add the 
`-Pflink-pre-1.15` parameter: `mvn clean package -DskipTests -Pflink-pre-1.15 
-Dflink-optimizer.flink-version=1.14.6`
+* Specify Spark version for Spark optimizer(the default is 3.3.3): `mvn clean 
package -DskipTests -Dspark-optimizer.spark-version=3.2.2`
+* Build `amoro-mixed-format-trino` module under JDK 17: `mvn clean package 
-DskipTests -Ptrino-spotless,build-mixed-format-trino -pl 
'amoro-mixed-format/amoro-mixed-format-trino' -am`.
+* Build all modules: `mvn clean package -DskipTests 
-Ptoolchain,build-mixed-format-trino`, besides you need config `toolchains.xml` 
in `${user.home}/.m2/` dir with content below.
 
 ```
 <?xml version="1.0" encoding="UTF-8"?>
@@ -130,18 +137,6 @@ Amoro is built using Maven with Java 1.8 and Java 17(only 
for `amoro-mixed-forma
 </toolchains>
 ```
 
-* To invoke a build and run tests: `mvn package -P toolchain`
-* To skip tests: `mvn -DskipTests package -P toolchain`
-* To package without trino module and JAVA 17 dependency: `mvn clean package 
-DskipTests`
-* To build with hadoop 2.x(the default is 3.x) `mvn clean package -DskipTests 
-Dhadoop=v2`
-* To indicate Flink version for optimizer (the default is 1.18.1): `mvn clean 
package -Dflink-optimizer.flink-version=1.15.4`. If the version of Flink is 
below 1.15.0, you also need to add the `-Pflink-pre-1.15` parameter: `mvn clean 
package -Pflink-pre-1.15 -Dflink-optimizer.flink-version=1.14.6`.
-  `mvn clean package -Pflink-pre-1.15 -Dflink-optimizer.flink-version=1.14.6 
-DskipTests`
-
->Spotless is skipped by default in `trino` module. So if you want to perform 
checkstyle when building `trino` module, you must be in a Java 17 environment.
-
-* To invoke a build include `amoro-mixed-format/amoro-mixed-format-trino` 
module in Java 17 environment: `mvn clean package -DskipTests -P 
trino-spotless,build-mixed-format-trino`
-* To only build `amoro-mixed-format/amoro-mixed-format-trino` and its 
dependent modules in Java 17 environment: `mvn clean package -DskipTests -P 
trino-spotless,build-mixed-format-trino -pl 
'amoro-mixed-format/amoro-mixed-format-trino' -am`
-
 ## Quickstart
 
 Visit 
[https://amoro.apache.org/quick-demo/](https://amoro.apache.org/quick-demo/) to 
quickly
diff --git a/docs/admin-guides/deployment.md b/docs/admin-guides/deployment.md
index 543524737..fe528b05f 100644
--- a/docs/admin-guides/deployment.md
+++ b/docs/admin-guides/deployment.md
@@ -63,7 +63,7 @@ If the Flink version in the 
amoro-ams/amoro-ams-optimizer/amoro-optimizer-flink
 for example `mvn clean package -Pflink-pre-1.15 
-Dflink-optimizer.flink-version=1.14.6 -DskipTests` to compile.
 
 If you need to compile the Trino module at the same time, you need to install 
jdk17 locally and configure `toolchains.xml` in the user's `${user.home}/.m2/` 
directory,
-then run `mvn package -P toolchain` to compile the entire project.
+then run `mvn package -Ptoolchain,build-mixed-format-trino` to compile the 
entire project.
 
 ```xml
 <?xml version="1.0" encoding="UTF-8"?>

Reply via email to