Issuu on Google+

TIA XML Print Solution

TECHNICAL OVERVIEW

Oriac TIA XML Print Solution Integrating TIA with Adobe Output Server using XML

Introduction The complete solution consists of three separate systems: TIA Print System, Adobe Output Server and the XML Generation System. Please refer to the diagram called 'TIA XML Print Solution - Process Model' on the last page when reading the overview.

TIA Print System All the features of the standard TIA Print System are supported by this solution and no changes to TIA core are necessary. A print request from TIA is initiated by inserting a new row in the Print_Request table. This request can be initiated from any subsystem in TIA that needs to generate documents i.e. Product Documents, Renewals, Reminders, Claims or Standard Letters. The print request row contains key data such as policy number, customer number, document name etc. This key data will later be used by the XML Generation System to extract the required document data from TIA. The print request contains certain data already formatted, such as the recipient's address, salutation and signature information. This formatted data is generated automatically just before the print request is created by calling a TIA user function called UF20_Name_Letter used to create the address and salutation in a printable format. The Print_Argument table used to store the 'paragraph wording' of any document that utilises dynamic wording (typically standard letters). A print request can be either for 'online' or 'batch', which will be selected by the TIA user. These modes of print requests are differentiated by a flag set to either 'B' for batch or 'X' for online. The user can manually choose which printer to output to for online print requests.

XML Generation System (XGS) All of the processes described here are performed in the Oracle database, that is to say they have been created as database procedures or functions, written in PL/SQL. The 'XGS Daemon' processes any online print requests as soon as they are created. This daemon program calls XGS_Main.Start_Online every time a new print request is inserted into the Print_Request table (or an existing one is updated). This is achieved by use of a database trigger on the Print_Request table that sends a message to the XGS Daemon (which is otherwise 'sleeping'), telling it to wake-up and do some work.

Copyright Š 2004, Oriac Information Systems Ltd. All rights reserved.

Page 1 of 4


TIA XML Print Solution

TECHNICAL OVERVIEW

All batch print requests will be processed when XGS_Main.Start_Batch is run. This can be called from a batch job administered in the TIA Batch System, or run manually from a test screen within TIA called XGSBat. The XML Generation System is modular, giving the advantage that the library processes can be called from both the Online process and the Batch process. The extract program to be called initially is determined by the document id in the print request. Every document to be processed by the XML Generation System has to have a row created in a TIA table called Print_Program. This table contains parameters and data, which influence how the document will be processed, including: Ø Setting the archive flag (to tell Adobe Output Server to save a pdf file to the Archive directory). Ø Default values for email subject and message (used when the TIA user has selected the printer used to flag an email request). Ø The physical extract program (e.g. XML_PL01) to be called when processing a print request for this document. The initial extract program that is executed makes calls to a library of processes used for extracting data from TIA and generating an XML data stream. These processes are spread between two database packages: Ø XGS_Util, which consists of routines used to create the XML constructs and the Adobe_Config_Header record (used to manipulate the Adobe Output Server). Also contains other routines primarily developed to be used by the XML Generation System, but could potentially be used by other TIA processes. Ø XGS_Data, which contains a modular set of data extract processes customised for a specific TIA installation. Any errors encountered by the XML Generation System are reported in a table called XGS_Errors. If the trace facility is switched on (TIA site preference), messages are written to a table called XGS_Trace to help trace faults. The final step of processing the print request is to finalise the XML data stream and update the print request as 'processed' (by appending 'P' to status flag e.g. 'XP' for online request). For installations where TIA is running on a Unix platform the XML data stream is written as a file to the Unix file system. A Unix daemon program running in the background called 'aos_pq_feed.sh', writes this file to a virtual printer called 'aos_pq_feed'. This virtual printer is a print queue that spools the file to another virtual printer on the Adobe Output Server machine called aos_pq (also known as the Adobe Print Processor). The use of virtual printers in this way serves to bridge the network between the Unix file system and the Adobe Output Server, which is running on a Wintel machine. For installations where TIA (the database server) is running on a Wintel platform, the XML data stream is written directly to the aos_pq virtual printer on the Adobe Output Server.

Copyright © 2004, Oriac Information Systems Ltd. All rights reserved.

Page 2 of 4


TIA XML Print Solution

TECHNICAL OVERVIEW

Adobe Output Server (AOS) The virtual printer 'aos_pq' spools the files it receives to a specific location being polled by AOS. Actually, it does slightly more than simply spool the file. It also renames the file (e.g. jf46.dar) to guarantee uniqueness to AOS and more importantly it adds the name of the 'print job' to the first line of XML. The print job tells AOS the steps that AOS needs to take to process the XML data file. At this stage the print job is always DEFAULTJOB, which triggers further processing by AOS to determine the actual print job. It does this by transforming the XML data file using an XSLT file which is a key component of this solution. The templates and graphic files are stored on the AOS machine within a logical directory. The structure consists of the following key elements: Country, Product and Language. For example, 'd:\program files\adobe\tia_project\be\pl\f\templates', could be where AOS will look for templates for a Belgium product for Professional Liability. The elements for deriving the file path are values in the XML file, more specifically in the Adobe_Config_Header record. This record forms part of the XML file and is generated by the XML_Util package. It contains all the parameters that AOS needs to process the data file such as output destination, printer driver, archive indicator etc. The following extract shows how the Adobe_Config_Header looks in an XML file that was generated for an online print request in: <adobe_config_header> <output_channel>ondemand</output_channel> <printer>HPLASERJET/Q</printer> <printer_driver>HPLJ4</printer_driver> <archive_flag>yes</archive_flag> <archive_file_name>565755</archive_file_name> <country>BE</country> <product>PL</product> <language>F</language> <attachment_name>PL05_565755</attachment_name> </adobe_config_header>

This listing does not give a complete picture of the Adobe_Config_Header record, because certain fields will not be relevant for an 'ondemand' print request, such as email information. AOS writes to a log file, which contains logging information and error messages. If an error occurs, the data file along with an error file is written to an error directory. If backup is enabled then all processed data files will be copied to the backup directory. Depending on the 'output channel' the rendered document will either be output to a printer on the network, sent as an email attachment or sent as a facsimile.

Copyright Š 2004, Oriac Information Systems Ltd. All rights reserved.

Page 3 of 4


TIA XML Print Solution

TECHNICAL OVERVIEW TIA XML Print Solution - Process Model

TIA Print System

Product Documents

Standard Letters

Reminder Letters

XGS_Data

XML Generation System

Renewal Letters

XGS_Util

UF20_Name_ Letter

Print_ Request

Print_ Argument

TIA

TIA Database

XML_xxnn

Unix

aos_pq_ feed.sh

XML Data File

XGS Daemon On Demand

Start_Online XGS_Main

Unix W intel

Start_Batch

Batch XGSBat

Document Template

XML Data Stream

aos_pq_feed (unix virtual print queue)

Print Queue

Logos

Network printer

Adobe Output Server (Wintel box)

aos_pq (Adobe print processor)

Adobe Output Server

Rendered document

Mail Server Email recipient

archived pdf file

Fax Server

Network Fax recipient

Copyright Š 2004, Oriac Information Systems Ltd. All rights reserved.

Page 4 of 4


XML Print Solution