Github user mxmrlv commented on a diff in the pull request:

    https://github.com/apache/incubator-ariatosca/pull/20#discussion_r87984407
  
    --- Diff: aria/context/operation.py ---
    @@ -17,52 +17,113 @@
     Workflow and operation contexts
     """
     
    -from uuid import uuid4
     
    -from aria.logger import LoggerMixin
    +from .common import BaseContext
     
    -class OperationContext(LoggerMixin):
    +
    +class BaseOperationContext(BaseContext):
         """
         Context object used during operation creation and execution
         """
     
    -    def __init__(
    -            self,
    -            name,
    -            operation_details,
    -            workflow_context,
    -            node_instance,
    -            inputs=None):
    -        super(OperationContext, self).__init__()
    -        self.name = name
    -        self.id = str(uuid4())
    -        self.operation_details = operation_details
    -        self.workflow_context = workflow_context
    -        self.node_instance = node_instance
    -        self.inputs = inputs or {}
    +    def __init__(self, name, workflow_context, task, **kwargs):
    +        super(BaseOperationContext, self).__init__(
    +            name=name,
    +            model_storage=workflow_context.model,
    +            resource_storage=workflow_context.resource,
    +            deployment_id=workflow_context._deployment_id,
    +            workflow_id=workflow_context._workflow_id,
    +            execution_id=workflow_context._execution_id,
    +            parameters=workflow_context.parameters,
    --- End diff --
    
    remove


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to