Skip to content

Commit cf064fa

Browse files
authored
improve consistency and testing (#26)
* fix(requirements): include tomli version in requirements files * chore(java): update java defaults in README, spec, and default files. * feat(java): now queries for the latest LTS version of java.
1 parent 2958053 commit cf064fa

10 files changed

Lines changed: 58 additions & 22 deletions

File tree

CHANGELOG.rst

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
.. SPDX-FileCopyrightText: 2025 Industrial Info Resources, Inc.
1+
.. SPDX-FileCopyrightText: 2026 Industrial Info Resources, Inc.
22
.. SPDX-FileContributor: William P. Marshall
33
..
44
.. SPDX-License-Identifier: GPL-3.0-or-later
@@ -9,6 +9,24 @@ Marshallwp General Collection Release Notes
99

1010
.. contents:: Topics
1111

12+
v1.5.2
13+
======
14+
15+
Release Summary
16+
---------------
17+
18+
Update testing to make Python 3.10 happy and improve java documentation, spec, and default values.
19+
20+
Major Changes
21+
-------------
22+
23+
- The `java` role now queries `Public APIs for Oracle Java Releases <https://docs.oracle.com/en-us/iaas/jms/doc/public-api-oracle-java-releases.html>`_ for the latest LTS version of Java available. This should help reduce the number of updates this role needs that default up-to-date.
24+
25+
Minor Changes
26+
-------------
27+
28+
- Requirements files now include an explicit tomli version.
29+
1230
v1.5.1
1331
======
1432

changelogs/.plugin-cache.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# SPDX-FileCopyrightText: 2025 Industrial Info Resources, Inc.
1+
# SPDX-FileCopyrightText: 2026 Industrial Info Resources, Inc.
22
# SPDX-FileContributor: William P. Marshall
33
#
44
# SPDX-License-Identifier: GPL-3.0-or-later
@@ -58,4 +58,4 @@ plugins:
5858
strategy: {}
5959
test: {}
6060
vars: {}
61-
version: 1.5.1
61+
version: 1.5.2

changelogs/changelog.yaml

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# SPDX-FileCopyrightText: 2025 Industrial Info Resources, Inc.
1+
# SPDX-FileCopyrightText: 2026 Industrial Info Resources, Inc.
22
# SPDX-FileContributor: William P. Marshall
33
#
44
# SPDX-License-Identifier: GPL-3.0-or-later
@@ -225,3 +225,16 @@ releases:
225225
fragments:
226226
- 24-refactor-toml.yaml
227227
release_date: '2025-11-20'
228+
1.5.2:
229+
changes:
230+
major_changes:
231+
- The `java` role now queries `Public APIs for Oracle Java Releases <https://docs.oracle.com/en-us/iaas/jms/doc/public-api-oracle-java-releases.html>`_
232+
for the latest LTS version of Java available. This should help reduce the
233+
number of updates this role needs that default up-to-date.
234+
minor_changes:
235+
- Requirements files now include an explicit tomli version.
236+
release_summary: Update testing to make Python 3.10 happy and improve java documentation,
237+
spec, and default values.
238+
fragments:
239+
- 26-improve-consistency-and-testing.yml
240+
release_date: '2026-01-23'

galaxy.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# SPDX-FileCopyrightText: 2025 Industrial Info Resources, Inc. <https://www.industrialinfo.com>
1+
# SPDX-FileCopyrightText: 2026 Industrial Info Resources, Inc. <https://www.industrialinfo.com>
22
# SPDX-FileContributor: William P. Marshall
33
#
44
# SPDX-License-Identifier: GPL-3.0-or-later
@@ -10,7 +10,7 @@
1010

1111
namespace: "marshallwp"
1212
name: "general"
13-
version: 1.5.1
13+
version: 1.5.2
1414
readme: README.md
1515
authors:
1616
- William P. Marshall

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55

66
# add python packages that are required for this collection
77
tomli-w >= 1.2.0
8-
tomli ; python_version < '3.11'
8+
tomli >= 1.1.0 ; python_version < "3.11"

roles/java/README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
SPDX-FileCopyrightText: 2025 Industrial Info Resources, Inc. <https://www.industrialinfo.com>
2+
SPDX-FileCopyrightText: 2026 Industrial Info Resources, Inc. <https://www.industrialinfo.com>
33
SPDX-FileContributor: William P. Marshall
44
55
SPDX-License-Identifier: GPL-3.0-or-later
@@ -23,7 +23,7 @@ Role Variables
2323

2424
| Name | Description | Default |
2525
| ---- | ----------- | ------- |
26-
| java_version | Default Java Version. Should always be a supported version of java. | 21 |
26+
| java_version | Default Java Version. By default it queries Oracle for the latest LTS version of Java. | |
2727
| java_type | Indicates whether the role should try to install the JRE or JDK. | jre |
2828
| java_use_headless | Headless variants exclude GUI components and are good for terminal-only servers. | true |
2929
| java_vendor | The vendor providing you with Java. `Default` means your distro's default repositories. | Default |
@@ -53,16 +53,16 @@ Including an example of how to use your role (for instance, with variables passe
5353
- marshallwp.general.java
5454
# Install Oracle Java (not OpenJDK)
5555
- role: marshallwp.general.java
56-
java_version: 21
56+
java_version: 25
5757
java_vendor: Oracle
5858
java_variant: Java
5959
# Install Bellsoft OpenJDK
6060
- role: marshallwp.general.java
61-
java_version: 21
61+
java_version: 25
6262
java_vendor: Bellsoft
6363
# Install Amazon Corretto (their OpenJDK Build)
6464
- role: marshallwp.general.java
65-
java_version: 21
65+
java_version: 25
6666
java_vendor: Amazon
6767
java_variant: OpenJDK
6868
```
@@ -74,11 +74,11 @@ Another way to consume this role would be:
7474
hosts: all
7575
gather_facts: false
7676
tasks:
77-
- name: Install Azul Zulu 21
77+
- name: Install Azul Zulu 25
7878
ansible.builtin.include_role:
7979
name: marshallwp.general.java
8080
vars:
81-
java_version: 21
81+
java_version: 25
8282
java_vendor: Azul
8383
java_variant: OpenJDK
8484
```

roles/java/defaults/main.yml

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,16 @@
1-
# SPDX-FileCopyrightText: 2025 Industrial Info Resources, Inc. <https://www.industrialinfo.com>
1+
# SPDX-FileCopyrightText: 2026 Industrial Info Resources, Inc. <https://www.industrialinfo.com>
22
# SPDX-FileContributor: William P. Marshall
33
#
44
# SPDX-License-Identifier: GPL-3.0-or-later
55

66
---
7-
# Default Java Version. Should always be a supported version of java.
8-
java_version: 25
7+
# Default Java Version. The lookup queries for the latest supported LTS version of java.
8+
java_version: "{{
9+
(lookup('ansible.builtin.url',
10+
'https://java.oraclecloud.com/currentJavaReleases?isLts=true&isSupportedVersion=true&licenseType=NFTC&sortBy=jdkVersion&sortOrder=DESC')
11+
| ansible.builtin.from_json)['items'][0]['jdkDetails']['jdkVersion']
12+
| int
13+
}}"
914

1015
# Valid values are JRE or JDK. JRE is not available for all vendors and variants.
1116
java_type: jre
@@ -26,8 +31,8 @@ java_install_directory: "/usr/lib/jvm/{{ java_type }}-{{ java_version }}-{{ java
2631
# Archive download directory for non-repository-based installs.
2732
java_archive_download_dir: /tmp
2833

29-
# Update the alternatives
30-
java_update_alternatives: true
34+
# Enable or disable updating alternatives via update-alternatives for Archive-installed Java
35+
java_update_alternatives: false
3136

3237
# When not installing from a repository, file extension will determine whether a file is
3338
# installed via ansible.builtin.package or extracted via ansible.builtin.unarchive.

roles/java/meta/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ argument_specs:
7272
java_version:
7373
description: Default Java Version. Should always be a supported version of java.
7474
type: int
75-
default: 21
75+
default: 25
7676
java_type:
7777
description: Indicates whether the role should try to install the JRE or JDK.
7878
default: jre

roles/java/vars/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ java_packages:
183183
packages:
184184
- "bellsoft-java{{ java_version }}{{ (java_type == 'jre') | ansible.builtin.ternary('-runtime',
185185
(java_use_headless) | ansible.builtin.ternary('-lite', '')) }}"
186-
# https://adoptium.net/blog/2021/12/eclipse-temurin-linux-installers-available/
186+
# https://adoptium.net/installation/linux
187187
Eclipse:
188188
OpenJDK: # a.k.a. Temurin
189189
Alpine:

tests/unit/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55

66
# add python packages that are required for this collection
77
tomli-w >= 1.2.0
8-
tomli ; python_version < '3.11'
8+
tomli >= 1.1.0 ; python_version < "3.11"

0 commit comments

Comments
 (0)