Home Download RBT v1.3.1

Application Installation

Getting Started

RBT is a Java EE web application requiring a a web container running Java SE 6 update 5 or higher and Java EE 5 or higher. The installer must have a working knowledge of J2EE deployment descriptors and be able to edit the web.xml of a J2EE web application.

To begin the installation, download rbt-1.3.1.zip from the web site and unzip the contents into a work directory - zip file contents are shown below:

  • rbt-1.3.1.war - web application archive
  • rbtapi.jar - api library for customization
  • rbtdoc.zip - web files containing rbt documentation
  • javadocs.zip - rbtapi javadocs
  • examples directory - contains example deployment descriptor, configuration file and database scripts
  • dbscripts directory - contains sql scripts to create RBT security tables in Oracle, SQL Server and MySQL
  • xmlschemas directory - contains XML schemas defining DBT XML objects used in the application

Prior to installing RBT you must create the security database objects. In the examples directory you will find the following scripts for creating the database tables:

RBT has been tested on on the databases shown above. The scripts can be run to create the required database objects. For databases not in the list, use one of the scripts as an example. RBT should work with any SQL 92 compliant database that has a JDBC 4.0 type 4 driver.

XML Configuration File Path

RBT configuration is defined in an xml configuration file. RBT configuration file location must be specified with a context parameter entry in the web.xml as shown below:


            <context-param>
                <param-name>rbt.configuration.file.path</param-name>
                <param-value>[your config file directory]/[your config file name].xml</param-value>
            </context-param>

            <context-param>
                <param-name>rbt.configuration.file.path</param-name>
                <param-value>c:/rbt/configuration/rbt.config.xml</param-value>
            </context-param>
                        

XML Configuration File Example

All configurable RBT application parameters are found in the RBT configuration xml file defined by schema:

RBT configuration schema

The individual elements in the configuration file are described in the following sections. An example configuration file is shown below:

        <?xml version="1.0" encoding="UTF-8"?>
        <RbtConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema"
            xmlns="http://xml.rbt.rbtdata.org/schemas">
        <!-- the implementation of the SecurityInterface that provides authentication and
            access control for RBT applications. If you create your own implementation of
            SecurityInterface put the class name here -->
            <securityInterfaceClass>org.rbtdata.rbt.security.JdbcSecurity</securityInterfaceClass>

        <!-- specifies how deep the RBT application will recursively follow the
            parent/child table relationships when building the relationship tree-->
            <maxRecursionDepth>5</maxRecursionDepth>

        <!-- default font size which will act as base size for all fonts -->
            <defaultFontSize>10pt</defaultFontSize>

        <!-- default font to use if no font specuified -->
            <defaultFontName>Times New Roman</defaultFontName>

        <!-- default font family to use if no font/font family specified-->
            <defaultFontFamily>Arial,Helvetica,sans-serif</defaultFontFamily>

        <!-- default time format for query results if no time mask specified-->
            <defaultTimeFormat>HH:mm</defaultTimeFormat>

        <!-- default date format for query results if no date mask specified-->
            <defaultDateFormat>yyyy-MM-dd</defaultDateFormat>

        <!-- default timestamp format for query results if no timestamp mask specified-->
            <defaultTimestampFormat>yyyy-MM-dd HH:mm:ss</defaultTimestampFormat>

        <!-- default floating point  format for query results if no number mask specified-->
            <defaultFloatFormat>######.00</defaultFloatFormat>

        <!-- default page size when creating a new document -->
            <defaultPageSize>8.5inX11in</defaultPageSize>

        <!-- default page orientation when creating a new document -->
            <defaultPageOrientation>portrait</defaultPageOrientation>

        <!-- default page margins when creating a new document -->
            <defaultPageMargins>0.5,0.5,0.5,0.5</defaultPageMargins>

        <!-- default page measurement unit when creating a new document -->
            <defaultMeasurementUnit>inches</defaultMeasurementUnit>

        <!-- image location for images used in the designer. This can be URL or a directory path. All users can
            see the images in the root. Under the root, folders can be created with group names and the images
            placed in these folders will only be avaialble to members of the specific group -->
            <imageRootDirectory>http://localhost:8088/imgserver/rbtimages</imageRootDirectory>

        <!-- the following rss parameters will be used for the rss xml output channel entries.
        -->
            <rssTitle>RBT Document Channel</rssTitle>
            <rssDescription>RBT RSS Source for Document Output</rssDescription>
            <rssUrl>http://www.rbtdata.org/rss</rssUrl>


        <!-- JDBC datasources which are accessible to the RBT applications. There can be only one security
            datasource and that will contain the RBT security tables. The security database tables should be
            created with the appropriate db script found in the dbscripts folder-->
            <datasources>
        <!-- security datasource for RBT security tables -->
                <security>
        <!-- JDBC JNDI name for the datasource -->
                    <jndiName>jdbc/MySQLRbtDB</jndiName>
        <!-- User-friendly datasource name for display in administrator and designer -->
                    <displayName>My SQL</displayName>
        <!-- default schema for database connection -->
                    <schema>rbt</schema>
        <!-- table type accessible to RBT applications, there can be 1 or more of these.
            These names are the same used in the java.sql.DatabaseMetaData.getTables() method -->
                    <tableTypes>
                        <tableTypeName>TABLE</tableTypeName>
                        <tableTypeName>VIEW</tableTypeName>
                    </tableTypes>
        <!-- set to true to use the catalog name in the fully qualified table name for
            databases where the catalog is provided such as SQL Server 2005 -->
                    <useCatalog>false</useCatalog>
        <!-- database management system name for display purposes - not currently used -->
                    <dbms>MySQL</dbms>

        <!-- character to use when quoting database identifiers -->
                    <quotedFieldChar>`</quotedFieldChar>

        <!-- concatenation operator to use if DBMS does not support SQL concat function -->
                    <dbmsConcatOperator></dbmsConcatOperator>


        <!-- by default, when the RBT administrator load up to provide setting table access permissions for
            a user or a group, all tables and columns for each datasource are loaded - this can be expensive
            and time consuming. If you want to limit the accessible table names for a datasource, put the
            table names here. If this elements contains table, then only the table information for the
            specified tables will be loaded -->
                    <tables></tables>
                 </security>

        <!-- this definition of the datasources elements are the same as the security
            datasource above. there can be one or more data datasources accessible to
            RBT applications.  -->
                <data>
                    <jndiName>jdbc/MySQLDB</jndiName>
                    <displayName>Sakila</displayName>
                    <schema>sakila</schema>
                    <useCatalog>false</useCatalog>
                    <dbms>MySQL</dbms>
                    <quotedFieldChar>`</quotedFieldChar>
                    <tableTypes>
                        <tableTypeName>TABLE</tableTypeName>
                        <tableTypeName>VIEW</tableTypeName>
                        <tableTypeName>SYS</tableTypeName>
                    </tableTypes>
                    <tables></tables>
                 </data>
                <data>
                    <jndiName>jdbc/sqlserver</jndiName>
                    <displayName>DBO</displayName>
                    <schema>dbo</schema>
                    <useCatalog>true</useCatalog>
                    <dbms>SQLServer 2005</dbms>
                    <quotedFieldChar>"</quotedFieldChar>
                    <tableTypes>
                        <tableTypeName>TABLE</tableTypeName>
                        <tableTypeName>VIEW</tableTypeName>
                        <tableTypeName>SYS</tableTypeName>
                    </tableTypes>
                    <tables></tables>
                 </data>
                <data>
                    <jndiName>jdbc/oraclexehr</jndiName>
                    <displayName>Human Resources</displayName>
                    <schema>HR</schema>
                    <useCatalog>false</useCatalog>
                    <dbms>OracleXE</dbms>
                    <quotedFieldChar>"</quotedFieldChar>
                    <tableTypes>
                        <tableTypeName>TABLE</tableTypeName>
                        <tableTypeName>VIEW</tableTypeName>
                        <tableTypeName>SYS</tableTypeName>
                    </tableTypes>
                    <tables></tables>
                 </data>
            </datasources>
        <!-- RBT has 2 configurable NUR (not used recently) caches to improve performance. The
            dbObjectCache contains the security objects used by the database administrator
            for security setup. The formatCache contains user-specified date, time, timestamp
            and float format objects found in the document designs. -->

            <dbObjectCache>
                <!-- enable or disable object caching -->
                <enabled>true</enabled>
                <!-- max size of cache -->
                <maxSize>10</maxSize>
                <!-- interval in milliseconds that the cache will be checked for expired objects -->
                <checkInterval>100000</checkInterval>
                <!-- interval in milliseconds that the recently used set will be cleared -->
                <clearInterval>200000</clearInterval>
                <!-- default time in milliseconds that a cache object can stay in cache -->
                <timeToLive>300000</timeToLive>
            </dbObjectCache>
            <formatCache>
                <!-- enable or disable object caching -->
                <enabled>true</enabled>
                <!-- max size of cache -->
                <maxSize>20</maxSize>
                <!-- interval in milliseconds that the cache will be checked for expired objects -->
                <checkInterval>200000</checkInterval>
                <!-- interval in milliseconds that the recently used set will be cleared -->
                <clearInterval>300000</clearInterval>
                <!-- default time in milliseconds that a cache object can stay in cache -->
                <timeToLive>400000</timeToLive>
            </formatCache>

            <datasetCache>
                <!-- enable or disable object caching -->
                <enabled>true</enabled>
                <!-- max size of cache -->
                <maxSize>30</maxSize>
                <!-- interval in milliseconds that the cache will be checked for expired objects -->
                <checkInterval>300000</checkInterval>
                <!-- interval in milliseconds that the recently used set will be cleared -->
                <clearInterval>400000</clearInterval>
                <!-- default time in milliseconds that a cache object can stay in cache -->
                <timeToLive>500000</timeToLive>
            </datasetCache>

        <!-- By default the RBT designer provides a generic set of basic fonts and font families for
            document design - if you want to add more put the names here -->
            <additionalFonts>
                <fontName>Tahoma</fontName>
                <fontName>Sylfaen</fontName>
                <fontName>Calibri</fontName>
                <fontName>Century</fontName>
                <fontName>Engravers MT</fontName>
            </additionalFonts>
        </RbtConfiguration>
                        

XML Element Descriptions

RbtConfiguration
NameRequiredMultipleDefaultDescription
securityInterfaceClassyesnoorg.rbtdata.rbt.security.JdbcSecurityThe java class that implements the RBT SecurityInterface class. To implement custom security place your class here.
maxRecursionDepthyesno5set limit on how deep to follow parent-child table relationships
defaultFontSizeyesno10ptThe base font for the document design in RBT. All font size selections in the designer will be based on a percentage of this size
defaultFontNameyesnoTimes New RomanThe default font to use for display objects in document designer when no font is specified
defaultFontFamilyyesnoArial,Helvetica,sans-serifThe font family CSS style that will be set for the body element of the document HTML page
defaultTimeFormatyesnoHH:mmdefault java format string to apply to query result time columns
defaultDateFormatyesnoyyyy-MM-dddefault java format string to apply to query result date columns
defaultTimestampFormatyesnoyyyy-MM-dd HH:mm:ssdefault java format string to apply to query result timestamp columns
defaultFloatFormatyesno######.00default java format string to apply to query result floating point number columns
defaultPageSizeyesno8.5inX11indefault page size setting when creating a new document
defaultPageOrientationyesnoportraitdefault page orientation setting when creating a new document
defaultPageMarginsyesno0.5,0.5,0.5,0.5comma delimited list of default page margins (in default measurement units) when creating a new document. Format is left,top,right,bottom
defaultMeasurementUnityesnoinchesdefault measurement units for document design display pane - rulers, margins etc. (inches or centimeters)
imageRootDirectoryyesnononeSpecifies image root directory for document images resources - can be relative or fully qualified URL. The imageRootDirectory is used as the parent directory of available images and is included as the image parent in an HTML image tag for images added to document templates in the designer. A fully qualified URL allows you to specify any valid web server that is configured to serve images. When you use a fully qualified URL, the web server must be configured to allow directory listings on the specified directory. Relative paths are also supported. The relative path must exist under the [webserver_location]/webapps/rbt directory on the server. When using a relative path, web server directory listing access is not an issue.
datasourcesyesno contains the datasource configurations for the RBT application datasources - described below
dbObjectCacheyesno contains cache parameter settings for the database object cache - described below
formatCacheyesno contains the cache parameter settings for the time, date, timestamp and float display formats - described below
datasetCacheyesno contains the cache parameter settings for the document dataset cache - described below
additionalFontsyesno The document designer has a limited set of font/font family default selections available. If you would like additional font selections, add <fontName> elements as shown in the example below
           <additionalFonts>
                <fontName>Tahoma</fontName>
                <fontName>Sylfaen</fontName>
                <fontName>Calibri</fontName>
                <fontName>Century</fontName>
                <fontName>Engravers MT</fontName>
            </additionalFonts>
        

Datasource Description

There are 2 types of datasource specifications - <security> and <data>. There can be only one <security> datasource specified and this is the database containing the RBT security tables. There can be multiple <data> datasources specified and these define the available databases accessible to users for document design. Element definitions for both <security> and <data> are the same and are described below:

security/data Datasource
NameRequiredMultipleDefaultDescription
jndiNameyesno JDBC datasource JNDI name
displayNameyesno User-friendly datasource display name for display in the administrator and designer
schemayesno Default schema (user in oracle) for this datasource JDBC connection
tableTypesyesyesVIEW and TABLEChild element <tableTypeName> are database table types to load for designer access - used in JDBC DatabaseMetaData.getTables() method.
useCatalogyesnofalseSet to true to use database catalog name (when it exists) as part of fully qualified table name in SQL queries
dbmsnono DBMS display name
quotedFieldCharnono"Character to use when quoting identifiers in SQL statement
dbmsConcatOperatornono By default, some DB concatenation operations in RBT use the SQL concat function which is not supported on all systems. If your datasource DBMS does not support the SQL concat function, specify the DBMS-specific concatenation operator here
tablesyesno By default the administrator loads meta data for all tables in the datasource with the types specified in the tableTypes element - this can be quite expensive. If you want to limit which meta data is loaded (and tables made available) specify the <tableName> elements as shown in the example below.
        <tables>
            <tableName>table1</tableName>
            <tableName>table2</tableName>
            <tableName>table3</tableName>
            ...
        &ly;tables>
    
foreignKeyDisplayNamesnono  If you want to provide a brief description of a table relationship displayed in the column select tree, you can add entries as shown in the example below. The display name entered will be show next to the associated table name in the column select tree.
        <foreignKeyDisplaNames>
            <foreignKeyName>
                <name>dbms_foreign_key_name1</name>
                <displayName>fk1 display name</displayName>
            </foreignKeyName>
            <foreignKeyName>
                <name>dbms_foreign_key_name1</name>
                <displayName>fk2 display name</displayName>
             </foreignKeyName>
         ...
         </foreignKeyDisplayNames>
    

Cache Description

The RBT application maintains 3 caches to improve performance and reduce database overhead:
  • dbObjectCache - contains administrator database meta data information - tables, columns etc. and the RBT data associated with these objects.
  • formatCache - contains document design display format settings for date, time, timestamp and float data types.
  • datasetCache - contains document dataset results from document execution.
Each cache described above is an implementation of an NUR (not used recently) cache and share a common set of initialization parameters that can be modified if required. These elements are described in the table below:

NameRequiredMultipleDefaultDescription
enabledyesnotrueset to false to disable caching of objects
maxSizeyesno100maximum number of objects that the cache will hold
checkIntervalyesno600000time in milliseconds between cache checks for expired objects
clearIntervalyesno18000000time in milliseconds before clearing the recently used objects set
timeToLiveyesno900000default time in milliseconds that an object will be allowed to stay in the cache

Logging Configuration

RBT uses log4j for logging and the log4j.properties file is located in the WEB-INF/classes directory of the rbt-1.3.1.war file. It is expected that the installer has J2EE and log4j knowledge to configure the logging properties as desired.

Accessing RBT

Once the rbt war file is deployed to the web container the RBT applications can be accessed at the following URLs:

  • administrator - http://[your_server_name]/rbt/admin.html
  • designer - http://[your_server_name]/rbt/designer.html
  • runner - http://[your_server_name]/rbt/

The initial administrator username and password are: admin/admin.