Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: improve class scanning filter #20978

Merged
merged 1 commit into from
Feb 12, 2025

Conversation

mcollovati
Copy link
Collaborator

Ignores additional well-known packages when scanning classes to find frontend resources.

Ignores additional well known packages when scanning classes
to find frontend resources.
@mcollovati
Copy link
Collaborator Author

An example of local run on CC app. Focus on the Visited NNN classes and Build frontend completed timing

Latest 24.7 Flow alpha
09:35:55.587 [INFO] --- flow:24.7.0.alpha12:prepare-frontend (default) @ control-center-app ---
09:35:56.748 [INFO] Reflections took 919 ms to scan 261 urls, producing 15335 keys and 85284 values
09:35:57.347 [INFO] Visited 105 classes. Took 96 ms.
09:35:57.367 [INFO] Copying frontend resources from jar files ...
09:35:57.454 [INFO] Visited 262 resources. Took 86 ms.
09:35:57.466 [INFO] 
09:35:57.466 [INFO] --- flow:24.7.0.alpha12:build-frontend (default) @ control-center-app ---
09:35:57.473 [INFO] Scanning classes to find frontend configurations and dependencies...
09:36:00.640 [INFO] Visited 10839 classes. Took 3166 ms.
09:36:00.641 [INFO] Checking if a production mode bundle build is needed
09:36:00.642 [WARNING] There is no prod-bundle in the project or on the classpath nor is there a default production bundle included.
.....
09:36:44.557 [INFO] Frontend dependencies resolved successfully.
09:36:44.836 [INFO] Copying frontend resources from jar files ...
09:36:44.883 [INFO] Visited 262 resources. Took 46 ms.
09:36:45.444 [INFO] Running Vite ...
09:36:53.268 [INFO] Scanning classes to find frontend configurations and dependencies...
09:36:55.744 [INFO] Visited 10839 classes. Took 2476 ms.
09:36:56.066 [INFO] Premium Features are enabled
09:36:56.068 [INFO] Build frontend completed in 58597 ms.
09:36:56.068 [INFO] 
This patch
09:39:12.060 [INFO] --- flow:24.7-SNAPSHOT:prepare-frontend (default) @ control-center-app ---
09:39:13.054 [INFO] Reflections took 859 ms to scan 261 urls, producing 15335 keys and 85284 values
09:39:13.627 [INFO] Visited 105 classes. Took 88 ms.
09:39:13.649 [INFO] Copying frontend resources from jar files ...
09:39:13.719 [INFO] Visited 262 resources. Took 69 ms.
09:39:13.726 [INFO] 
09:39:13.726 [INFO] --- flow:24.7-SNAPSHOT:build-frontend (default) @ control-center-app ---
09:39:13.739 [INFO] Scanning classes to find frontend configurations and dependencies...
09:39:14.464 [INFO] Visited 1505 classes. Took 724 ms.
09:39:14.465 [INFO] Checking if a production mode bundle build is needed
09:39:14.466 [WARNING] There is no prod-bundle in the project or on the classpath nor is there a default production bundle included.
...
09:39:23.680 [INFO] Frontend dependencies resolved successfully.
09:39:23.962 [INFO] Copying frontend resources from jar files ...
09:39:24.016 [INFO] Visited 262 resources. Took 54 ms.
09:39:24.566 [INFO] Running Vite ...
09:39:32.256 [INFO] Scanning classes to find frontend configurations and dependencies...
09:39:32.835 [INFO] Visited 1505 classes. Took 579 ms.
09:39:33.155 [INFO] Premium Features are enabled
09:39:33.156 [INFO] Build frontend completed in 19425 ms.
09:39:33.157 [INFO] 
Flow version Visit classes Scan times (ms) Build time (ms)
24.7.0.alpha12 10839 3166 / 2476 58597
This patch 1505 724 / 579 19425

Copy link

github-actions bot commented Feb 11, 2025

Test Results

1 167 files  ± 0  1 167 suites  ±0   1h 37m 32s ⏱️ -49s
7 672 tests ± 0  7 615 ✅ + 1  57 💤 ±0  0 ❌  - 1 
7 976 runs   - 17  7 912 ✅  - 17  64 💤 +1  0 ❌  - 1 

Results for commit 74ca144. ± Comparison against base commit 309d431.

♻️ This comment has been updated with latest results.

@mshabarov mshabarov merged commit 6fe93c4 into main Feb 12, 2025
26 checks passed
@mshabarov mshabarov deleted the chore/improve-class-scanning-filter branch February 12, 2025 06:58
vaadin-bot pushed a commit that referenced this pull request Feb 12, 2025
Ignores additional well known packages when scanning classes
to find frontend resources.
vaadin-bot pushed a commit that referenced this pull request Feb 12, 2025
Ignores additional well known packages when scanning classes
to find frontend resources.
vaadin-bot added a commit that referenced this pull request Feb 12, 2025
Ignores additional well known packages when scanning classes
to find frontend resources.

Co-authored-by: Marco Collovati <marco@vaadin.com>
vaadin-bot added a commit that referenced this pull request Feb 12, 2025
Ignores additional well known packages when scanning classes
to find frontend resources.

Co-authored-by: Marco Collovati <marco@vaadin.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants