Awesome diagrams. For the sake of making the topology clearer/more obvious I suggest to use at least 2 Application (AS/EAP) nodes. Moreover, sometimes its clearer to picture nodes as JVM so that its clear what is running where.
Just in terms of AS and Infinispan, lets separate the use case into:
- remote access - this is 3) and actually 2), from your application node you access the Infinispan cluster using hotrod/memcached/rest/etc
- embedded access - this is only possible if the cache is running in the same JVM as the AS with the application. You can do this with AS by connecting multuple instances in a cluster, running the application only on the few of them, but have a custom cache running on all the nodes. With a process callled 'trimming' you can trim down the AS instances only to run core subsystems and jgroups + infinispan subsystems.
However, if you are actually talking about enterprise EAP and JDG (not JBDG) offering please ask at the enterprise customer portal for what exactly is supported and how (e.g. JDG and EAP run different versions of Infinispan).
If by any chance, you meant running standalone community Infinispan cluster (in a datagrid fashion) and JBoss AS, I would actually recommend going the trimming approach since its easier to manage the same software just with different configuration.
That was a great suggestion on my diagrams. Let me look into the trimming option.
By the way I sucessfully used remote cache store with in-memory infinispan, I have pasted the configuration below which may help any other JBoss folks.
<loader class="org.infinispan.loaders.remote.RemoteCacheStore" fetchPersistentState="true"
<property name="hotRodClientPropertiesFile" value="hotrod-client.properties"/>
<property name="useDefaultRemoteCache" value="true"/>