Chapter 4. Configuration and Services

Table of Contents

4.1. Services Container
4.2. Services
4.2.1. Persistence
4.2.2. Identity
4.2.3. Security
4.2.4. Task Management
4.2.5. Journal and History

This chapter introduces the services configuration infraestructure provided by Nova Bonita as well as main services included in this Milestone version.

4.1. Services Container

The Process Virtual Machine technology includes a services container allowing the injection of services and objets that will be leveraged during workflow definition and execution. Objects and services used by the Bonita engine are defined through a XML file. A dedicated parser and a wiring framework are in charge of creating those objects. Security, identity, persistence, notifications, human task and timers are examples of pluggable services.

This services container (aka IoC container) can be configured through a configuration file. A default configuration file is included in the package under the /conf directory (environment.xml.mem).

Currently, following objects implementations can be injected in the environment:

  • repository: data repository storing workflow processes, instances, activities... Both in-memory (class org.ow2.bonita.repository.memory.MemoryRepository) and db persistence (class org.ow2.bonita.repository.db.DbRepository) implementations are included in this milestone.

  • recorder: object responsible of workflow execution logs. Default implementation handles workflow logs in the command line console (org.ow2.bonita.services.record.impl.LoggerRecorder). Recorder and Journal (see next) objects can be chained (new ones can be added as well on top of the recorder chainer). This give you a powerful mechanism to handle workflow execution data

  • journal: object responsible for storing or retrieving workflow execution data. Both in-memory (class org.ow2.bonita.services.record.impl.InMemoryJournal) and db persistence (class org.ow2.bonita.services.record.impl.DbJournal) implementations are provided.

  • archiver: object intended for workflow logs archiving. Default implementation handles logs on workflow data archiving through the default implementation (class org.ow2.bonita.services.record.impl.LoggerArchiver). Archiver and History (see next) objects can be chained (new ones can be added as well on top of the archiver chainer). This give you a powerful mechanism to handle workflow archived data

  • history: object intended for storing or retrieving workflow archieved data. Default implementation provided is the one available in the following class: org.ow2.bonita.services.record.impl.XMLHistory. This class will store workflow history in the file system as XML files

  • finished-instance-handler: action to perform when a workflow instance is finished. Default implementation is to store data for a particular workflow instace and to remove data from journal (class org.ow2.bonita.services.impl.DefaultActivityFactory). Journal and History objects implementations (described previously) are leveraged by this class.

As explained before both memory based vs persistence objects are provided as default implementations in the environment. Notice that in a persistence configuration additional resources are required, i.e for hibernate persistence you can specify mapings, cache configuration...