Skip to content

Conversation

@amemon-redhat
Copy link
Collaborator

No description provided.

@kksat
Copy link
Contributor

kksat commented Jul 28, 2025

is there ARA recording for this test?

Copy link
Contributor

@kksat kksat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's have a discussion in our regular meeting

@amemon-redhat
Copy link
Collaborator Author

@amemon-redhat
Copy link
Collaborator Author

{{ current_ascs_host_info.instances | selectattr('mSystemNumber', 'equalto', sap_ascs_instance_number) | list }}
msg_server_process_list: >-
{{ (ascs_instance_list | first)['ProcessList'] | selectattr('name', 'equalto', 'msg_server') | list
if ascs_instance_list | length > 0 else [] }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think usual ansible approach to make sure you get list as a result is not to use if but to use ansible.builtin.default filter like so "{{ list | selectattr('name','equalto','something') | ansible.builtin.default([]) }}" - this will be [] (empty list if the first expression fails)

ansible.builtin.set_fact:
sap_ascs_node_name_original: "{{ sap_ascs_node_name }}"

# ============================================================================
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if you want to separate actions, I think comments is not the best place to do that. You might separete them into different role task files and include them like so:

- name: Prerequisite
  ansible.builtin.include_tasks:
    file: prerequisite.yml

ansible.builtin.set_fact:
sap_ascs_node_name_original: "{{ sap_ascs_node_name }}"

# ============================================================================
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if you want to separate actions, I think comments is not the best place to do that. You might separete them into different role task files and include them like so:

- name: Prerequisite
  ansible.builtin.include_tasks:
    file: prerequisite.yml

Same for main logic, you can separate it into separate taks file

@amemon-redhat amemon-redhat assigned amemon-redhat and unassigned kksat Oct 14, 2025
@amemon-redhat
Copy link
Collaborator Author

@kksat
https://ara.saponrhel.org/playbooks/1537.html

Done consolidating and combining some repeated tasks.

@amemon-redhat amemon-redhat assigned kksat and unassigned amemon-redhat Oct 16, 2025
@amemon-redhat
Copy link
Collaborator Author

looks like we have some issues with git hub at the moment: saving the last successful test run: https://ara.saponrhel.org/playbooks/1538.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants