Package org.infinispan.server.test.core
Interface InfinispanServerDriver
-
- All Known Implementing Classes:
AbstractInfinispanServerDriver,ContainerInfinispanServerDriver,EmbeddedInfinispanServerDriver,ForkedInfinispanServerDriver
public interface InfinispanServerDriver- Since:
- 11.0
- Author:
- Tristan Tarrant <tristan@infinispan.org>
-
-
Field Summary
Fields Modifier and Type Field Description static org.infinispan.util.logging.Loglog
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidapplyKeyStore(org.infinispan.client.hotrod.configuration.ConfigurationBuilder builder, String certificateName)voidapplyKeyStore(org.infinispan.client.rest.configuration.RestClientConfigurationBuilder builder, String certificateName)voidapplyTrustStore(org.infinispan.client.hotrod.configuration.ConfigurationBuilder builder, String certificateName)voidapplyTrustStore(org.infinispan.client.rest.configuration.RestClientConfigurationBuilder builder, String certificateName)org.infinispan.client.hotrod.RemoteCacheManagercreateRemoteCacheManager(org.infinispan.client.hotrod.configuration.ConfigurationBuilder builder)FilegetCertificateFile(String name)FilegetConfDir()InfinispanServerTestConfigurationgetConfiguration()MBeanServerConnectiongetJmxConnection(int server)Returns aMBeanServerConnectionto the specified serverFilegetRootDir()InetAddressgetServerAddress(int server)Returns an InetAddress that points to a specific server.InetSocketAddressgetServerSocket(int server, int port)Returns an InetSocketAddress for connecting to a specific port on a specific server.org.infinispan.lifecycle.ComponentStatusgetStatus()intgetTimeout()Returns the amount of time in seconds that we should wait for a server start/stop operation.booleanisRunning(int server)Determines whether a specific server is running as part of a server configurationvoidkill(int server)Forcefully stops a server.voidpause(int server)Pauses a server.voidprepare(String name)Prepares a named server configurationvoidrestart(int server)Restarts a previously stopped server.voidrestartCluster()Restarts all of the nodesvoidresume(int server)Resumes a paused server.voidstart(String name)Starts a prepared server configurationvoidstop(int server)Gracefully stops a running servervoidstop(String name)Stops a running server configuration
-
-
-
Method Detail
-
getStatus
org.infinispan.lifecycle.ComponentStatus getStatus()
-
getConfiguration
InfinispanServerTestConfiguration getConfiguration()
-
prepare
void prepare(String name)
Prepares a named server configuration- Parameters:
name- the name of the server configuration
-
start
void start(String name)
Starts a prepared server configuration- Parameters:
name- the name of the server configuration
-
stop
void stop(String name)
Stops a running server configuration- Parameters:
name- the name of the server configuration
-
isRunning
boolean isRunning(int server)
Determines whether a specific server is running as part of a server configuration- Parameters:
server- the- Returns:
- true if the server is running, false otherwise
-
getServerSocket
InetSocketAddress getServerSocket(int server, int port)
Returns an InetSocketAddress for connecting to a specific port on a specific server. The implementation will need to provide a specific mapping (e.g. port offset).- Parameters:
server- the index of the serverport- the service port- Returns:
- an unresolved InetSocketAddress pointing to the actual running service
-
getServerAddress
InetAddress getServerAddress(int server)
Returns an InetAddress that points to a specific server.- Parameters:
server- the index of the server- Returns:
- an InetAddress pointing to the server's address
-
getRootDir
File getRootDir()
-
getConfDir
File getConfDir()
-
applyKeyStore
void applyKeyStore(org.infinispan.client.hotrod.configuration.ConfigurationBuilder builder, String certificateName)
-
applyKeyStore
void applyKeyStore(org.infinispan.client.rest.configuration.RestClientConfigurationBuilder builder, String certificateName)
-
applyTrustStore
void applyTrustStore(org.infinispan.client.hotrod.configuration.ConfigurationBuilder builder, String certificateName)
-
applyTrustStore
void applyTrustStore(org.infinispan.client.rest.configuration.RestClientConfigurationBuilder builder, String certificateName)
-
pause
void pause(int server)
Pauses a server. Equivalent to kill -SIGSTOP- Parameters:
server- the index of the server
-
resume
void resume(int server)
Resumes a paused server. Equivalent to kill -SIGCONT- Parameters:
server- the index of the server
-
stop
void stop(int server)
Gracefully stops a running server- Parameters:
server- the index of the server
-
kill
void kill(int server)
Forcefully stops a server. Equivalent to kill -SIGKILL- Parameters:
server- the index of the server
-
restart
void restart(int server)
Restarts a previously stopped server.- Parameters:
server- the index of the server
-
restartCluster
void restartCluster()
Restarts all of the nodes
-
getJmxConnection
MBeanServerConnection getJmxConnection(int server)
Returns aMBeanServerConnectionto the specified server- Parameters:
server- the index of the server
-
createRemoteCacheManager
org.infinispan.client.hotrod.RemoteCacheManager createRemoteCacheManager(org.infinispan.client.hotrod.configuration.ConfigurationBuilder builder)
-
getTimeout
int getTimeout()
Returns the amount of time in seconds that we should wait for a server start/stop operation. This may vary depending on the type of driver (embedded, container)- Returns:
- the number of seconds after which a server start/stop is considered to timeout
-
-