This is an automated email from the ASF dual-hosted git repository.
hello-stephen pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/master by this push:
new 82f366e1f80 [improvement](build) Avoid unnecessary submodule
initialization (#68533)
82f366e1f80 is described below
commit 82f366e1f8017a5f404cc212be321ec7cfa2c29b
Author: Gavin Chou <[email protected]>
AuthorDate: Mon Sep 28 11:23:06 2026 +0800
[improvement](build) Avoid unnecessary submodule initialization (#68533)
Problem Summary: Worktree instructions currently tell contributors to
initialize missing submodules manually. Non-build tasks can interpret
that as a full recursive initialization, which creates independent
submodule object databases under each linked worktree and consumes
significant disk space. Clarify that non-build tasks must leave
submodules uninitialized, while build and test entry points initialize
their required paths. Manual initialization is limited to an exact path
when it is genuinely necessary.
---
AGENTS.md | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/AGENTS.md b/AGENTS.md
index babc1657c1c..4d4f857ddf3 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -20,7 +20,9 @@ Separately, any new outbound HTTP request the FE or BE issues
to a host named by
## When running in a WORKTREE directory
-To ensure smooth test execution without interference between worktrees, the
first thing to do upon entering a worktree directory is to check if
`.worktree_initialized` exists. If not, execute `hooks/setup_worktree.sh`,
setting `$ROOT_WORKSPACE_PATH` to the base directory (typically
`${DORIS_REPO}`) beforehand. After successful execution, verify that
`.worktree_initialized` has been touched and that `thirdparty/installed`
dependencies exist correctly. Also check if submodules have been pr [...]
+To ensure smooth test execution without interference between worktrees, the
first thing to do upon entering a worktree directory is to check if
`.worktree_initialized` exists. If not, execute `hooks/setup_worktree.sh`,
setting `$ROOT_WORKSPACE_PATH` to the base directory (typically
`${DORIS_REPO}`) beforehand. After successful execution, verify that
`.worktree_initialized` has been touched and that `thirdparty/installed`
dependencies exist correctly.
+
+Submodules are not part of the default worktree setup. If the task does not
compile Doris or run tests that require submodules, leave all submodules
uninitialized. Build and test entry points initialize the submodule paths they
require. Only initialize a submodule manually when the task actually needs it
and an entry point does not handle it; initialize the exact required path
instead of running an unscoped recursive update for every submodule.
When working in worktree mode, all operations must be confined to the current
worktree directory. Do not enter `${DORIS_REPO}` or use any resources there.
Compilation and execution must be done within the current worktree directory.
The compiled Doris cluster must use random ports not used by other worktrees
(modify BE and FE conf before compilation, using a uniform offset of
`${DORIS_PORT_OFFSET_RANGE}` from default ports without conflicting with other
worktrees' ports). Run from the `o [...]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]