The Northwind adapter definition comes preconfigured with all types of element and alarm definition. It utilizes the Northwind database to show how to expose database information.
In this example, when the Northwind adapter definition is deployed, it builds an adapter that has a hierarchy for both customers and product inventories.
Figure A-1 illustrates the customer hierarchy building out elements for invoices and groups by Shipment Type for each customer:
Figure A-1 Explorer Pane by Shipment Type
Figure A-2 illustrates the product inventory hierarchy building out elements for products and groups them by Product Type:
Figure A-2 Explorer Pane by Product Type
The remainder of this section provides a high-level overview of specific examples from the demo adapter definition that created these various types of elements (in the deployed adapter) and their associated alarms.
When an adapter definition is created, basic information and settings are defined for the adapter to use when deployed.
In Figure A-3, the run-time adapter leverages the Product Name, Vendor, Version, and Copyright Notice in the adapter properties:
Figure A-3 Definition Editor
To examine the adapter settings example:
In the Definition Editor, select the root element in the
pane (in this instance, it is the element).Click the following icons to see how the adapter icon, default properties, scripts, and databases are set:
Adapter: Defines basic descriptive information for the adapter, including copyright information.
Icon: Allows assigning an icon for the root adapter element in the run-time adapter.
Properties: Defines defaults and permissions for alarm columns, hierarchy file, stylesheet file, and maximum number of alarms for the adapter.
Scripts: Defines defaults and permissions for any scripts to be run with adapter activity.
Database: Defines database information and permissions for the database connection used by the run-time adapter.
Element Group is a hard-coded folder (not dynamically created) that might hold children and alarms in the deployed adapter.
In Figure A-4, the run-time adapter uses the Group definition to create a single Operations Center element (or folder) named :
Figure A-4 Definition Editor Group Definition Tab
In the Northwind demo, there are several examples of Element Groups, which include Customers, Invoices (by ID), and Product Inventory.
To examine an element group example:
In the Definition Editor, click to open and browse the hierarchy in the
pane.Select the
folder.This is an element group definition.
Click the
and icons to see how group elements (folders) are created and assigned icons in the demonstration definition.The
pane defines basic information about the definition. In this case, the name specified for this element is used for this element in the deployed adapter.The
pane allows assigning an icon that is used for this parent element (folder) in the deployed adapter.In Figure A-5, the run-time adapter uses the Database Element definition to create Operations Center elements for all unique customer names found in the Customers table:
Figure A-5 Definition Editor: Database elements are displayed in the Definition Navigator pane.
The Northwind demo has several examples of database elements, including
, , and .To examine a database elements example:
In the Definition Editor, click to open and browse the hierarchy tree in the
pane.Select the
element.This is a database element definition. With the deployed adapter, it instructs the creation of an element under the
folder for each unique value found in the column of the Customers table.Click the following icons to see how database elements are defined in the demonstration definition:
Element: Defines basic information about the database element definition. In this case, the name and description are only used within the adapter definition and the Definition Editor.
Icon: Assigns an icon for these elements in the deployed adapter.
Query: Defines the query that pulls database information to create these elements. It is also used to define various properties for the elements.
Schedule: Sets up a schedule for polling the database for new information with the query specified in the
tab.Pages: Defines one or more property pages for the element using the properties available in the
tab.A generated element is created in the adapter definition when you want to create parent elements directly from a table column in the database.
It is important, however, that the associated Property Name value exactly matches a property created from a query of a child DB Element or Alarm Definition.
In Figure A-6, the run-time adapter uses the generator definition to create a Operations Center element for all values found in the table column that identifies the shipping method used to send the order:
Figure A-6 Definition Editor: Operations Center elements can be generated from database table columns.
In the Northwind demo, two examples of generated elements are
, and .To examine an element group example:
In the Definition Editor, click to open and browse the hierarchy in the
pane.Select the
folder.This is a generator definition.
Click the
and icons to see how generators are created and icons are assigned in the demonstration definition.The
pane defines basic information about the generator definition. The and values are used only by the adapter definition and the Definition Editor. The value must directly match a property created from a query of a child or definition.The
pane is used to assign an icon to the elements created by the by the deployed adapter at run-time.Figure A-7 illustrates that alarm definitions can be created in the adapter definition when you want to have alarms generated for an element from database information:
Figure A-7 Definition Editor with Alarm Definitions
In the Northwind demo, one example of an alarm definition is
.To examine a database elements example:
In the Definition Editor, click to open and browse the hierarchy in the
pane.Select the
folder.This is an alarm definition. With the deployed adapter at run-time, it instructs the creation of alarms for the elements created by
.Click the following icons to see how database elements are defined in the demonstration definition:
Alarm: Defines basic information about the Alarm definition. In this case, the name and description are only used within the adapter definition and Definition Editor.
Icon: Allows assigning an icon for these alarms in the deployed adapter.
Query: Defines the query that pulls database information to create alarms for the corresponding element. It is also used to define various properties for the alarms.
Schedule: Sets up a schedule that is used to poll the database for new information using the query specified in the
tab.Pages: Defines one or more property pages for the alarm using those properties available from the
tab.