#  this resource adapter is for connecting to a remote Infinispan cache using the Hot Rod Client. remote query dsl feature that uses Google protobuf's for serialization.
#
#  the properties are pre-filled based on using the JDG remote-query quickstart, and as an example of what the content should look like
#
#  for the complete details on the format for each property, see the ra.xml file for the resource adapter: connector-translator-dsl 
#
#  Note:  The RemoteServerList host:port may have to be changed, depending on your JDG deployment.  Also, the port is based on running it locally and incrementing the ports

                <resource-adapter id="infinispanRemRADSL">
                    <module slot="main" id="org.jboss.teiid.resource-adapter.infinispan.hotrod"/>
                    <connection-definitions>
                        <connection-definition class-name="org.teiid.resource.adapter.infinispan.hotrod.InfinispanManagedConnectionFactory" jndi-name="java:/infinispanRemoteMat" enabled="true" use-java-context="true" pool-name="infinispanRemoteMat">
                            <!-- cacheName:className[;pkFieldName[:cacheKeyJavaType]]) -->
                            <config-property name="CacheTypeMap">
                                addressbook_indexed:com.client.quickstart.addressbook.remotecache.pojos.domain.Person;id
                            </config-property>
                            <!-- protobuf definition file that defines the schema and, possibly, indexes -->
                            <config-property name="ProtobufDefinitionFile">
                                 /quickstart/addressbook.proto
                            </config-property>
                            <!-- the protobuf definition root message descriptor that corresponds the root class defined in CasheTypeMap -->
                            <config-property name="MessageDescriptor">
                                quickstart.Person
                            </config-property>
                             <!-- module name to load the cache classes from -->
                            <config-property name="Module">
                                com.client.quickstart.addressbook.remotecache.pojos
                            </config-property>
                            <config-property name="MessageMarshallers">
                                com.client.quickstart.addressbook.remotecache.pojos.domain.Person:com.client.quickstart.addressbook.remotecache.pojos.marshallers.PersonMarshaller
                            </config-property>
                            <!-- comma seperated list of hostname:port  -->
                            <config-property name="RemoteServerList">
                                127.0.0.1:11322
                            </config-property>
                            <config-property name="StagingCacheName">
                                addressbook_indexed_mat
                            </config-property>                            
                            <config-property name="AliasCacheName">
                                aliasCache
                            </config-property>                            
                        </connection-definition>
                    </connection-definitions>
                </resource-adapter>