Very short example on using Jigsaw Layers (used in presentation).
The example contains four commits:
jigsaw.layers.Example
module added that collects Java conferences viaJavaConfProvider
service interface- GeeCON Prague provider added
- GeeCON Krakow provider added
- Jigsaw layer created that loads
geecon.prague.provider
module into a separate layer
You need JDK 10+ to run this example.
-
Open the project in the IntelliJ IDEA (CE is enough).
-
Build Project
-
Create a run configuration:
- Choose
jigsaw.layers.example.JavaConfCollector
as the main class - Use
Jigsaw-Layers-Example
as the classpath nodule - Use
out/production/geecon.prague.provider
as Program arguments - Use the root project directory as Working directory
- Choose
-
Run. You should get the following:
Hello from GeeCON Prague!
Hello from GeeCON Krakow!