Service Styles
Overview
The caGrid Data Services Infrastructure supports varying and pluggable service styles. Service styles are intended to allow service developers to repeatedly create data services which require a specific set of functionality to be added or have a well defined configuration and setup process. Styles can add logical functionality to the data service creation and modification processes by implementing specific interfaces which are invoked by the data services extension as it runs. Styles may also add graphical functionality to the service development process by adding a set of wizard panels to the creation process, and optionally including a tab in the service modification UI to further manage configuration of the style. Examples of data service styles include the caCORE SDK backend data source support features. The pluggable nature of service styles allows the main data services infrastructure to remain decoupled from the implementation details of caGrid-provided (or third party) query processors, and ensures that future development and support for new data sources will not always necessitate changes to the core codebase.
Service Styles Architecture
![]() |
| Styles Directory Layout |
Data service styles may be added to the data service extension to provide additional functionality to the service creation and configuration processes, and are selected by the service developer when a service is first created. Styles may be installed at any time after the primary caGrid Data Services extension has been installed by adding to the styles directory found in the installed data service extension directory. Each style must provide its own directory in which files it uses will be placed, but no restriction is made on the naming of these directories. At the top level of each style directory, a style.xmlfile must exist, describing the style. This document describes the style's name, which caGrid and Data Service versions it is compatible with, and information on which classes are to be loaded for each component of the style. If the service developer selects no style at service creation time, the service is created with only the standard data services components and query method, and ready to have a domain model, query processor, and other data service requirements selected and configured.
Functionality Extended by Styles
Data Service styles may add functionality to any or all of the following areas of service development with the Introduce toolkit:
- Creation Wizard
- The service style may supply a list of wizard panels to be displayed and chained together in a wizard-like fashion to break the setup process for the service style into a series of steps. These panels will be shown in a wizard dialog when a service style is selected at service creation time.
- Post-creation processing
- Just as Introduce extensions may add functionality to the service creation process, data service styles may add processing capabilities to this step.
- Modification User Interface
- The style may supply a graphical panel which will be added to the data service tab in the Introduce service modification viewer. This tab can be used to configure any style-specific options in the service.
- Post-code generation processing
- The style may add functionality to the code generation process of service modification. This processing will be invoked each time the service is modified and saved in Introduce.
Creating a Data Service Style
Creating a data service style is a straightforward process, similar to writing an extension to the Introduce toolkit. Details on this process can be found on the How-To page for style creation.






