Java Module Migration: Top-Down vs Bottom-Up

Packaging and deploying Java code and use the Java Platform Module System
Answer Correct answer: B — Every module is moved to the module path in a top-down migration.

Which statement is true about migration?

  1. Every module is moved to the module path in a bottom-up migration.
  2. Every module is moved to the module path in a top-down migration. Correct Answer
  3. Unnamed modules are automatic modules in a top-down migration.
  4. The required modules migrate before the modules that depend on them in a top-down migration.

Community Votes

B
100%

100% of anonymous learners picked answer B. Votes are pick records left by other test-takers — they are not the verified answer.

Community Insight

The key insight is distinguishing the direction of dependency resolution: top-down resolves dependencies from root to leaf, while bottom-up resolves from leaf to root. The common trap is confusing which migration strategy moves all modules to the module path versus keeping some on the classpath.

This question tests the differences between top-down and bottom-up migration strategies in the Java Platform Module System (JPMS). It establishes that in a top-down migration, every module is moved to the module path.

Many candidates choose option A because they associate 'bottom-up' with building from the base, but forget that bottom-up migration typically keeps unnamed modules on the classpath to resolve circular dependencies before moving them.

Community Discussion (5 comments)

leylapanaxi 👍 1 Selected: B
All modules are moved to module path in bottom-up approach
9817c20 👍 1
B iz ze correct answer.
zuluitai 👍 1 Selected: B
B is the correct answer here.
Uteman 👍 1
B is correct
Tojose 👍 3
I think the correct answer is B. Every module is moved to the module path in a top-down migration.

Comments & Corrections

No comments yet — spotted an error or have a note? Share it below.

Log in to comment, report an error, or add a note about this question.

Submitted for moderation before publishing. Keep it helpful and respectful.

Expert Analysis

Why the Answer Is Correct

In a top-down migration, the process starts with the main application module (the root) and proceeds downwards through its dependencies. In this strategy, every module is moved to the module path. This allows the module system to validate the entire graph at once, assuming no circular dependencies exist among the unnamed/automatic modules being converted.

Why the Other Options Are Wrong

Option A is incorrect because in a bottom-up migration, modules are moved from the leaves up to the root. During this process, unnamed modules might remain on the classpath until their dependencies are resolved, so it's not strictly true that every module is moved to the module path simultaneously or in the same manner as top-down. Option C is vague; while unnamed modules become automatic modules, the defining characteristic of top-down migration is the movement of all modules to the module path. Option D describes a dependency resolution order (required modules before dependents), which is generally true for compilation but doesn't define the migration strategy itself as precisely as B.

Community Comment Notes

The community consensus strongly favors option B. As user 'Tojose' noted, "I think the correct answer is B. Every module is moved to the module path in a top-down migration." Another user, 'leylapanaxi', clarified that "All modules are moved to module path in bottom-up approach" was a misconception, reinforcing that B is the distinct characteristic of top-down migration in this context. User '9817c20' simply stated "B iz ze correct answer," reflecting the high agreement rate.

Exam Strategy

When studying JPMS migration, focus on the distinction between top-down and bottom-up approaches. Remember that top-down migration requires all modules to be on the module path, while bottom-up allows for gradual conversion where some modules may remain on the classpath initially.

Frequently Asked Questions

Why is bottom-up migration different from top-down?

Bottom-up migration starts from leaf modules and moves up, potentially keeping unnamed modules on the classpath until dependencies are resolved. Top-down moves all modules to the module path from the start.

Can unnamed modules be used in top-down migration?

Yes, but they must be converted to automatic modules or named modules and placed on the module path. The key is that all modules end up on the module path in top-down migration.

More 1Z0-829 FAQ →

Related Analysis

← Back to 1Z0-829 Study Guide