summaryrefslogtreecommitdiff
path: root/taskflow
Commit message (Collapse)AuthorAgeFilesLines
...
| * Avoid log warning when closing is underway (on purpose)Joshua Harlow2017-08-011-1/+8
| | | | | | | | | | | | Related-Bug: #1557107 Change-Id: I8b2f327dadbf038cd050f05fbc46a428282a3d82
* | Remove class StopWatch from timingchenghuiyu2017-10-242-8/+2
| | | | | | | | | | | | | | | | In new release timeutils.StopWatch can be used from oslo.uitls, so it was deprecated for removal in timing.py Change-Id: I138b8d276998a4ea2537966767cbd14f96daf757 Closes-Bug: #1715043
* | Merge "Remove method blather in log adapter"2.17.0Zuul2017-10-241-7/+0
|\ \
| * | Remove method blather in log adapterchenghuiyu2017-09-041-7/+0
| |/ | | | | | | | | | | | | | | As method blather was using in new place, it was deprecated for removal in new release. Change-Id: Ic8d425e1774d6b7090ec105f2b37467a90c6e1e6 Closes-Bug: #1714873
* | Remove kwarg timeout in executor conductorchenghuiyu2017-09-011-3/+1
|/ | | | | | | The method stop returns immediately regardless of whether the conductor has been stopped, so kwarg timeout is no longer necessary, and it is deprecated for removal. Change-Id: I50e5cbb1a00eb9b6f358f150716d2a5d682a49c9
* Update URLs in documents according to document migrationChangBo Guo(gcb)2017-07-132-5/+5
| | | | Change-Id: I9ca92fdcec388e02462332e04fe7c1bf8b5f64b8
* Merge "Fix process based executor task proxying-back events"Jenkins2017-07-113-9/+87
|\
| * Fix process based executor task proxying-back eventsJoshua Harlow2017-07-113-9/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Let's dive into what the problem is here. First a description of what happens to a task that is to be executed in a external (but local) process via the process executor mechanism. When a task is about to be sent to execute in the external (but local) process its first cloned, this is mainly done so that its notification callbacks can be altered in a safe manner (ie not altering the original task object to do this) and that clone has its notifier emptied out. What replaces the clone's notifier callbacks though is a new object (that has a __call__ method so it looks like just another callback) that will send messages to the parent process (the one that has the engine in it) over a secure(ish) channel whenever the local task triggers its notifier notify() method. This allows for callbacks in the parent process to get triggered because once the messages recieved the original tasks notifier object has its notify() method called (therefore those callbacks do not really know the task they are getting messages from is executing out of process). The issue though is that if the ANY(*) event type is registered due to how it works in the notifier is that if the child/cloned notifier has the ANY event type registered and the cloned task calls notify() with a specific event this will cause the ANY callback (in the clone) to transmit a message *and* it will cause the *specific* event callback to also transmit a message back to the parent process. On the engine process side it will get 2 messages and trigger the callbacks 3 times (twice for the specific event callback because how the local notifier has the ANY callback registered and one more time when the local process also sends the same event based on its registration of the ANY event in the child process). This is not what is expected (the message rcved on the engine process should only trigger one callback to get triggered if the engine process task has no ANY callback registered or two engine process callbacks to get triggered if the engine process task has the ANY callback registered). Closes-Bug: #1537948 Change-Id: I271bf1f23ad73df6c177cf00fd902c4881ba44ae
* | turn on warning-is-error in doc buildDoug Hellmann2017-07-084-5/+7
|/ | | | | Change-Id: Id87a1b17c1986d0e30629fed13bdfbecef4a3603 Signed-off-by: Doug Hellmann <doug@doughellmann.com>
* Replace assertRaisesRegexp with assertRaisesRegexVu Cong Tuan2017-06-0313-102/+102
| | | | | | | | | | assertRaisesRegexp was renamed to assertRaisesRegex in Py3.2 For more details, please check: https://docs.python.org/3/library/ unittest.html#unittest.TestCase.assertRaisesRegex Change-Id: I89cce19e80b04074aab9f49a76c7652acace78b3 Closes-Bug: #1436957
* do not allow redis job reclaim by same ownerRick van de Loo2017-05-132-5/+26
| | | | | | | | | | | | | | | Running a nonblocking conductor or two conductors on the same host will re-execute the same job multiple times with the current implementation of 'claim' for the redis jobboard backend. This is different from the ZooKeeper jobboard backend, there the same owner of a job is not allowed to reclaim the job again (https://github.com/openstack/taskflow/blob/master/taskflow/jobs/backends/impl_zookeeper.py#L554). If the same owner is allowed to reclaim the job again there can be no concurrent execution on the same owner because all jobs will be re-claimed and re-executed by the same owner every pass as long as it's on the jobboard. To reproduce this behavior: - Use the redis jobboard backend - Create a flow with a task that sleeps 10 seconds in the execute method - Post that flow as a job - Run a nonblocking conductor It will claim and execute the same job multiple times in a loop until the first worker is finished and consumes the job. After this change it will not re-execute the same job multiple times. Change-Id: I4f6c364211500e510fc496f23b03ce056771417d
* Merge "Stop using oslotest.mockpatch"2.11.0Jenkins2017-05-051-5/+4
|\
| * Stop using oslotest.mockpatchChangBo Guo(gcb)2017-04-281-5/+4
| | | | | | | | | | | | This module has been deprecated in favor of native fixtures. Change-Id: I40ed7360091fea51a257807035e923c85602949f
* | Merge "python3.0 has deprecated LOG.warn"Jenkins2017-05-0316-82/+88
|\ \
| * | python3.0 has deprecated LOG.warnxhzhf2017-03-0716-82/+88
| |/ | | | | | | | | | | | | | | python3.0 has deprecated LOG.warn https://docs.python.org/3/library/logging.html#logging.warning Closes-Bug: #1650843 Change-Id: Ib8473cbdb84547f385e619fe08ed723b1ee7bcdb
* | Fix py35 test failureChangBo Guo(gcb)2017-05-031-1/+1
|/ | | | | | | | dict.keys() returns object dict_keys on Python 3, can't work well with kombu recently, convert it to list before futhur processing. Closes-Bug: #1687855 Change-Id: I9dcfadd8f16eccce06f4cde3b2a6669f28a3f8bc
* Protect storage better against external concurrent accessJoshua Harlow2017-01-092-44/+62
| | | | | | | | | Lock down the various state machine action handling functions so that they are ensured correct (and consistent) access to the storage layer when they are modifiying and/or reading it. Change-Id: Ie893a44aa963ab515f19e77f9904f49c843cb4e5
* Rename engine analyzer to be named selectorJoshua Harlow2017-01-035-67/+67
| | | | | | | | | | | | | This moves out the engine next to run (or revert) selection process to a single class that just does this and moves out the common functions the analyzer class provided to the runtime object (which all components can access). This makes it easier to adjust the selection algorithm in different ways. Change-Id: I091c69297a7bff60729791d3ca6c3fae14d6eea5
* Merge "Remove vim header from source files"Jenkins2016-11-182-4/+0
|\
| * Remove vim header from source fileshowardlee2016-11-092-4/+0
| | | | | | | | | | | | | | | | Trivial fix [H106] Don't put vim configuration in source files (off by default). Change-Id: I7e9e9930fd6f135074078637f5af6f403e75ff78
* | Use assertIs(Not)None to check for Nonehowardlee2016-11-072-6/+6
|/ | | | | | | | | | | | | [H203] Use assertIs(Not)None to check for None (off by default) Unit test assertions tend to give better messages for more specific assertions. As a result, assertIsNone(...) is preferred over assertEqual(None, ...) and assertIs(None, ...), and assertIsNotNone(...) is preferred over assertNotEqual(None, ...) and assertIsNot(None, ...). Off by default. Trivial fix Change-Id: I5b6ac7d99f0689843eb98cb3e9b9b10531322640
* Merge "Replace retrying with tenacity"Jenkins2016-11-051-9/+7
|\
| * Replace retrying with tenacityGevorg Davoian2016-11-031-9/+7
| | | | | | | | | | | | | | | | | | | | | | | | This patch replaces the legacy retrying library with the newer and more convenient tenacity one, taking into account that: 1) retrying uses milliseconds for wait times, but tenacity uses seconds; 2) retrying has a lot of numeric arguments for specifying behaviour of decorated functions, while tenacity has a few of them, which are specialized objects, thus making the retry-decorator more flexible. Change-Id: I4b165d37b2ecc210f2b94c103b73eaab51529261 Closes-Bug: #1635404
* | Fix broken linkAndreas Jaeger2016-11-031-1/+1
|/ | | | | | | | http://docs.openstack.org/developer/taskflow/utils.html points to http://docs.openstack.org/developer/taskflow/kazoo.readthedocs.org/ - fix the broken URL. Change-Id: I6f6650cef94cea9d6f138925e5e8d2ed6ea177c3
* Merge "Add logging around metadata, ignore tallying + history"Jenkins2016-10-112-24/+47
|\
| * Add logging around metadata, ignore tallying + historyJoshua Harlow2016-08-012-24/+47
| | | | | | | | | | | | | | | | This can be useful to look at for debugging purposes when trying to understand how (and if) a atom is being ignored by a set of deciders. Change-Id: I550a2f7f361e516c255683d725b2f3a8130a0a86
* | Using assertIsNone() instead of assertIs(None, ..)qinchunhua2016-10-101-2/+2
| | | | | | | | | | | | | | | | | | | | Following OpenStack Style Guidelines[1]: http://docs.openstack.org/developer/hacking/#unit-tests-and-assertraises [H203] Unit test assertions tend to give better messages for more specific assertions. As a result, assertIsNone(...) is preferred over assertEqual(None, ...) and assertIs(..,None). Change-Id: I52ecf3f4945c4cb99f6350afca1c51d88b16bb8d
* | Fix a typo in logging.pygengchc22016-09-281-3/+3
| | | | | | | | | | | | TrivialFix Change-Id: Idc9498e7697844fa42a8688880c026b36e60ed93
* | Use method ensure_tree from oslo.utilsChangBo Guo(gcb)2016-09-252-20/+2
| | | | | | | | | | | | Oslo.utils provides same function and just use it. Change-Id: Iac245d4d98c41edea5294a4d8842db69a42b3794
* | Make failure formatter configurable for DynamicLoggingListenerIvan Kolodyazhny2016-09-081-3/+8
| | | | | | | | | | | | | | | | | | DynamicLoggingListener uses only formatters.FailureFormatter to format errors. We should have API to pass formatter instance to DynamicLoggingListener to make it more flexible. Change-Id: I9658fbac97e4074b551a50d6016a92806a3636c1 Implements: blueprint dynamic-logging-listener-formatter-support
* | Some classes not define __ne__() built-in functionJi-Wei2016-08-316-0/+18
| | | | | | | | | | | | | | | | | | | | Some classes defines __eq__() built-in function, but does not define __ne__() built-in function, so self.assertEqual works but self.assertNotEqual does not work at all in this test case in python2. This patch fixes it. Change-Id: I3e4f213081268bad44583a63a84795d39094117f Closes-Bug: #1586268
* | Start to add a location for contributed useful tasks/flows/moreJoshua Harlow2016-07-281-0/+0
|/ | | | | | | | | Make it easy to denote a contrib path under taskflow that will contain features that others have contributed that we want in taskflow to bake and to make sure they are useful for others before say either promoting (or just leaving as is as contributed useful content). Change-Id: I65658be3856428997bc3a47289e8e1a0938f49e2
* Merge "Ensure the fetching jobs does not fetch anything when in bad state"Jenkins2016-07-251-8/+66
|\
| * Ensure the fetching jobs does not fetch anything when in bad stateJoshua Harlow2016-05-311-8/+66
| | | | | | | | | | | | | | | | | | | | When the underlying connection is in LOST or SUSPENDED mode do not allow jobs to be iterated over (and clear the local cache when the connection has been LOST). Related-Bug: #1557107 Change-Id: Ic0a2ab2519ff8a7386d80d9092a0e24579883681
* | Merge "Remove white space between print and ()"Jenkins2016-07-211-3/+3
|\ \
| * | Remove white space between print and ()haobing12016-07-181-3/+3
| | | | | | | | | | | | Change-Id: Ie181f5bdcd17b213586face17b8c6d9cbf6384db
* | | Replace assertEqual(None, *) with assertIsNone in testsweiweigu2016-07-124-8/+8
|/ / | | | | | | | | | | | | | | Replace assertEqual(None, *) with assertIsNone in tests to have more clear messages in case of failure. Change-Id: I74452af6d840bcf612fd3bb2521db9134460dd63 Closes-Bug: #1280522
* | remove unused LOGji-xuepeng2016-07-103-9/+0
| | | | | | | | | | | | This is to remove unused LOG to keep code clean. Change-Id: Ie44659f3b7af9612f127f7d46bb2c1481b6a634f
* | Merge "Fixes: typo error in comments"Jenkins2016-07-091-1/+1
|\ \
| * | Fixes: typo error in commentsrahulram2016-07-081-1/+1
| | | | | | | | | | | | Change-Id: I3e2bd1f4acaa9a36531b70d886d7407f59dfecb7
* | | Merge "Make tests less dependent on transient state"Jenkins2016-07-081-3/+2
|\ \ \
| * | | Make tests less dependent on transient stateGreg Hill2016-06-021-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Having to update the endpoint count every time you add a test class is really obnoxious and leads to a ton of pointless rebasing. Now we just check that it finds at least the task it knows about and call that good. Change-Id: I96b8c6cd6cbc1fdc58dee4b18cab5699e3daa844
* | | | Merge "Use the full 'get_execute_failures' vs the shortname"Jenkins2016-07-081-6/+6
|\ \ \ \
| * | | | Use the full 'get_execute_failures' vs the shortnameJoshua Harlow2016-05-281-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The usage of the full name is easier to read and easier to understand in the surronding code so prefer to use it. Change-Id: I1c43704ae7dfdba90217ce9a1c60cef8e2ce8632
* | | | | Merge "Fix some misspellings in the function name and descriptions"Jenkins2016-07-0813-21/+21
|\ \ \ \ \ | |_|_|/ / |/| | | |
| * | | | Fix some misspellings in the function name and descriptionsPablo Iranzo Gómez2016-06-3013-21/+21
| | | | | | | | | | | | | | | | | | | | Change-Id: I7e3451feb94b1f25b00c5e7b197bb6b527548306
* | | | | Merge "Add tests to verify kwargs behavior on revert validation"Jenkins2016-07-061-23/+41
|\ \ \ \ \ | |/ / / / |/| | | |
| * | | | Add tests to verify kwargs behavior on revert validationGreg Hill2016-06-091-23/+41
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A bug was reported where a task's revert method was throwing an 'extra args' exception even though it had a **kwargs to slurp up any extra args. I added some tests to duplicate the behavior but the tests all pass. I'm hoping pushing this up will cause CI to reproduce the bug so I can diagnose it further. Change-Id: I9f4d0f065f11370f7981e93349f473df2bb1015d Closes-Bug: #1589848
* | | | Don't use deprecated method timeutils.isotime2.2.0ChangBo Guo(gcb)2016-06-101-2/+2
|/ / / | | | | | | | | | | | | | | | | | | | | | This method was drepcated and will be removed in Ie8903e23fc88c03f4da78292a759d18c6a135064, so don't use it anymore. Change-Id: If2a6249cfd4ea1cb5eb4dfc4e3333ac9a5aafbf6
* | | Merge "Split revert/execute missing args messages"Jenkins2016-06-012-10/+17
|\ \ \