Working with the DatabaseCache Project

The DatabaseCache project contains a process that shows how to use TIBCO ActiveMatrix BusinessWorks Plug-in for ActiveSpaces to query and store tuples in a space.

The process is designed with the following activities:

The following table describes the activities in this process:

Activity Description
FilePoller Reads the input.txt file to monitor if an input ID or the key specified in the space is created or changed. When the activity obtains an ID, it triggers the process.

The input.txt file is located in the TIBCO_HOME/bw/palettes/activespaces/version_number/samples/DatabaseCache/data directory.

Get From Space Queries a tuple in the space with the ID specified in the input.txt file.
Read Database File Reads the database.data file and sends the contents to the output of this activity.
Parse Data Retrieves the input from the output of the Read Database File activity and parses the data of the input based on the data format specified in the General tab.
Map Data Maps the data values in a tuple to the elements of the root variable if the tuple matches the input ID in the input.txt file.

The Root variable is a process variable added to the process definition by this activity and specified in the Input tab. The structure of the root is defined based on the field names specified in the space.

Cache Info Space Stores the output tuple of the Map Data activity in the space.