@Mojo(name="upload",
defaultPhase=PACKAGE)
public class UploadMojo
extends org.apache.maven.plugin.AbstractMojo
| Modifier and Type | Field and Description |
|---|---|
protected String |
baseAuthPassword |
protected String |
baseAuthUser |
protected URL |
endpoint |
protected File |
file |
protected String |
repository |
protected org.springframework.web.client.RestTemplate |
restTemplate |
protected String |
sharedSecret |
protected String |
targetFile |
protected File |
targetFolder |
| Constructor and Description |
|---|
UploadMojo() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
debugBody(Object o,
org.springframework.http.MediaType mediaType) |
protected void |
determineFile() |
void |
execute() |
protected org.springframework.http.HttpHeaders |
getHeader() |
protected org.springframework.http.ResponseEntity<Repository> |
getRepository() |
protected void |
login() |
protected <T> org.springframework.http.ResponseEntity<T> |
send(Object requestObject,
org.springframework.http.HttpHeaders header,
org.springframework.http.HttpMethod method,
String path,
Class<T> resultType) |
protected <T> org.springframework.http.ResponseEntity<T> |
send(Object requestObject,
org.springframework.http.HttpHeaders header,
org.springframework.http.HttpMethod method,
String path,
Class<T> resultType,
boolean throwErrorOn4xx) |
protected org.springframework.http.ResponseEntity<Package> |
upload() |
protected org.springframework.http.ResponseEntity<Package> |
upload(boolean install,
boolean privileged,
boolean hidden) |
@Parameter(property="sharedSecret",
defaultValue="loreipsum",
required=true)
protected String sharedSecret
@Parameter(property="repository",
defaultValue="Local",
required=true)
protected String repository
@Parameter(property="endpoint",
defaultValue="http://localhost:8080/appNGizer/",
required=true)
protected URL endpoint
protected File file
@Parameter(defaultValue="${project.build.directory}",
readonly=true)
protected File targetFolder
@Parameter(defaultValue="${project.artifactId}-${project.version}",
readonly=true)
protected String targetFile
@Parameter(property="baseAuthUser") protected String baseAuthUser
@Parameter(property="baseAuthPassword") protected String baseAuthPassword
protected org.springframework.web.client.RestTemplate restTemplate
public void execute()
throws org.apache.maven.plugin.MojoExecutionException,
org.apache.maven.plugin.MojoFailureException
org.apache.maven.plugin.MojoExecutionExceptionorg.apache.maven.plugin.MojoFailureExceptionprotected <T> org.springframework.http.ResponseEntity<T> send(Object requestObject, org.springframework.http.HttpHeaders header, org.springframework.http.HttpMethod method, String path, Class<T> resultType) throws URISyntaxException, org.apache.maven.plugin.MojoExecutionException
URISyntaxExceptionorg.apache.maven.plugin.MojoExecutionExceptionprotected <T> org.springframework.http.ResponseEntity<T> send(Object requestObject, org.springframework.http.HttpHeaders header, org.springframework.http.HttpMethod method, String path, Class<T> resultType, boolean throwErrorOn4xx) throws URISyntaxException, org.apache.maven.plugin.MojoExecutionException
URISyntaxExceptionorg.apache.maven.plugin.MojoExecutionExceptionprotected void debugBody(Object o, org.springframework.http.MediaType mediaType)
protected org.springframework.http.HttpHeaders getHeader()
protected void login()
throws URISyntaxException,
org.apache.maven.plugin.MojoExecutionException
URISyntaxExceptionorg.apache.maven.plugin.MojoExecutionExceptionprotected org.springframework.http.ResponseEntity<Repository> getRepository() throws URISyntaxException, org.apache.maven.plugin.MojoExecutionException
URISyntaxExceptionorg.apache.maven.plugin.MojoExecutionExceptionprotected org.springframework.http.ResponseEntity<Package> upload() throws URISyntaxException, InterruptedException, ExecutionException
protected org.springframework.http.ResponseEntity<Package> upload(boolean install, boolean privileged, boolean hidden) throws URISyntaxException, InterruptedException, ExecutionException
protected void determineFile()
throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionExceptionCopyright © 2011–2021 aiticon GmbH. All rights reserved.