Commit Graph

48 Commits (3f3e3e3d5bdf042a0ef733477673fa703d97ccba)

Author SHA1 Message Date
Toshio Kuratomi f4d68b8860 Transform tracebacks into unicode before printing
Fixes #14042
2016-01-25 19:18:59 -08:00
James Cammarata 120b9a7ac6 Changing the way workers are forked 2015-12-11 23:35:07 -05:00
James Cammarata 80db6bacc4 Make sure run_once tasks properly set variables for all active hosts
Fixes #13267
2015-11-30 11:27:05 -05:00
James Cammarata 25807f5404 Don't modify things we've put on the queue
Fixes #12937
2015-11-17 14:22:52 -05:00
James Cammarata 5cbeab5a3c Performance improvements for HostVars and some bugfixes 2015-11-16 17:15:52 -05:00
James Cammarata 2b25b7974c Remove unnecessary sleep from result process 2015-11-13 16:45:45 -05:00
James Cammarata 13750f68ee Reduce spinning while waiting on queues 2015-11-12 14:41:09 -05:00
James Cammarata efbc6054a4 Add variable compression option 2015-11-05 16:22:37 -05:00
James Cammarata 63c47fb271 Fixing up performance 2015-11-05 16:22:37 -05:00
Brian Coca f5b095f6c8 properly sanitize registered vars 2015-10-30 16:42:06 -04:00
Brian Coca b6c92dacb5 removed key striping as they are read up the chain 2015-10-30 14:03:37 -04:00
Brian Coca 8ce864db6f sanatize results 2015-10-24 15:23:12 -04:00
James Cammarata 86de1429e5 Cleaning up FIXMEs 2015-10-22 16:03:50 -04:00
James Cammarata 1fa975d81a Simplify group_by by removing BYPASS_HOST_LOOP from the action
Fixes #12825
2015-10-19 14:57:07 -04:00
Toshio Kuratomi a526eae543 Clean up a few more pyflakes warnings 2015-10-19 11:20:21 -07:00
Toshio Kuratomi baa309309d Bundle a new version of python-six for compatibility along with some code to make it easy for distributions to override the bunndled copy if they have a new enough version. 2015-10-16 08:21:28 -07:00
James Cammarata a3e913da62 Don't assume handlers exist in the same role (if any)
Fixes #12536
2015-09-29 14:52:43 -04:00
James Cammarata 31d5f88a1d Use the task loop to calculate multiple delegated hosts
Due to the way we're now calculating delegate_to, if that value is based
on a loop variable ('item') we need to calculate all of the possible
delegated_to variables for that loop.

Fixes #12499
2015-09-25 01:41:09 -04:00
James Cammarata bde5ed9672 Catch worker errors that may be subclassed on others that lead to incorrect exits 2015-09-17 14:46:53 -04:00
James Cammarata c2115c3715 Re-adding part of 926f127 which was actually fixing #12277 2015-09-11 09:45:27 -04:00
James Cammarata 083aef65ad Revert "set_fact should put facts in the fact_cache, not vars_cache"
This reverts commit 926f127245.
2015-09-11 09:45:27 -04:00
James Cammarata 926f127245 set_fact should put facts in the fact_cache, not vars_cache
Also fixes a template path lookup issue when using an include

Fixes #12277
2015-09-09 11:10:18 -04:00
Marius Gedminas 37be9539ff Python 3: use six.text_type instead of unicode
Replace 'unicode' with six.text_type, everywhere but in module_utils.
2015-09-04 08:40:10 +03:00
Marius Gedminas 823677b490 Replace .iteritems() with six.iteritems()
Replace .iteritems() with six.iteritems() everywhere except in
module_utils (because there's no 'six' on the remote host).  And except
in lib/ansible/galaxy/data/metadata_template.j2, because I'm not sure
six is available there.
2015-09-03 09:23:27 +03:00
Marius Gedminas 0c6ce31f76 Use 'except ... as' syntax
This syntax works on Python 2.6 through 3.x.  lib/ansible/module_utils
(and lib/ansible/modules) need to support Python 2.4, so I didn't touch
those.
2015-08-27 22:15:04 +03:00
Toshio Kuratomi 6e107d2f22 Comments pointing the way towards substituting cryptography for pycrypto 2015-08-24 15:50:37 -07:00
Brian Coca 2198f48f54 changed check to avoid OS X broken sem_getvalue()
fixes #11988
2015-08-18 03:46:20 -04:00
James Cammarata e7b2308b66 Performance improvements
* Speed up serialization of hostvars by simply using the internal
  dictionary used for cached lookups
* Use blocking gets/puts on queues instead of spin locking
* Merge sequential implicitly created blocks
2015-08-17 13:46:57 -04:00
James Cammarata 42cfacf83b Switch up the task/host overrides for PlayContext to use the compiled vars dict
Fixes #11436
2015-07-28 16:25:44 -04:00
James Cammarata cb262449c7 Reworking internal result flags and making sure include_vars hides vault data
Fixes #10194
2015-07-27 14:04:31 -04:00
James Cammarata e64989beb4 Moving ConnectionInformation -> PlayContext
Also making PlayContext a child class of the Playbook Base class,
which gives it access to all of the FieldAttribute code to ensure
field values are correctly typed after post_validation

Fixes #11381
2015-07-21 12:13:50 -04:00
James Cammarata dca36c1d16 Reestablishing the use of tags/when for role duplication detection
Not figuring these in can cause problems with "diamond" pattern relationships,
even though this is still not quite optimal.
2015-07-20 14:37:20 -04:00
James Cammarata 271a7f3281 Cleaning up some of the notify/facts logic added earlier to fix problems 2015-07-17 14:44:19 -04:00
James Cammarata 5abdd3b821 Handle notifications when coupled with a loop
Fixes #11606
2015-07-17 12:03:04 -04:00
Brian Coca b76cb8f655 now that invocation is only async again, no need to sanitize 2015-07-15 10:40:37 -04:00
James Cammarata 0b035a4e35 Unicode in result debug statements caused a traceback 2015-07-15 01:56:28 -04:00
Brian Coca 4203b699a8 removed dict comprehension as 2.6 does not like 2015-07-11 15:15:46 -04:00
Brian Coca 1274ce565d added result sanitation to registered var and to callbacks
removed time display as it only is provided by command module
2015-07-11 01:05:29 -04:00
James Cammarata b520d5bc60 Lots of fixes for integration test bugs 2015-07-10 01:53:59 -04:00
James Cammarata 27fcf1a4b5 Fix bug in registered variables related to delegate_to changes 2015-07-08 12:38:24 -04:00
James Cammarata 8f0496d7ce Fix usage of set_host_var when registering a result var
Fixes #11521
2015-07-08 09:15:55 -04:00
James Cammarata 293dd38d05 Correctly handle assigning results to the delegated to host 2015-07-07 16:09:36 -04:00
James Cammarata 1d8ccfb99f Fixing includes where the included file is "{{item}}" 2015-07-06 14:30:56 -04:00
James Cammarata ec4d1b11df Fix some more handler issues
* Only notify handlers when the task is changed
* Don't run handlers on hosts which have failed
2015-06-30 14:44:41 -04:00
Benno Joy be81b650e8 fixes issue 11286 where role handlers are not run 2015-06-21 00:36:37 -04:00
James Cammarata daa319881f Make sure registered variable message is sent before other messages
Avoids a race condition where previously the registered variable message
was being sent after the 'host_task_ok' message, meaning the next task
may be started before the var is registered, leading to an undefined
variable error
2015-06-17 12:42:47 -04:00
James Cammarata daf533c80e V2 fixes
* PluginLoader class will now be more selective about loading some
  plugin classes, if a required base class is specified (used to avoid
  loading v1 plugins that have changed significantly in their apis)
* Added ability for the connection info class to read values from a
  given hosts variables, to support "magic" variables
* Added some more magic variables to the VariableManager output
* Fixed a bug in the ActionBase class, where the module configuration
  code was not correctly handling unicode
2015-05-11 11:29:48 -05:00
James Cammarata ce3ef7f4c1 Making the switch to v2 2015-05-03 21:47:26 -05:00