public abstract class AbstractCassandraMojo
extends org.apache.maven.plugin.AbstractMojo
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
addMainClasspath
Adds the main classpath to cassandra (for example you could use this when you have a custom comparator on your
main classpath.
|
protected boolean |
addTestClasspath
Adds the test classpath to cassandra (for example you could use this when you have a custom comparator on your
test classpath.
|
protected File |
cassandraDir
The directory to hold cassandra's database.
|
protected int |
jmxPort
Port to listen to for the JMX interface.
|
protected String |
keyspace
The keyspace against which individual operations will be executed
|
protected String |
listenAddress
Address to bind to and tell other Cassandra nodes to connect to.
|
protected int |
maxMemory
Number of megabytes to limit the cassandra JVM to.
|
protected int |
nativeTransportPort
Port on which the CQL native transport listens for clients.
|
protected org.apache.maven.project.MavenProject |
project
The enclosing project.
|
protected String |
rpcAddress
Address to use for the RPC interface.
|
protected int |
rpcPort
Port to listen to for the RPC interface.
|
protected org.apache.maven.execution.MavenSession |
session
The current build session instance.
|
protected boolean |
skip
Skip the execution.
|
protected boolean |
startNativeTransport
Enable or disable the native transport server.
|
protected String |
stopKey
Key to be provided when stopping cassandra
|
protected int |
stopPort
Port to listen to for receiving the stop command over
|
protected int |
storagePort
Port to listen to for the Storage interface.
|
protected Map<String,String> |
systemPropertyVariables
List of System properties to pass to the JUnit tests.
|
| Constructor and Description |
|---|
AbstractCassandraMojo() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
createCassandraHome()
Creates the cassandra home directory.
|
protected void |
createCassandraHome(File cassandraDir,
String listenAddress,
String rpcAddress,
BigInteger initialToken,
String[] seeds)
Creates the cassandra home directory.
|
protected void |
createCassandraJar(File jarFile,
String mainClass)
Create a jar with just a manifest containing a Main-Class entry for SurefireBooter and a Class-Path entry for
all classpath elements.
|
protected void |
createCassandraJar(File jarFile,
String mainClass,
File cassandraDir)
Create a jar with just a manifest containing a Main-Class entry for SurefireBooter and a Class-Path entry for
all classpath elements.
|
protected Map<String,String> |
createEnvironmentVars()
Creates the environment required when launching Cassandra or the CLI tools.
|
protected org.apache.maven.toolchain.Toolchain |
getToolchain()
Gets the Java toolchain.
|
protected org.apache.commons.exec.CommandLine |
newJavaCommandLine()
Create a
CommandLine to launch Java. |
protected org.apache.commons.exec.CommandLine |
newNodetoolCommandLine(String... args)
Creates the command line to launch the
nodetool utility. |
protected org.apache.commons.exec.CommandLine |
newServiceCommandLine()
Creates the command line to launch the cassandra server.
|
protected org.apache.commons.exec.CommandLine |
newServiceCommandLine(File cassandraDir,
String listenAddress,
String rpcAddress,
BigInteger initialToken,
String[] seeds,
boolean jmxRemoteEnabled,
int jmxPort)
Creates the command line to launch the cassandra server.
|
getLog, getPluginContext, setLog, setPluginContextprotected File cassandraDir
protected org.apache.maven.project.MavenProject project
protected boolean addTestClasspath
protected boolean addMainClasspath
protected boolean skip
protected org.apache.maven.execution.MavenSession session
protected String rpcAddress
protected int rpcPort
protected int jmxPort
protected int nativeTransportPort
protected boolean startNativeTransport
protected String listenAddress
protected int storagePort
protected int stopPort
protected String stopKey
protected int maxMemory
protected String keyspace
protected void createCassandraJar(File jarFile, String mainClass) throws IOException
jarFile - The jar file to create/updatemainClass - The main class to run.IOException - if something went wrong.protected void createCassandraJar(File jarFile, String mainClass, File cassandraDir) throws IOException
jarFile - The jar file to create/updatemainClass - The main class to run.IOException - if something went wrong.protected void createCassandraHome()
throws IOException
IOException - if something goes wrong.protected void createCassandraHome(File cassandraDir, String listenAddress, String rpcAddress, BigInteger initialToken, String[] seeds) throws IOException
cassandraDir - the cassandra home directory.IOException - if something goes wrong.protected org.apache.maven.toolchain.Toolchain getToolchain()
protected org.apache.commons.exec.CommandLine newJavaCommandLine()
CommandLine to launch Java.CommandLine to launch Java.protected Map<String,String> createEnvironmentVars()
protected org.apache.commons.exec.CommandLine newServiceCommandLine()
throws IOException
IOException - if there are issues creating the cassandra home directory.protected org.apache.commons.exec.CommandLine newServiceCommandLine(File cassandraDir, String listenAddress, String rpcAddress, BigInteger initialToken, String[] seeds, boolean jmxRemoteEnabled, int jmxPort) throws IOException
IOException - if there are issues creating the cassandra home directory.protected org.apache.commons.exec.CommandLine newNodetoolCommandLine(String... args) throws IOException
nodetool utility.args - the command line arguments to pass to the nodetool utility.CommandLine to launch nodetool with the supplied arguments.IOException - if there are issues creating the cassandra home directory.Copyright © 2011–2015 MojoHaus. All rights reserved.