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

jin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-hugegraph-doc.git


The following commit(s) were added to refs/heads/master by this push:
     new 6599d1f3 chore: add docker using / add load data methods (#423)
6599d1f3 is described below

commit 6599d1f35ac640391442376c0667013830dfe626
Author: Jingkai Yang <[email protected]>
AuthorDate: Mon Nov 17 19:32:28 2025 +0800

    chore: add docker using / add load data methods (#423)
---
 .../docs/quickstart/computing/hugegraph-vermeer.md | 219 +++++++++++++++++++--
 .../docs/quickstart/computing/hugegraph-vermeer.md | 219 +++++++++++++++++++--
 2 files changed, 411 insertions(+), 27 deletions(-)

diff --git a/content/cn/docs/quickstart/computing/hugegraph-vermeer.md 
b/content/cn/docs/quickstart/computing/hugegraph-vermeer.md
index e96b5046..e739e110 100644
--- a/content/cn/docs/quickstart/computing/hugegraph-vermeer.md
+++ b/content/cn/docs/quickstart/computing/hugegraph-vermeer.md
@@ -16,6 +16,142 @@ master 是负责通信、转发、汇总的节点,计算量和占用资源量
 
 ### 1.2 运行方法
 
+1. **方案一:Docker Compose(推荐)**
+
+确保docker-compose.yaml存在于您的项目根目录中。如果没有,以下是一个示例:
+```yaml
+#
+# 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
+#
+#    http://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.
+#
+
+services:
+  vermeer-master:
+    image: hugegraph/vermeer
+    container_name: vermeer-master
+    volumes:
+      - ~/.config:/go/bin/config # Change here to your actual config path
+    command: --env=master
+    networks:
+      vermeer_network:
+        ipv4_address: 172.20.0.10 # Assign a static IP for the master
+
+  vermeer-worker:
+    image: hugegraph/vermeer
+    container_name: vermeer-worker
+    volumes:
+      - ~/:/go/bin/config # Change here to your actual config path
+    command: --env=worker
+    networks:
+      vermeer_network:
+        ipv4_address: 172.20.0.11 # Assign a static IP for the worker
+
+networks:
+  vermeer_network:
+    driver: bridge
+    ipam:
+      config:
+        - subnet: 172.20.0.0/24 # Define the subnet for your network
+```
+
+修改 docker-compose.yaml
+- **Volume**:例如将两处 ~/:/go/bin/config 改为 
/home/user/config:/go/bin/config(或您自己的配置目录)。
+- **Subnet**:根据实际情况修改子网IP。请注意,每个容器需要访问的端口在config文件中指定,具体请参照项目`config`文件夹下内容。
+
+在项目目录构建镜像并启动(或者先用 docker build 再 docker-compose up)
+
+```shell
+# 构建镜像(在项目根 vermeer 目录)
+docker build -t hugegraph/vermeer .
+
+# 启动(在 vermeer 根目录)
+docker-compose up -d
+# 或使用新版 CLI:
+# docker compose up -d
+```
+
+查看日志 / 停止 / 删除:
+
+```shell
+docker-compose logs -f
+docker-compose down
+```
+
+2. **方案二:通过 docker run 单独启动(手动创建网络并分配静态 IP)**
+
+确保CONFIG_DIR对Docker进程具有适当的读取/执行权限。
+
+构建镜像:
+
+```shell
+docker build -t hugegraph/vermeer .
+```
+
+创建自定义 bridge 网络(一次性操作):
+
+```shell
+docker network create --driver bridge \
+  --subnet 172.20.0.0/24 \
+  vermeer_network
+```
+
+运行 master(调整 CONFIG_DIR 为您的绝对配置路径,可以根据实际情况调整IP):
+
+```shell
+CONFIG_DIR=/home/user/config
+
+docker run -d \
+  --name vermeer-master \
+  --network vermeer_network --ip 172.20.0.10 \
+  -v ${CONFIG_DIR}:/go/bin/config \
+  hugegraph/vermeer \
+  --env=master
+```
+
+运行 worker:
+
+```shell
+docker run -d \
+  --name vermeer-worker \
+  --network vermeer_network --ip 172.20.0.11 \
+  -v ${CONFIG_DIR}:/go/bin/config \
+  hugegraph/vermeer \
+  --env=worker
+```
+
+查看日志 / 停止 / 删除:
+
+```shell
+docker logs -f vermeer-master
+docker logs -f vermeer-worker
+
+docker stop vermeer-master vermeer-worker
+docker rm vermeer-master vermeer-worker
+
+# 删除自定义网络(如果需要)
+docker network rm vermeer_network
+```
+
+3. **方案三:从源码构建**
+
+构建。具体请参照[Vermeer 
Readme](https://github.com/apache/incubator-hugegraph-computer/tree/master/vermeer)。
+
+```shell
+go build
+```
+
 在进入文件夹目录后输入 `./vermeer --env=master` 或 `./vermeer --env=worker01`
 
 ## 二、任务创建类 rest api
@@ -33,7 +169,11 @@ master 是负责通信、转发、汇总的节点,计算量和占用资源量
 
 具体参数参考 Vermeer 参数列表文档。
 
-request 示例:
+vermeer提供三种加载方式:
+
+1. 从本地加载
+
+**request 示例:**
 
 ```javascript
 POST http://localhost:8688/tasks/create
@@ -41,16 +181,67 @@ POST http://localhost:8688/tasks/create
  "task_type": "load",
  "graph": "testdb",
  "params": {
- "load.parallel": "50",
- "load.type": "local",
- "load.vertex_files": "{\"localhost\":\"data/twitter-2010.v_[0,99]\"}",
- "load.edge_files": "{\"localhost\":\"data/twitter-2010.e_[0,99]\"}",
- "load.use_out_degree": "1",
- "load.use_outedge": "1"
+  "load.parallel": "50",
+  "load.type": "local",
+  "load.vertex_files": "{\"localhost\":\"data/twitter-2010.v_[0,99]\"}",
+  "load.edge_files": "{\"localhost\":\"data/twitter-2010.e_[0,99]\"}",
+  "load.use_out_degree": "1",
+  "load.use_outedge": "1"
  }
 }
 ```
 
+2. 从hugegraph加载
+
+**request 示例:**
+
+⚠️ 安全警告:切勿在配置文件或代码中存储真实密码。请改用环境变量或安全的凭据管理系统。
+
+```javascript
+POST http://localhost:8688/tasks/create
+{
+  "task_type": "load",
+  "graph": "testdb",
+  "params": {
+    "load.parallel": "50",
+    "load.type": "hugegraph",
+    "load.hg_pd_peers": "[\"<your-hugegraph-ip>:8686\"]",
+    "load.hugegraph_name": "DEFAULT/hugegraph2/g",
+    "load.hugegraph_username": "admin",
+    "load.hugegraph_password": "<your-password-here>",
+    "load.use_out_degree": "1",
+    "load.use_outedge": "1"
+  }
+}
+```
+
+3. 从hdfs加载
+
+**request 示例:**
+
+```javascript
+POST http://localhost:8688/tasks/create
+{
+  "task_type": "load",
+  "graph": "testdb",
+  "params": {
+    "load.parallel": "50",
+    "load.type": "hdfs",
+    "load.hdfs_namenode": "name_node1:9000",
+    "load.hdfs_conf_path": "/path/to/conf",
+    "load.krb_realm": "EXAMPLE.COM",
+    "load.krb_name": "[email protected]",
+    "load.krb_keytab_path": "/path/to/keytab",
+    "load.krb_conf_path": "/path/to/krb5.conf",
+    "load.hdfs_use_krb": "1",
+    "load.vertex_files": "/data/graph/vertices",
+    "load.edge_files": "/data/graph/edges",
+    "load.use_out_degree": "1",
+    "load.use_outedge": "1"
+  }
+}
+```
+
 ### 2.3 输出计算结果
 
 所有的 vermeer 计算任务均支持多种结果输出方式,可自定义输出方式:local、hdfs、afs 或 hugegraph,在发送请求时的 params 
参数下加入对应参数,即可生效。指定 output.need_statistics 为 1 
时,支持计算结果统计信息输出,结果会写在接口任务信息内。统计模式算子目前支持 "count" 和 "modularity" 。但仅针对社区发现算法适用。
@@ -66,13 +257,13 @@ POST http://localhost:8688/tasks/create
  "graph": "testdb",
  "params": {
  "compute.algorithm": "pagerank",
- "compute.parallel":"10",
- "compute.max_step":"10",
- "output.type":"local",
- "output.parallel":"1",
- "output.file_path":"result/pagerank"
-       }
- }
+ "compute.parallel": "10",
+ "compute.max_step": "10",
+ "output.type": "local",
+ "output.parallel": "1",
+ "output.file_path": "result/pagerank"
+  }
+}
 ```
 
 ## 三、支持的算法
diff --git a/content/en/docs/quickstart/computing/hugegraph-vermeer.md 
b/content/en/docs/quickstart/computing/hugegraph-vermeer.md
index 7ea79038..b0a96027 100644
--- a/content/en/docs/quickstart/computing/hugegraph-vermeer.md
+++ b/content/en/docs/quickstart/computing/hugegraph-vermeer.md
@@ -16,6 +16,144 @@ The framework's runtime configuration can be passed via 
command-line parameters
 
 ### 1.2 Running Method
 
+1.  **Option 1: Docker Compose (Recommended)**
+
+Please ensure that `docker-compose.yaml` exists in your project root 
directory. If it doesn't, here is an example:
+
+```yaml
+#
+# 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
+#
+#    http://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.
+#
+
+services:
+  vermeer-master:
+    image: hugegraph/vermeer
+    container_name: vermeer-master
+    volumes:
+      - ~/.config:/go/bin/config # Change here to your actual config path
+    command: --env=master
+    networks:
+      vermeer_network:
+        ipv4_address: 172.20.0.10 # Assign a static IP for the master
+
+  vermeer-worker:
+    image: hugegraph/vermeer
+    container_name: vermeer-worker
+    volumes:
+      - ~/:/go/bin/config # Change here to your actual config path
+    command: --env=worker
+    networks:
+      vermeer_network:
+        ipv4_address: 172.20.0.11 # Assign a static IP for the worker
+
+networks:
+  vermeer_network:
+    driver: bridge
+    ipam:
+      config:
+        - subnet: 172.20.0.0/24 # Define the subnet for your network
+```
+
+Modify `docker-compose.yaml`
+
+- **Volume**: For example, change both instances of `~/:/go/bin/config` to 
`/home/user/config:/go/bin/config` (or your own configuration directory).
+- **Subnet**: Modify the subnet IP based on your actual situation. Note that 
the ports each container needs to access are specified in the config file. 
Please refer to the contents of the project's `config` folder for details.
+
+Build the Image and Start in the Project Directory (or `docker build` first, 
then `docker-compose up`)
+
+```shell
+# Build the image (in the project root vermeer directory)
+docker build -t hugegraph/vermeer .
+
+# Start the services (in the vermeer root directory)
+docker-compose up -d
+# Or use the new CLI:
+# docker compose up -d
+```
+
+View Logs / Stop / Remove
+
+```shell
+docker-compose logs -f
+docker-compose down
+```
+
+2.  **Option 2: Start individually via `docker run` (Manually create network 
and assign static IP)**
+
+Ensure the CONFIG_DIR has proper read/execute permissions for the Docker 
process.
+
+Build the image:
+
+```shell
+docker build -t hugegraph/vermeer .
+```
+
+Create a custom bridge network (one-time operation):
+
+```shell
+docker network create --driver bridge \
+  --subnet 172.20.0.0/24 \
+  vermeer_network
+```
+
+Run master (adjust `CONFIG_DIR` to your **absolute** configuration path, and 
you can adjust the IP as needed based on your actual situation).
+
+```shell
+CONFIG_DIR=/home/user/config
+
+docker run -d \
+  --name vermeer-master \
+  --network vermeer_network --ip 172.20.0.10 \
+  -v ${CONFIG_DIR}:/go/bin/config \
+  hugegraph/vermeer \
+  --env=master
+```
+
+Run worker:
+
+```shell
+docker run -d \
+  --name vermeer-worker \
+  --network vermeer_network --ip 172.20.0.11 \
+  -v ${CONFIG_DIR}:/go/bin/config \
+  hugegraph/vermeer \
+  --env=worker
+```
+
+View logs / Stop / Remove:
+
+```shell
+docker logs -f vermeer-master
+docker logs -f vermeer-worker
+
+docker stop vermeer-master vermeer-worker
+docker rm vermeer-master vermeer-worker
+
+# Remove the custom network (if needed)
+docker network rm vermeer_network
+```
+
+3.  **Option 3: Build from Source**
+
+Build. You can refer[Vermeer 
Readme](https://github.com/apache/incubator-hugegraph-computer/tree/master/vermeer).
+
+```shell
+go build
+```
+
 Enter the directory and input `./vermeer --env=master` or `./vermeer 
--env=worker01`.
 
 ## 2. Task Creation REST API
@@ -33,7 +171,11 @@ Available URLs are as follows:
 
 Refer to the Vermeer parameter list document for specific parameters.
 
-Request example:
+Vermeer provides three ways to load data:
+
+1. Load from Local Files
+
+**Request Example:**
 
 ```javascript
 POST http://localhost:8688/tasks/create
@@ -41,16 +183,67 @@ POST http://localhost:8688/tasks/create
  "task_type": "load",
  "graph": "testdb",
  "params": {
- "load.parallel": "50",
- "load.type": "local",
- "load.vertex_files": "{\"localhost\":\"data/twitter-2010.v_[0,99]\"}",
- "load.edge_files": "{\"localhost\":\"data/twitter-2010.e_[0,99]\"}",
- "load.use_out_degree": "1",
- "load.use_outedge": "1"
+  "load.parallel": "50",
+  "load.type": "local",
+  "load.vertex_files": "{\"localhost\":\"data/twitter-2010.v_[0,99]\"}",
+  "load.edge_files": "{\"localhost\":\"data/twitter-2010.e_[0,99]\"}",
+  "load.use_out_degree": "1",
+  "load.use_outedge": "1"
  }
 }
 ```
 
+2. Load from HugeGraph
+
+**Request Example:**
+
+⚠️ Security Warning: Never store real passwords in configuration files or 
code. Use environment variables or a secure credential management system 
instead.
+
+```javascript
+POST http://localhost:8688/tasks/create
+{
+  "task_type": "load",
+  "graph": "testdb",
+  "params": {
+    "load.parallel": "50",
+    "load.type": "hugegraph",
+    "load.hg_pd_peers": "[\"<your-hugegraph-ip>:8686\"]",
+    "load.hugegraph_name": "DEFAULT/hugegraph2/g",
+    "load.hugegraph_username": "admin",
+    "load.hugegraph_password": "<your-password-here>",
+    "load.use_out_degree": "1",
+    "load.use_outedge": "1"
+  }
+}
+```
+
+3. Load from HDFS
+
+**Request Example:**
+
+```javascript
+POST http://localhost:8688/tasks/create
+{
+  "task_type": "load",
+  "graph": "testdb",
+  "params": {
+    "load.parallel": "50",
+    "load.type": "hdfs",
+    "load.hdfs_namenode": "name_node1:9000",
+    "load.hdfs_conf_path": "/path/to/conf",
+    "load.krb_realm": "EXAMPLE.COM",
+    "load.krb_name": "[email protected]",
+    "load.krb_keytab_path": "/path/to/keytab",
+    "load.krb_conf_path": "/path/to/krb5.conf",
+    "load.hdfs_use_krb": "1",
+    "load.vertex_files": "/data/graph/vertices",
+    "load.edge_files": "/data/graph/edges",
+    "load.use_out_degree": "1",
+    "load.use_outedge": "1"
+  }
+}
+```
+
 ### 2.3 Output Computation Results
 
 All Vermeer computation tasks support multiple result output methods, which 
can be customized: local, hdfs, afs, or hugegraph. Add the corresponding 
parameters under the params parameter when sending the request to take effect. 
When output.need_statistics is set to 1, it supports outputting statistical 
information of the computation results, which will be written in the interface 
task information. The statistical mode operators currently support "count" and 
"modularity," but only for com [...]
@@ -66,13 +259,13 @@ POST http://localhost:8688/tasks/create
  "graph": "testdb",
  "params": {
  "compute.algorithm": "pagerank",
- "compute.parallel":"10",
- "compute.max_step":"10",
- "output.type":"local",
- "output.parallel":"1",
- "output.file_path":"result/pagerank"
+ "compute.parallel": "10",
+ "compute.max_step": "10",
+ "output.type": "local",
+ "output.parallel": "1",
+ "output.file_path": "result/pagerank"
   }
- }
+}
 ```
 
 ## 3. Supported Algorithms

Reply via email to