mercredi 28 juin 2017

Testing jCache with Hazelcast Provider

How can I achieve unit tests for caching using jCache and HazelcastProvider?

Currently I'm getting this error:

Caused by: java.lang.IllegalStateException: Unable to connect to any address in the config! The following addresses were tried: [localhost/127.0.0.1:5701, localhost/127.0.0.1:5702, localhost/127.0.0.1:5703]

Simplified code below:

@RunWith(SpringJUnit4ClassRunner.class)
@TestPropertySource("classpath:provider.properties")
@ContextConfiguration(classes = {
    CustomCacheConfiguration.class
})

I have cache declared in hazelcast.xml file along with multicast, so as I understand it correctly, I should have an embedded instance.

Aucun commentaire:

Enregistrer un commentaire