Github user ran-z commented on a diff in the pull request:
https://github.com/apache/incubator-ariatosca/pull/95#discussion_r111162387
--- Diff: aria/modeling/orchestration.py ---
@@ -200,15 +200,52 @@ class PluginBase(ModelMixin):
class TaskBase(ModelMixin):
"""
- A Model which represents an task
+ Represents the smallest unit of stateful execution in ARIA. The task
state includes inputs,
+ outputs, as well as an atomic status, ensuring that the task can only
be running once at any
+ given time.
+
+ Tasks may be "one shot" or may be configured to run repeatedly in the
case of failure.
+
+ Tasks are often based on :class:`Operation`, and thus act on either a
:class:`Node` or a
+ :class:`Relationship`, however this is not required.
+
+ :ivar node: The node actor (optional)
+ :vartype node: :class:`Node`
+ :ivar relationship: The relationship actor (optional)
+ :vartype relationship: :class:`Relationship`
+ :ivar plugin: The implementing plugin (set to None for default
execution plugin)
+ :vartype plugin: :class:`Plugin`
+ :ivar inputs: Parameters that can be used by this task
+ :vartype inputs: {basestring: :class:`Parameter`}
+ :ivar implementation: Python path to an ``@operation`` function
+ :vartype implementation: basestring
+ :ivar max_attempts: Maximum number of retries allowed in case of
failure
+ :vartype max_attempts: int
+ :ivar retry_interval: Interval between retries (in seconds)
+ :vartype retry_interval: int
+ :ivar ignore_failure: Set to True to ignore failures
+ :vartype ignore_failure: bool
+ :ivar due_at: Timestamp to start the task
+ :vartype due_at: datetime
+ :ivar execution: Assigned execution
+ :vartype execution: :class:`Execution`
+ :ivar status: Current atomic status ('pending', 'retrying', 'sent',
'started', 'success',
+ 'failed')
+ :vartype status: basestring
+ :ivar started_at: Timestamp for when task started
+ :vartype started_at: datetime
+ :ivar ended_at: Timestamp for when task ended
+ :vartype ended_at: datetime
+ :ivar retry_count: How many retries occurred
+ :vartype retry_count: int
"""
__tablename__ = 'task'
__private_fields__ = ['node_fk',
'relationship_fk',
'plugin_fk',
- 'execution_fk',
--- End diff --
:+1:
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---