Skip to content

Commit

Permalink
Merge pull request #39 from guidograzioli/update_8_4
Browse files Browse the repository at this point in the history
Update infinispan to 14.0.21, data_grid to 8.4.6
  • Loading branch information
guidograzioli authored Feb 19, 2024
2 parents b78078c + 63a87f4 commit b74511e
Show file tree
Hide file tree
Showing 10 changed files with 37 additions and 25 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
uses: ansible-middleware/github-actions/.github/workflows/release.yml@main
with:
collection_fqcn: 'middleware_automation.infinispan'
downstream_name: 'data_grid'
downstream_name: 'dg'
secrets:
galaxy_token: ${{ secrets.ANSIBLE_GALAXY_API_KEY }}
jira_webhook: ${{ secrets.JIRA_WEBHOOK_CREATE_VERSION }}
Expand Down
1 change: 1 addition & 0 deletions galaxy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ tags:
- infrastructure
- runtimes
- middleware
- cache
- a4mw
dependencies:
"middleware_automation.common": ">=1.1.0"
Expand Down
2 changes: 2 additions & 0 deletions molecule/default/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
template: replicated
mode: ASYNC
statistics: True
infinispan_resp_cache: configuredstaticcache
- role: infinispan
infinispan_nodename: instance2
infinispan_service_name: instance2
Expand All @@ -37,6 +38,7 @@
template: replicated
mode: ASYNC
statistics: True
infinispan_resp_cache: configuredstaticcache
- role: infinispan_cache
infinispan_deployer_user: "supervisor"
infinispan_deployer_password: "remembertochangeme"
Expand Down
15 changes: 5 additions & 10 deletions molecule/default/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,6 @@
url_username: "supervisor"
url_password: "remembertochangeme"
register: test_cache_status
- name: "Check service operational: test cache status via rest (assert)"
ansible.builtin.assert:
that:
- test_cache_status.json.stats.total_number_of_entries == 1
fail_msg: "infinispan operational error: test cache error"
- name: "Check configuration: static test cache (yml) status"
ansible.builtin.uri:
url: http://localhost:11222/rest/v2/caches/configuredstaticcache
Expand All @@ -63,7 +58,7 @@
that:
- test_cache_status.status == 200
- test_cache_status.json.statistics
- test_cache_status.json.stats.total_number_of_entries == 0
- test_cache_status.json.stats.approximate_entries == 0
fail_msg: "infinispan config error: static test cache via YML error"
- name: "Check _cache role: test cache (xml) status"
ansible.builtin.uri:
Expand All @@ -75,7 +70,7 @@
ansible.builtin.assert:
that:
- test_cache_status.status == 200
- test_cache_status.json.stats.total_number_of_entries == 0
- test_cache_status.json.stats.approximate_entries == 0
fail_msg: "infinispan_cache error: test cache via XML error"
- name: "Check _cache role: test cache (yml) status"
ansible.builtin.uri:
Expand All @@ -88,7 +83,7 @@
that:
- test_cache_status.status == 200
- test_cache_status.json.statistics
- test_cache_status.json.stats.total_number_of_entries == 0
- test_cache_status.json.stats.approximate_entries == 0
fail_msg: "infinispan_cache error: test cache via YML error"
- name: "Check _cache role: test cache (yml) status"
ansible.builtin.uri:
Expand All @@ -101,5 +96,5 @@
that:
- test_cache_status.status == 200
- not test_cache_status.json.statistics
- test_cache_status.json.stats.total_number_of_entries == -1
fail_msg: "infinispan_cache error: test cache via YML error"
- test_cache_status.json.stats.approximate_entries == -1
fail_msg: "infinispan_cache error: test cache via YML error"
11 changes: 6 additions & 5 deletions roles/infinispan/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,11 @@ Role Defaults
|`infinispan_jvm_package`| RHEL java package runtime | `java-11-openjdk-headless` |
|`infinispan_service_name`| Name of the systemd service unit, appended with `-{{infinispan_port_offset}}` when not 0 | `infinispan` |
|`infinispan_service_desc` | Description of the systemd service unit | `Infinispan` |
|`infinispan_service_restart_on_failure`| systemd restart-on-failure behavior activation |True
|`infinispan_service_startlimitintervalsec`| systemd StartLimitIntervalSec | `300` if `infinispan_service_restart_on_failure` else ``
|`infinispan_service_startlimitburst`| systemd StartLimitBurst | `5` if `infinispan_service_restart_on_failure` else ``
|`infinispan_service_restartsec`| systemd RestartSec | `10s` if `infinispan_service_restart_on_failure` else ``
|`infinispan_service_restart_on_failure`| systemd restart-on-failure behavior activation | `True`` |
|`infinispan_service_startlimitintervalsec`| systemd StartLimitIntervalSec | `300` if `infinispan_service_restart_on_failure` else `` |
|`infinispan_service_startlimitburst`| systemd StartLimitBurst | `5` if `infinispan_service_restart_on_failure` else `` |
|`infinispan_service_restartsec`| systemd RestartSec | `10s` if `infinispan_service_restart_on_failure` else `` |
|`infinispan_resp_cache`| Name of the cache on which to enable the RESP protocol; if empty, disable RESP | `''` |


* Download and install defaults
Expand Down Expand Up @@ -87,7 +88,7 @@ The following are _required_ when `infinispan_jgroups_discovery` is `JDBC_PING`:

| Variable | Description | Default |
|:---------|:------------|:--------|
| `infinispan_jdbc_engine` | backend database engine (values: `['mariadb','postgres','sqlserver']`) | `mariadb` |
|`infinispan_jdbc_engine` | backend database engine (values: `['mariadb','postgres','sqlserver']`) | `mariadb` |
|`infinispan_jdbc_driver_version`| driver version to download | `2.7.4` |
|`infinispan_jdbc_url`| URL for jdbc connection | `jdbc:mariadb://localhost:3306/keycloak` |
|`infinispan_jdbc_user`| username for jdbc connection | `keycloak-user` |
Expand Down
7 changes: 5 additions & 2 deletions roles/infinispan/defaults/main.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
infinispan_version: "14.0.19.Final"
infinispan_version: "14.0.21.Final"
infinispan_bundle: "infinispan-server-{{ infinispan_version }}.zip"
infinispan_download_url: "https://downloads.jboss.org/infinispan/{{ infinispan_version }}/{{ infinispan_bundle }}"
infinispan_dest: /opt/infinispan
Expand All @@ -19,7 +19,7 @@ infinispan_jgroups_iface: default_ipv4
infinispan_service_user: ispn
infinispan_service_group: ispn
infinispan_port_offset: 0
infinispan_jvm_package: java-11-openjdk-headless
infinispan_jvm_package: java-17-openjdk-headless
infinispan_java_home:
infinispan_configure_firewalld: False

Expand Down Expand Up @@ -76,3 +76,6 @@ infinispan_logfile_maxsize: '100 MB'

# declarative cache configuration
infinispan_caches: []

# experimental redis protocol
infinispan_resp_cache: ''
6 changes: 5 additions & 1 deletion roles/infinispan/meta/argument_specs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -192,10 +192,14 @@ argument_specs:
default: "Infinispan"
description: "Description of the systemd service unit"
type: "str"
infinispan_resp_cache:
default: ""
description: "Name of the cache on which to enable the RESP protocol; if empty, disable RESP"
type: "str"
downstream:
options:
data_grid_version:
default: "8.4.1"
default: "8.4.6"
description: "Red Hat Data Grid version to install"
type: "str"
data_grid_installation_path:
Expand Down
8 changes: 5 additions & 3 deletions roles/infinispan/meta/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@ galaxy_info:
min_ansible_version: "2.14"

platforms:
- name: EL
versions:
- "8"
- name: EL
versions:
- "8"
- "9"

galaxy_tags:
- infinispan
Expand All @@ -26,3 +27,4 @@ galaxy_info:
- rhel
- rhn
- server
- cache
3 changes: 3 additions & 0 deletions roles/infinispan/templates/infinispan.xml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,9 @@
<endpoint socket-binding="default" security-realm="default">
{% endif %}
<hotrod-connector name="hotrod"/>
{% if infinispan_resp_cache | length > 0 %}
<resp-connector cache="{{ infinispan_resp_cache }}"/>
{% endif %}
<rest-connector name="rest">
<authentication mechanisms="DIGEST BASIC"/>
</rest-connector>
Expand Down
7 changes: 4 additions & 3 deletions roles/infinispan_cache/meta/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,10 @@ galaxy_info:
min_ansible_version: "2.14"

platforms:
- name: EL
versions:
- "8"
- name: EL
versions:
- "8"
- "9"

galaxy_tags:
- infinispan
Expand Down

0 comments on commit b74511e

Please sign in to comment.