Skip to main content
Skip table of contents

Document Tracking

Contents

Tracked document flows are defined by assigning multiple workflow items and one workflow end at the corresponding component ports. All the documents that pass through the workflow items till the workflow end are logically grouped together as a single workflow and stored into the DB. Therefore each message send across a defined workflow is treated as a single workflow entry. A workflow entry can have multiple documents (one for each workflow item/end). The document contains the actual message that reaches the port (or a part of it, depending on the configuration).

Document Tracking in Event Processes section explains how to assign document tracking to a workflow.

The section below illustrates how to configure an external database for Document Tracking before starting to track.

Configuring Document Tracking

It is recommended using an external database for document tracking, which can be configured by providing the database configuration details in sbwdb.cfg file located in the Enterprise Server profile. To configure document tracking, perform the actions below:

  1. Configure sbwdb.cfgfile in the FES profile located at FIORANO_HOME/esb/server/profiles/<PROFILE NAME>/FES/conf by enabling all the properties related to the respective database and disabling the default settings.

    For example, to use an Oracle database,

    1. uncomment the following line:

      CODE
      #JDBC_DRIVER=oracle.jdbc.driver.OracleDriver
    2. comment out the default value below:

      CODE
      JDBC_DRIVER=org.h2.Driver


      Figure 1: sbwdb.cfg file data after commenting and commenting out properties for the Oracle database

      Follow the same process for all the properties where Oracle-specific details are enabled, and disable the default values.

      For an HA profile, configure the settings above in the secondary profile as well.



    3. To store the message as XML, set the REPRESENTABLE_DATA_TYPES property (property #12) to 'true'.

      Retaining the value as 'false' stores the message as a blob.



      Figure 2:  sbwdb.cfg file data with REPRESENTABLE_DATA_TYPES set to 'true'



  2. Add the driver in the FES server classpath in the FIORANO_HOME/esb/server/bin/server.conf under <java.classpath> section. 

    • Place the file in the FES machine to use the path.
    • Both absolute and relative paths will work.



  3. Restart the server.

    Check the server logs to ensure that there are no error messages during startup.

Creating SBW Tables Manually

If the server does not have enough permissions to create the sbw tables, then tables can be manually created using the following SQL queries:

CODE
create table TES_SBW_SCHEMA_VERSION (VERSION integer)
create table TIFOSI_DB_HEALTH (HEALTH varchar(800))

If REPRESENTABLE_DATA_TYPES is set to 'false', then use the following query to create WF_INST_EVENT_HISTORY table:

CODE
create table WF_INST_EVENT_HISTORY (EVENT_ID integer, WORKFLOW_INSTANCE_ID varchar(800), WORKFLOW_ID varchar(800), USER_DEFINED_DOC_ID varchar(800), SERVICE_INST_ID varchar(800), STATE_ID varchar(800), STATE_COMMENT varchar(800), STATE_EVENT_DATE varchar(800), DOCUMENT_ID varchar(800), WORKFLOW_STATUS varchar(800), IN_TIME DATE, OUT_TIME DATE, TOTAL_TIME varchar(800), WF_VERSION varchar(800), DOCUMENT BLOB, HAS_BEEN_RESET varchar(4))

If REPRESENTABLE_DATA_TYPES is set to 'true', then use the following query to create WF_INST_EVENT_HISTORY table:

CODE
create table WF_INST_EVENT_HISTORY (EVENT_ID integer, WORKFLOW_INSTANCE_ID varchar(800), WORKFLOW_ID varchar(800), USER_DEFINED_DOC_ID varchar(800), SERVICE_INST_ID varchar(800), STATE_ID varchar(800), STATE_COMMENT varchar(800), STATE_EVENT_DATE varchar(800), DOCUMENT_ID varchar(800), WORKFLOW_STATUS varchar(800), IN_TIME DATE, OUT_TIME DATE, TOTAL_TIME varchar(800), WF_VERSION varchar(800), HAS_BEEN_RESET varchar(4))
ALTER TABLE WF_INST_EVENT_HISTORY ADD MESSAGE XMLTYPE XMLTYPE MESSAGE STORE AS CLOB
ALTER TABLE WF_INST_EVENT_HISTORY ADD MESSAGE_HEADERS XMLTYPE XMLTYPE MESSAGE_HEADERS STORE AS CLOB
ALTER TABLE WF_INST_EVENT_HISTORY ADD MESSAGE_ATTACHMENTS XMLTYPE XMLTYPE MESSAGE_ATTACHMENTS STORE AS CLOB
ALTER TABLE WF_INST_EVENT_HISTORY ADD MESSAGE_CFWD_PROPERTIES XMLTYPE XMLTYPE MESSAGE_CFWD_PROPERTIES STORE AS CLOB
ALTER TABLE WF_INST_EVENT_HISTORY ADD MESSAGE_CFWD_SRC_CONTEXT XMLTYPE XMLTYPE MESSAGE_CFWD_SRC_CONTEXT STORE AS CLOB

Tracking in the Dashboard

To track data and manage the tracked data, log on to the Dashboard (Fiorano Web Console) and navigate to the Document Tracking tab on the left navigation panel.

For further information, please refer to the Document Tracking section in the Dashboard page.

Re-injecting a failed document

If a document fails in a workflow, it can be re-injected from the Document Tracking tab in the Dashboard.

Refer to the Re-injecting Failed Documents section which illustrates how to re-inject failed document(s).

Deleting Document Tracking data 

To avoid issues such as Low Disk Space error, free some disk space by discarding old entries in the Document Tracking Database.

Refer the sections below:

In case of H2 database, SBW documents can be manually cleared by deleting the EnterpriseServers/{profile_name}/doctracking_db folder inside runtimedata directory. The server needs to be restarted after performing this action.

Please note that Fiorano recommends taking guidance from the Fiorano Technical Support Team before the manual intervention.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.