Configuring for the Bulk Load for PostgreSQL Database

The bulk load service provides a way to mass provision the inventory database with existing parties and items. A configuration file has been provided which needs to be configured with appropriate values before the bulk load is initiated.

Prerequisites

The data to load must be converted as CSV files if they are not already in that format. The PostgreSQL database is only able to read CSV files and treats these as a table. Inventory then applies the stored procedures to create internal items, item characteristics, item relationships, orders, parties, characteristics, relationships, and orders. See CSV File and JSON Config File Samples for examples of item.csv and items_characs.csv files.

Procedure

  1. If you have not already, create CSV files containing items, item characteristics, orders, item relationships, parties, party characteristics, and put these files in a directory on the TIBCO Fulfillment Subscriber Inventory server machine.
  2. Create a bulk load JSON configuration file (bulkConfig.json) on the TIBCO Fulfillment Subscriber Inventory server machine. See CSV File and JSON Config File Samples for an example of how the JSON configuration file should be constructed. This file can be saved in the $FSI_HOME/config/ file.
  3. Configure the following parameters in the bulk load JSON configuration file:
    Parameter Description
    oracleDirectoryName

    This is the absolute directory path where the csv files containing the data are to be loaded.

    timeStampFormat

    This is the timestamp format for the date/time columns that is used in the CSV exported data. Timestamps here follow the PostgreSQL notation. It is possible to customize the date/time format per entity for the date/time type of columns in the source data. One possible timestamp format is: "DD-MON-YYYY HH12.MI.SS PM". An example value of this format is: "01-JAN-2014 05.40.12 PM".

    commitSize

    Unlike the Oracle database, bulk load does not use this parameter. Keep the default.

    entities

    This is the list of entities to load. Each entity to load is a configuration object containing the following parameters:

    • type - This parameter defines the type of entity to load. It can be any one of the following types: FSI_PARTY, FSI_PARTY_CHARACTERISTIC, FSI_ITEM, FSI_ITEM_CHARACTERISTIC, FSI_ITEM_RELATIONSHIP, FSI_ITEM_ORDER, FSI_ITEM_ORDER_COMMENT
    • dataSourceName - This is the name of the CSV file.
    • dataSourceColumnList - This parameter is for the names of the columns in the CSV file. The possible values depend on the type of entity to load. Some columns are mandatory and some are optional. See Mandatory and Optional Columns for the list of mandatory and optional columns.
  4. Configure the path to the bulk load JSON config file in the ConfigValues_FSI.xml file. The value to configure is com.tibco.fos.fsi.bulk.configuration.