Show Table of Contents
Chapter 2. Resource Adapter Development
2.1. Developing Custom Adapters
For situations in which an existing JCA Adapter (or other connector mechanism) is not suitable, Red Hat JBoss Data Virtualization provides a framework for developing custom JCA Adapters.
Red Hat JBoss Data Virtualization uses standard JCA Adapters. Base classes for all of the required supporting JCA SPI (Service Provider Interface) classes are provided by the Red Hat JBoss Data Virtualization API. The JCA CCI (Common Client Interface) support is not provided because Red Hat JBoss Data Virtualization uses the translator API as its common client interface.
Note
If you are not familiar with the JCA API, read the JCA 1.5 Specification at http://docs.oracle.com/cd/E15523_01/integration.1111/e10231/intro.htm.
The process for developing a Red Hat JBoss Data Virtualization JCA Adapter is as follows (the required classes can be found in org.teiid.resource.spi):
- Define a Managed Connection Factory by extending the
BasicManagedConnectionFactoryclass - Define a Connection Factory by extending the
BasicConnectionFactoryclass - Define a Connection by extending the
BasicConnectionclass - Specify configuration properties in an
ra.xmlfile
Note
The examples contained in this book are simplified and do not include support for transactions or security which would add significant complexity.
For sample resource adapter code, see the
teiid/connectors directory of the Red Hat JBoss Data Virtualization 6.4 Source Code ZIP file. This ZIP file can be downloaded from the Red Hat Customer Portal at https://access.redhat.com.

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.