Ethan Rose created HDDS-15892:
---------------------------------
Summary: Massive local build time degradation when using agent
worktrees
Key: HDDS-15892
URL: https://issues.apache.org/jira/browse/HDDS-15892
Project: Apache Ozone
Issue Type: Bug
Components: build
Reporter: Ethan Rose
Assignee: Ethan Rose
Agents like Claude and Cursor add worktrees to hidden directories within the
repo by default, like {{{}.claude/worktrees/{}}}. I have not been super
proactive about cleaning worktrees when I'm done with them, and have
accumulated ~20 so far.
My local build command is:
{code:java}
mvn -DskipTests=true -Dmaven.javadoc.skip=true -DskipRecon --threads 2.0C
-DskipShade -Dskip.npx clean package
{code}
This finishes in ~2 minutes in worktrees, but has crept up to 4+ minutes when
run from the repo root. All the extra time seems to come from the distribution
step.
>From repo root:
{code:java}
[INFO] Apache Ozone Distribution .......................... SUCCESS [02:55 min]
{code}
>From worktree:
{code:java}
[INFO] Apache Ozone Distribution .......................... SUCCESS [ 37.590 s]
{code}
The culprit looks to be the {{find}} commands in
[dist-layout-stitching|https://github.com/apache/ozone/blob/93e7b364e404c59161386e0a4b21129a32ba4112/hadoop-ozone/dist/dev-support/bin/dist-layout-stitching]
which are traversing all subdirectories to find classpath and jar files, even
hidden ones, which means they are incorrectly operating on every worktree's
build results as well.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]