We have been caching the paths to the plugins but before we would only
cache the specific plugin that we were looking for. This meant that we
might search through all of the plugin directories before finding the
specific module we were interested in. The next plugin we needed we
might again search through all the plugin directories before finding the
plugin we wanted.
This new code will cache all the potential plugins in each directory
searched. For a play that only uses one plugin we'll only search
through directories until we encounter the directory that has the proper
plugin. For a large playbook with many plugins used we'll search
through each directory at most once each.
From v1: 68e86de26f730c2ba403
We have been caching the paths to the plugins but before we would only
cache the specific plugin that we were looking for. This meant that we
might search through all of the plugin directories before finding the
specific module we were interested in. The next plugin we needed we
might again search through all the plugin directories before finding the
plugin we wanted.
This new code will cache all the potential plugins in each directory
searched. For a play that only uses one plugin we'll only search
through directories until we encounter the directory that has the proper
plugin. For a large playbook with many plugins used we'll search
through each directory at most once each.
This should alleviate #10165
When using the "creates" option with the script module, set changed
to False if the file already exists. This behavior is consistent with
other modules which use "creates", such as command and shell.
When using the "creates" option with the unarchive module, set changed
to False if the file already exists. This behavior is consistent with
other modules which use "creates", such as command and shell.
It's up to the module using the set_fs_attributes*/set_mode* methods to
specify the filename of the destination of the symlink if that's really
the file that should be modified.
Half of the fix for:
https://github.com/ansible/ansible-modules-core/issues/778