Class HotRodTestClientDriver

java.lang.Object
org.infinispan.server.test.api.HotRodTestClientDriver
All Implemented Interfaces:
org.infinispan.commons.configuration.Self<HotRodTestClientDriver>

public class HotRodTestClientDriver extends Object
REST operations for the testing framework
Since:
10
Author:
Tristan Tarrant
  • Field Details

    • serverConfiguration

      protected org.infinispan.commons.configuration.BasicConfiguration serverConfiguration
    • flags

      protected EnumSet<org.infinispan.commons.api.CacheContainerAdmin.AdminFlag> flags
    • mode

      protected String mode
    • qualifier

      protected String qualifier
  • Constructor Details

    • HotRodTestClientDriver

      public HotRodTestClientDriver(TestServer testServer, TestClient testClient)
  • Method Details

    • withClientConfiguration

      public HotRodTestClientDriver withClientConfiguration(org.infinispan.client.hotrod.configuration.ConfigurationBuilder clientConfiguration)
      Provide a custom client configuration to connect to the server.
      Parameters:
      clientConfiguration -
      Returns:
      the current HotRodTestClientDriver instance with the client configuration override
    • withClientConfiguration

      public HotRodTestClientDriver withClientConfiguration(org.infinispan.client.hotrod.configuration.ClientIntelligence clientIntelligence)
      Provide the Client Intelligence override
      Parameters:
      clientIntelligence -
      Returns:
      the current HotRodTestClientDriver instance with the client intelligence override
    • withMarshaller

      public HotRodTestClientDriver withMarshaller(Class<? extends org.infinispan.commons.marshall.Marshaller> marshallerClass)
      The Marshaller to be used by the client.
      Parameters:
      marshallerClass -
      Returns:
      the current HotRodTestClientDriver instance with the Marshaller configuration override
    • withPort

      public HotRodTestClientDriver withPort(int port)
    • get

      public <K, V> org.infinispan.client.hotrod.RemoteCache<K,V> get()
      Gets a cache with the name of the method where this method is being called from
      Returns:
      RemoteCache, the cache is such exist
    • create

      public <K, V> org.infinispan.client.hotrod.RemoteCache<K,V> create()
      Created a cache with the name of the method where this method is being called from. If the cache already exists, retrieves the existing cache
      Returns:
      RemoteCache, the cache
    • create

      public <K, V> org.infinispan.client.hotrod.RemoteCache<K,V> create(int index)
      Create a cache adding in the initial server list the server address given by the index
      Parameters:
      index - the server index, -1 for all
      Returns:
      RemoteCache, the cache
    • createRemoteCacheManager

      public org.infinispan.client.hotrod.RemoteCacheManager createRemoteCacheManager()
    • createRemoteCacheManager

      public org.infinispan.client.hotrod.RemoteCacheManager createRemoteCacheManager(int index)
    • self

      public HotRodTestClientDriver self()
    • withServerConfiguration

      public HotRodTestClientDriver withServerConfiguration(org.infinispan.commons.configuration.BasicConfiguration serverConfiguration)
    • withServerConfiguration

      public HotRodTestClientDriver withServerConfiguration(org.infinispan.commons.configuration.StringConfiguration configuration)
    • withCacheMode

      public HotRodTestClientDriver withCacheMode(Enum<?> mode)
    • withCacheMode

      public HotRodTestClientDriver withCacheMode(String mode)
    • withQualifier

      public HotRodTestClientDriver withQualifier(String qualifier)
    • makeVolatile

      public HotRodTestClientDriver makeVolatile()