LVconf Type: Data Table

Overview

Use the LiveView Configuration File Editor to configure the Data Table lvconf file type.

Specify the table's schema, either by reference to a named schema or by editing the schema grid directly.

Designate one or more primary keys, either by selecting an available field and clicking the arrow button, by dragging and dropping from left to right, or by double-clicking an available field's name.

Schema Tab

Specify a schema by importing a named schema, and/or adding fields directly to the table below

Schema Field

Property Type Description
Interface/Application drop‑down list, chooser Path to the sbapp or sbint file from which to import the schema. The path is relative to the project root (where the top-level lvconf must reside). If you specify a simple file name, LiveView searches for the file on the current project's module search path.
Schema drop‑down list The name of the schema within the specified sbapp or sbint file.

To define your own schema:

  • Click the Plus sign to add fields.

  • Select a field type from the drop-down list.

  • Enter an optional description.

Options Field

Define your data table options:

Property Type Description
Snapshot Concurrency int Defines the maximum number of snapshot queries (one per thread) within a partition that are executed at once.
Snapshot Parallelism int Defines the number of table partitions and the number of parallel regions used to scan a table during the snapshot portion of a query.
Publish Interval (ms) int This setting applies to all table types, and is used to specify in milliseconds the amount of delay before publishing data from the table; this condition is known as conflation of data. Set this attribute to a positive, non-zero integer ≥ 5 to specify conflation for this table. A value below 5, including zero and all negative numbers, is forced equal to 5. Static aggregation tables have an internal setting that is the equivalent of setting publish-interval-millis=1000 (1 second). For such tables, you cannot disable conflation, but you can change the conflation interval by setting publish-interval-millis to a different integer value. For all other table types, specify a value for publish-interval-millis to both enable conflation and to specify the conflation interval. To disable conflation for non-aggregation tables, remove the publish-interval-millis attribute entirely from your table’s lvconf entry.

Without conflation, data is published from a table as soon as it is received. With conflation enabled, all downstream components see conflated data, including alerts, LiveView Desktop, clients built with the Java or .NET APIs, or another table in a transformation sequence. If an alert is set for a conflated table, be aware that it is possible for conditions that would otherwise trigger an alert to occur briefly during a conflation period; in this case, the trigger conditions are conflated away and the alert does not trigger. See the Data Conflation topic in the LiveView Reference Guide for further information.

Table Space Reference drop‑down list A reference to a defined table-space.
Row Delete Rule string An optional rule specifying a predicate that is evaluated against the data in any incoming insert or update. If the incoming data satisfies the predicate and a row with a matching primary key exists, then no update occurs and the row is deleted. If the incoming data satisfies the predicate and no row with a matching primary key exists, then no insert occurs. If the incoming data does not satisfy the predicate, then an insert or update occurs as normal.
Group string Optional logical grouping for a table.

Description Field

Enter a short or long description (string) for the data table type.

Indexes Tab

Select an primary key from the Available Fields list and either double-click it or click arrow to move it to the Index Fields box.

Optionally, select a secondary index or click Add to create one.

Data Sources Tab

Choose up to three data sources in any combination. For most applications, only one data source type is required.

Aggregation Field

Property Type Description
Table Reference drop‑down list A reference to a table from which aggregated data is received.
Projection string The projection expression that is used to populate the fields of this aggregate table. that is, max(price) as MaxPrice, avg(price) as AvgPrice.
Predicate string The predicate used to filter rows from the base table. That is, area=='US' AND price>100 when transactionTime between now()-minutes(1) and now().

Application Field

Property Type Description
Application Reference drop‑down list Reference to a defined application.
Output Stream string A valid output stream of the application to receive data from. Application streams that are intended to send data to LiveView or receive data from LiveView must be marked public; that is, the stream property "Always expose Stream for Dequeue" or "Always expose Stream for Enqueue" must be set.
Disable validation typecheck check box There are certain unusual situations where a start-up artifact from a preprocessing app is not available early in LiveView server start-up. In these rare cases, in order to allow LiveView to run, you can skip typechecking of the referenced preprocessing app by setting this attribute to false. The downside is that you will no longer receive compile-time typecheck warnings, and may get runtime exceptions if your configuration is wrong. If typechecking is enabled, the system attempts to coerce fields to be the correct type, such as converting an integer to a long, or filling in empty fields with null.

Transform Field

Property Type Description
Application drop‑down list, chooser Used by the StreamBase interface generator to identify the transform.
Table Reference drop‑down list A reference to the source table.
Parameters set by this configuration selector Parameters for the StreamBase application. Select one from the available list.
Available Module Parameters string Select the application parameters to be set by this configuration. The Available module parameters table shows all parameters defined in the currently selected application. Default values are shown in brackets, when defined.
Disable validation typecheck check box There are certain unusual situations where a start-up artifact from a preprocessing app is not available early in LiveView server start-up. In these rare cases, in order to allow LiveView to run, you can skip typechecking of the referenced preprocessing app by setting this attribute to false. The downside is that you will no longer receive compile-time typecheck warnings, and may get runtime exceptions if your configuration is wrong. If typechecking is enabled, the system attempts to coerce fields to be the correct type, such as converting an integer to a long, or filling in empty fields with null.
Allow Cycle check box Optional. Under normal circumstances, cycles in the configuration graph are not allowed. Under certain advanced cases it might be necessary to have a cycle in the graph. A simple example would be table A publishing to table B and table B publishing back to table A. If a scenario like this is required, a custom transform should be introduced and the “allow-cycle” attribute should be set to true. This setting should be made with great care.
Use Snapshot Parallelism check box Optional. When a table is configured with snapshot-parallelism, setting this attribute to true pushes the processing of this transform into the same parallel region as snapshot processing. In general, performance should be better by running inside the parallel region.

Preprocessor Tab

None = default. If you select Use preprocessor application, configure the following as needed.

Preprocessor Field

Property Type Description
Application drop‑down list, chooser Filename of the StreamBase application. This file is located using the project's module search path.
Disable validation typecheck check box There are certain unusual situations where a start-up artifact from a preprocessing app is not available early in LiveView server start-up. In these rare cases, in order to allow LiveView to run, you can skip typechecking of the referenced preprocessing app by setting this attribute to false. The downside is that you will no longer receive compile-time typecheck warnings, and may get runtime exceptions if your configuration is wrong.
Parameters set by this configuration click Add Name-value pair property definitions.
Available Module Parameters N/A This table shows all parameters defined in the currently selected application. Default values are shown in brackets, when defined.

To set a parameter value (or override its default), select a parameter and click the Add button or double click a parameter, then enter the desired value.

Tables this preprocessor depends on click Add Since StreamBase applications can have container connections defined within them, it is possible to have a container connection from this application to another LiveView table. Explicitly stating these dependencies here allows LiveView to know about them such that LiveView will load tables in the proper order on startup.

Optionally:

  • Add all available module parameters without defaults

  • Add all available module parameters

  • Add a parameter not yet defined by the application

Aliases Tab

Property Type Description
Table Aliases string This can be simply the name of the aliased table, or a formatter string as would be passed to the java.lang.String.format method, where %s is to be replaced with the name of the base table.
Filter string Part of a predicate that is to be appended (using AND or its equivalent in the query language of the table being used) to all queries coming to the aliased table. This predicate should be in the query language of the base table.

Field Rules Tab

Field Rules: Click the Plus sign to add a new table-level rule.

Field Rule Details: Add a description for the rule.

Variables: Click the Plus sign to define a variable for the rules. Typed variables can be defined that will be used in the table-level rules. Use these to save intermediate calculations which otherwise would have to be re-calculated.

Source Tab

The Source tab provides a text-based XML configuration file editor, which is a validating XML editor that is aware of the schema that defines the XML syntax of LiveView configuration files. See Text-Based XML Configuration File Editor for more information.