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

4.x: Verify Starter with 4.x archetypes #7775

Merged
merged 3 commits into from
Oct 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion archetypes/helidon/src/main/archetype/common/common.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
<includes>
<include>.helidon.mustache</include>
<include>README.md.mustache</include>
<include>src/main/java/**/*.java.mustache</include>
<include>src/main/java/**/Main.java.mustache</include>
</includes>
</templates>
<model>
Expand Down
3 changes: 2 additions & 1 deletion archetypes/helidon/src/main/archetype/common/media.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@

<step name="Media Support" optional="true">
<variables>
<text path="media.default-json-lib">jsonb</text>
<text path="media.default-json-lib" if="${flavor} == 'mp'">jsonb</text>
<text path="media.default-json-lib" if="${flavor} == 'se'">jsonp</text>
</variables>
<inputs>
<!-- TODO https://github.com/oracle/helidon-build-tools/issues/699 -->
Expand Down
14 changes: 14 additions & 0 deletions archetypes/helidon/src/main/archetype/common/packaging.xml
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,20 @@ kubectl delete -f app.yaml
</templates>
</output>
</boolean>
<boolean id="jpms"
name="Module support (JPMS)"
description="Add a module-info to your project"
default="false"
optional="true">
<output>
<templates engine="mustache" transformations="mustache,packaged">
<directory>files</directory>
<includes>
<include>src/main/java/**/module-info.java.mustache</include>
</includes>
</templates>
</output>
</boolean>
</inputs>
</step>
</archetype-script>
1 change: 1 addition & 0 deletions archetypes/helidon/src/main/archetype/common/presets.xml
Original file line number Diff line number Diff line change
Expand Up @@ -37,5 +37,6 @@
<boolean path="docker.jlink-image">true</boolean>
<boolean path="k8s">true</boolean>
<boolean path="v8o">false</boolean>
<boolean path="jpms">false</boolean>
</presets>
</archetype-script>
10 changes: 5 additions & 5 deletions archetypes/helidon/src/main/archetype/flavor.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,16 @@
default="se"
global="true"
optional="true">
<option value="mp"
name="Helidon MP"
description="Declarative, MicroProfile compliant">
<exec src="mp/mp.xml"/>
</option>
<option value="se"
name="Helidon SE"
description="WebSever based on Virtual Threads">
<exec src="se/se.xml"/>
</option>
<option value="mp"
name="Helidon MP"
description="Declarative, MicroProfile compliant">
<exec src="mp/mp.xml"/>
</option>
</enum>
</inputs>
</step>
Expand Down
1 change: 1 addition & 0 deletions archetypes/helidon/src/main/archetype/mp/oci/oci-mp.xml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ This will mount `~/.oci` as a volume in the running docker container.
<boolean path="docker.jlink-image">false</boolean>
<boolean path="k8s">true</boolean>
<boolean path="v8o">false</boolean>
<boolean path="jpms">false</boolean>
</presets>
<call method="pre-processed-models"/>
<exec src="/common/common.xml"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@
<source src="/se/custom/database.xml"/>
<source src="/common/extra.xml"/>
<source src="/se/custom/extra.xml"/>
<exec src="/common/packaging.xml"/>
<source src="/common/observability.xml"/>
<source src="/se/custom/observability.xml"/>
<exec src="/common/packaging.xml"/>

<output>
<file source="files/src/main/resources/WEB/index.html" target="src/main/resources/WEB/index.html" if="${media} contains 'multipart'"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,25 +19,9 @@
<archetype-script xmlns="https://helidon.io/archetype/2.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://helidon.io/archetype/2.0 https://helidon.io/xsd/archetype-2.0.xsd">
<exec src="/common/presets.xml"/>
<presets>
<list path="media">
<value>json</value>
</list>
<boolean path="db">false</boolean>
<enum path="media.json-lib">jsonp</enum>
<boolean path="metrics">true</boolean>
<enum path="metrics.provider">microprofile</enum>
<boolean path="metrics.builtin">true</boolean>
<boolean path="health">true</boolean>
<boolean path="health.builtin">true</boolean>
<boolean path="tracing">false</boolean>
<list path="extra"/>
<boolean path="security">false</boolean>
<boolean path="docker">true</boolean>
<boolean path="docker.native-image">true</boolean>
<boolean path="docker.jlink-image">true</boolean>
<boolean path="k8s">false</boolean>
<boolean path="v8o">false</boolean>
</presets>
<exec src="/se/custom/custom-se.xml"/>
<source src="/common/sources.xml"/>
Expand Down
10 changes: 5 additions & 5 deletions archetypes/helidon/src/main/archetype/se/se.xml
Original file line number Diff line number Diff line change
Expand Up @@ -32,16 +32,16 @@
description="Sample Helidon Nima project that includes multiple REST operations">
<exec src="quickstart/quickstart-se.xml"/>
</option>
<option value="custom"
name="Custom"
description="Custom Helidon SE project">
<exec src="custom/custom-se.xml"/>
</option>
<option value="database"
name="Database"
description="Helidon SE application that uses a database with JPA">
<exec src="database/database-se.xml"/>
</option>
<option value="custom"
name="Custom"
description="Custom Helidon SE project">
<exec src="custom/custom-se.xml"/>
</option>
</enum>
</inputs>
</step>
Expand Down