mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 12:50:22 -07:00
make windows async ... async (#22624)
Fixes #22575 - issue under new exec wrapper where unconstrained handle inheritance (for stdin) caused WinRM to block on breakaway processes. Uses explicit handle inheritance to ensure that only stdin read handle gets inherited. Adds test to ensure that async is actually async.
This commit is contained in:
parent
89559f78de
commit
ce56da69b2
2 changed files with 75 additions and 14 deletions
|
@ -1,3 +1,7 @@
|
|||
- name: capture timestamp before fire and forget
|
||||
set_fact:
|
||||
start_timestamp: "{{ lookup('pipe', 'date +%s') }}"
|
||||
|
||||
- name: async fire and forget
|
||||
async_test:
|
||||
sleep_delay_sec: 5
|
||||
|
@ -12,6 +16,8 @@
|
|||
- asyncresult.started == 1
|
||||
- asyncresult.finished == 0
|
||||
- asyncresult.results_file is search('\.ansible_async.+\d+\.\d+')
|
||||
# ensure that async is actually async- this test will fail if # hosts > forks or if the target host is VERY slow
|
||||
- (lookup('pipe', 'date +%s') | int) - (start_timestamp | int) < 5
|
||||
|
||||
- name: async poll immediate success
|
||||
async_test:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue