While it is certainly doable, why would you want to do that ? Also beware that, unless you're "slotting" your modules appropriately you're mixing different modules (the 7.1's from WildFly itself and your 7.2).
I dont want to run an application server and a explicit cache server. seems like quite an overhead.
why wouldnt i want to run the cache on the same server?
for our use case we need a distributed cache.
thanks for your quick response! Unfortunately i can only write once very hour?!
Using the Wildfly modules might not a good idea as this module might be outdated and did not have the full functionality, as it is only to support some caches for internal use.
The simple way to run the cache inside the application is the library mode, add the infinispan bits as a module and set dependencies from the app.
A reason for C/S mode and a separate server is to separate the cache from the application, i.e. memory use. Also you can stop/start servers and applications without any effect for the cache.