← All 1Z0-819 Flashcard Decks

Modular Development & Deployment Practices Flashcards

7 cards from real 1Z0-819 practice questions. Tap to flip, then mark Knew It or Still Learning — missed cards come back until you master them.

Read the first 7 Modular Development & Deployment Practices flashcards as text
  1. What is the unnamed module in the Java Platform Module System?

    Answer: A virtual module that contains all classes loaded from the class path

    The unnamed module is a synthetic module that groups all types loaded from the class path, enabling backward compatibility with pre-module code.

  2. A `module-info.java` contains `opens com.example.impl to com.framework;`. What does this enable?

    Answer: Deep reflection into com.example.impl exclusively by com.framework at runtime

    A qualified `opens` grants the specified module the ability to use deep reflection (including private members) on the opened package at runtime.

  3. Which file format does `jmod` create, and what is it primarily used for?

    Answer: A .jmod file used for packaging modules for jlink and distribution

    `jmod` creates `.jmod` files that can bundle native code, config files, and legal notices alongside classes — primarily consumed by `jlink` to build runtime images.

  4. How does the Java module system handle split packages (the same package name in two named modules)?

    Answer: It throws an error at module resolution time — split packages are not allowed between named modules

    Split packages between two named modules are illegal; the module system rejects them during resolution with a `LayerInstantiationException` or startup error.

  5. Which `java` flag prints a module's descriptor including its requires, exports, and provides declarations?

    Answer: --describe-module

    `--describe-module ` prints the full module descriptor showing all directives declared in its `module-info`.

  6. What is an automatic module?

    Answer: A non-modular JAR placed on the module path that is given a derived module name

    When a non-modular JAR is placed on the module path, the system creates an automatic module with a name derived from the JAR filename and it can read all other modules.

  7. A module `com.app` has `requires java.sql;` in its descriptor. At runtime, which other module does `java.sql` implicitly require via `requires transitive`?

    Answer: java.naming

    `java.sql` declares `requires transitive java.logging` and `requires transitive java.xml`, but `java.naming` is the third transitive dependency that consumers of `java.sql` gain.