Skip to content

Commit

Permalink
correct some typos add some clarifications
Browse files Browse the repository at this point in the history
  • Loading branch information
essweine committed Apr 16, 2024
1 parent 3ca0a57 commit a9dedfe
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 10 deletions.
7 changes: 7 additions & 0 deletions doc/bpmn/application.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,13 @@ We'll mainly focus on the engine, as it contains the interface with the library,
the other components. The engine is quite small and simple compared to the code required to handle user input and
display information in a terminal.

.. warning::

This application is *not* a robust application and won't be suitable for displaying large amounts of data, which
may cause it to crash. The application won't run unless your terminal is at least 13 lines high. It also may
randomly crash at other times as well. While I'll make improvements as I add more examples and bug reports and/or
fixes are always welcome, my focus is on using the library rather than the UI.

Configuration is set up in a python module and passed into the application with the `-e` argument, which loads the
configured engine from this file. This setup should make it relatively to change the behavior of engine. The
following configurations are included:
Expand Down
17 changes: 9 additions & 8 deletions doc/concepts.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,17 @@ SpiffWorkflow consists of two different categories of objects:
- **Specification objects**, which represent definitions of structure and behavior and derive from :code:`WorkflowSpec` and :code:`TaskSpec`
- **Instance objects**, which represent the state of a running workflow (:code:`Workflow`/:code:`BpmnWorkflow` and :code:`Task`)

In the workflow context, a specification is model of the workflow, an abstraction that describes *every path that could
be taken whenever the workflow is executed*. An instance is a particular instantiation of a specification. It describes *the
current state* or *the path(s) that were actually taken when the workflow ran*.
For workflows, a specification is model of the workflow, an abstraction that describes *every path that could
be taken whenever the workflow is executed*. An instance is an execution of a specification. It describes *the current state*
or *the path(s) that were actually taken when the workflow ran*.

In the task context, a specification is a model for how a task behaves. It describes the mechanisms for deciding *whether
For tasks, a specification is a model for how a task behaves. It describes the mechanisms for deciding *whether
there are preconditions for running an associated task*, *how to decide whether they are met*, and *what it means to complete
(successfully or unsuccessfully)*. An instance describes the *state of the task, as it pertains to a particular workflow* and
*contains the data used to manage that state*.
(successfully or unsuccessfully)*. An instance describes the *state of the task, as it pertains to the workflow it is part of*
and *contains the data used to manage that state*.

Specifications are unique, whereas instances are not. There is *one* model of a workflow, and *one* specification for a particular task.
Specifications are unique, whereas instances are not. There is *one* model of a workflow, and *one* specification for a
particular task. The model can be executed many times, and within one execution, a task spec may also be reached many times.

Imagine a workflow with a loop. The loop is defined once in the specification, but there can be many tasks associated with
each of the specs that comprise the loop.
Expand Down Expand Up @@ -104,7 +105,7 @@ to Task State. These hooks are:
* `run_hook`: This method implements the task's behavior when it is run, returning:

- :code:`True` if the task completed successfully. The state will transition to **COMPLETED**.
- :code:`False` if the task completed unsucessfully. The state will transition to **ERRROR**.
- :code:`False` if the task completed unsucessfully. The state will transition to **ERROR**.
- :code:`None` if the task has not completed. The state will transition to **STARTED**.

* `_on_complete_hook`: This method will be run when the task's state is changed to **COMPLETED**.
Expand Down
2 changes: 1 addition & 1 deletion doc/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ What is SpiffWorkflow?

SpiffWorkflow is the workflow library underlying `Spiff Arena <https://github.com/sartography/spiff-arena>`_.

It consists of a generic core library, with packages supporting parsing and execution of BPMN diagrams that extend
It consists of a generic core library, with modules supporting parsing and execution of BPMN diagrams that extend
this core.

Extensive documentation about BPMN and how SpiffWorkflow interprets it, as well as information about custom extensions
Expand Down
2 changes: 1 addition & 1 deletion doc/modules.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ capabilities.

- Specs implementations are in :code:`specs`
- Workflow implementation is in :code:`workflow.py`
- Task implementation is in :code:`task.py`, with utilities for iteration and filtering in :code:`util.task.py`
- Task implementation is in :code:`task.py`, with utilities for iteration and filtering in :code:`util/task.py`

It is documented in :doc:`core/index`.

Expand Down

0 comments on commit a9dedfe

Please sign in to comment.