public class Container extends Object
<container>
tag used to configure the plugin
in the pom.xml
file.Constructor and Description |
---|
Container() |
Modifier and Type | Method and Description |
---|---|
Container |
createContainer(Configuration configuration,
Logger logger,
CargoProject project)
Creates the container based on its configuration and attaches the logger.
|
Container |
createContainer(Configuration configuration,
Logger logger,
CargoProject project,
org.apache.maven.artifact.factory.ArtifactFactory artifactFactory,
org.apache.maven.artifact.resolver.ArtifactResolver artifactResolver,
org.apache.maven.artifact.repository.ArtifactRepository localRepository,
List<org.apache.maven.artifact.repository.ArtifactRepository> repositories,
org.apache.maven.settings.Settings settings)
Creates the container based on its configuration and attaches the logger.
|
ArtifactInstaller |
getArtifactInstaller() |
String |
getContainerId() |
String |
getContextKey() |
Dependency[] |
getDependencies() |
String |
getHome() |
String |
getImplementation() |
String |
getInstallerZipFile() |
File |
getLog() |
LogLevel |
getLogLevel() |
String |
getOutput() |
Map<String,String> |
getSystemProperties() |
File |
getSystemPropertiesFile() |
Long |
getTimeout() |
ContainerType |
getType() |
ZipUrlInstaller |
getZipUrlInstaller() |
void |
setAppend(boolean append) |
void |
setArtifactInstaller(ArtifactInstaller artifactInstaller) |
void |
setContainerId(String containerId) |
void |
setContextKey(String contextKey) |
void |
setDependencies(Dependency[] dependencies) |
void |
setHome(String home) |
void |
setImplementation(String implementation) |
void |
setLog(File log) |
void |
setLogLevel(String levelAsString) |
void |
setOutput(String output) |
void |
setSystemProperties(Map<String,String> systemProperties) |
void |
setSystemPropertiesFile(File systemPropertiesFile) |
void |
setTimeout(Long timeout) |
void |
setType(ContainerType type) |
void |
setZipUrlInstaller(ZipUrlInstaller zipUrlInstaller) |
boolean |
shouldAppend() |
public void setSystemProperties(Map<String,String> systemProperties)
systemProperties
- System properties.public File getSystemPropertiesFile()
public void setSystemPropertiesFile(File systemPropertiesFile)
systemPropertiesFile
- System properties loaded from file.public Long getTimeout()
public String getInstallerZipFile()
public void setTimeout(Long timeout)
timeout
- Timeout (in milliseconds).public Dependency[] getDependencies()
public void setDependencies(Dependency[] dependencies)
dependencies
- List of dependencies.public ContainerType getType()
public void setType(ContainerType type)
type
- Container type.public String getContainerId()
public void setContainerId(String containerId)
containerId
- Container id.public String getHome()
public void setHome(String home)
home
- Container home.public String getOutput()
public void setOutput(String output)
output
- Output file.public ZipUrlInstaller getZipUrlInstaller()
ZipUrlInstaller
for the container.public void setZipUrlInstaller(ZipUrlInstaller zipUrlInstaller)
zipUrlInstaller
- ZipUrlInstaller
for the container.public ArtifactInstaller getArtifactInstaller()
ArtifactInstaller
for the container.public void setArtifactInstaller(ArtifactInstaller artifactInstaller)
artifactInstaller
- ArtifactInstaller
for the container.public boolean shouldAppend()
public void setAppend(boolean append)
append
- Whether to append logs.public void setLog(File log)
log
- Log file.public File getLog()
public void setLogLevel(String levelAsString)
levelAsString
- Log level.public LogLevel getLogLevel()
public String getImplementation()
public void setImplementation(String implementation)
implementation
- Container implementation.public String getContextKey()
public void setContextKey(String contextKey)
contextKey
- Container context key, which can be used to start, stop, configure or
deploy to the same Cargo container (together with its configuration) from different Maven
artifacts.public Container createContainer(Configuration configuration, Logger logger, CargoProject project) throws org.apache.maven.plugin.MojoExecutionException
configuration
- Container configuration.logger
- Logger.project
- Cargo project.org.apache.maven.plugin.MojoExecutionException
- If container creation fails.public Container createContainer(Configuration configuration, Logger logger, CargoProject project, org.apache.maven.artifact.factory.ArtifactFactory artifactFactory, org.apache.maven.artifact.resolver.ArtifactResolver artifactResolver, org.apache.maven.artifact.repository.ArtifactRepository localRepository, List<org.apache.maven.artifact.repository.ArtifactRepository> repositories, org.apache.maven.settings.Settings settings) throws org.apache.maven.plugin.MojoExecutionException
configuration
- Container configuration.logger
- Logger.project
- Cargo project.artifactFactory
- The artifact factory is used to create valid Maven
Artifact
objects.artifactResolver
- The artifact resolver is used to dynamically resolve
Artifact
objects. It will automatically download whatever
needed.localRepository
- The local Maven repository. This is used by the artifact resolver to
download resolved artifacts and put them in the local repository so that they won't have to
be fetched again next time the plugin is executed.repositories
- The remote Maven repositories used by the artifact resolver to look for
artifacts.settings
- Maven2 settings.org.apache.maven.plugin.MojoExecutionException
- If container creation fails.Copyright © 2004–2018 Github. All rights reserved.