Unverified Commit 9290e578 authored by Gautier de Saint Martin Lacaze's avatar Gautier de Saint Martin Lacaze Committed by GitHub
Browse files

Merge branch 'master' into master

parents 91764d4e 47ef2d9e
root = true
[*]
insert_final_newline = true
[*.java]
indent_size = 4
indent_style = space
trim_trailing_whitespace = true
......@@ -54,7 +54,7 @@ To utilize GitLab4J™ API in your Java project, simply add the following de
```java
dependencies {
...
compile group: 'org.gitlab4j', name: 'gitlab4j-api', version: '4.16.0'
compile group: 'org.gitlab4j', name: 'gitlab4j-api', version: '4.18.0'
}
```
......@@ -65,7 +65,7 @@ dependencies {
<dependency>
<groupId>org.gitlab4j</groupId>
<artifactId>gitlab4j-api</artifactId>
<version>4.16.0</version>
<version>4.18.0</version>
</dependency>
```
......
......@@ -5,7 +5,7 @@
<groupId>org.gitlab4j</groupId>
<artifactId>gitlab4j-api</artifactId>
<packaging>jar</packaging>
<version>4.17.0-SNAPSHOT</version>
<version>4.19.0-SNAPSHOT</version>
<name>GitLab4J-API - GitLab API Java Client</name>
<description>GitLab4J-API (gitlab4j-api) provides a full featured Java client library for working with GitLab repositories and servers via the GitLab REST API.</description>
<url>https://github.com/gitlab4j/gitlab4j-api</url>
......@@ -77,7 +77,7 @@
<url>git@github.com:gitlab4j/gitlab4j-api.git</url>
<connection>scm:git:git@github.com:gitlab4j/gitlab4j-api.git</connection>
<developerConnection>scm:git:git@github.com:gitlab4j/gitlab4j-api.git</developerConnection>
<tag>HEAD</tag>
<tag>head</tag>
</scm>
<build>
......
......@@ -498,7 +498,7 @@ public class CommitsApi extends AbstractApi {
MultivaluedMap<String, String> queryParams = (filter != null ?
filter.getQueryParams(page, perPage).asMap() : getPageQueryParams(page, perPage));
Response response = get(Response.Status.OK, queryParams,
Response response = get(Response.Status.OK, queryParams,
"projects", this.getProjectIdOrPath(projectIdOrPath), "repository", "commits", sha, "statuses");
return (response.readEntity(new GenericType<List<CommitStatus>>() {}));
}
......@@ -515,7 +515,7 @@ public class CommitsApi extends AbstractApi {
* @return a Pager containing the commit statuses for the specified project and sha that meet the provided filter
* @throws GitLabApiException GitLabApiException if any exception occurs during execution
*/
public Pager<CommitStatus> getCommitStatuses(Object projectIdOrPath, String sha,
public Pager<CommitStatus> getCommitStatuses(Object projectIdOrPath, String sha,
CommitStatusFilter filter, int itemsPerPage) throws GitLabApiException {
if (projectIdOrPath == null) {
......@@ -567,6 +567,31 @@ public class CommitsApi extends AbstractApi {
* @throws GitLabApiException GitLabApiException if any exception occurs during execution
*/
public CommitStatus addCommitStatus(Object projectIdOrPath, String sha, CommitBuildState state, CommitStatus status) throws GitLabApiException {
return addCommitStatus(projectIdOrPath, sha, state, null, status);
}
/**
* <p>Add or update the build status of a commit. The following fluent methods are available on the
* CommitStatus instance for setting up the status:</p>
* <pre><code>
* withCoverage(Float)
* withDescription(String)
* withName(String)
* withRef(String)
* withTargetUrl(String)
* </code></pre>
*
* <pre><code>GitLab Endpoint: POST /projects/:id/statuses/:sha</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance (required)
* @param sha a commit SHA (required)
* @param state the state of the status. Can be one of the following: PENDING, RUNNING, SUCCESS, FAILED, CANCELED (required)
* @param pipelineId The ID of the pipeline to set status. Use in case of several pipeline on same SHA (optional)
* @param status the CommitSatus instance hoilding the optional parms: ref, name, target_url, description, and coverage
* @return a CommitStatus instance with the updated info
* @throws GitLabApiException GitLabApiException if any exception occurs during execution
*/
public CommitStatus addCommitStatus(Object projectIdOrPath, String sha, CommitBuildState state, Integer pipelineId, CommitStatus status) throws GitLabApiException {
if (projectIdOrPath == null) {
throw new RuntimeException("projectIdOrPath cannot be null");
......@@ -585,6 +610,10 @@ public class CommitsApi extends AbstractApi {
.withParam("coverage", status.getCoverage());
}
if (pipelineId != null) {
formData.withParam("pipeline_id", pipelineId);
}
Response response = post(Response.Status.OK, formData, "projects", getProjectIdOrPath(projectIdOrPath), "statuses", sha);
return (response.readEntity(CommitStatus.class));
}
......@@ -837,7 +866,7 @@ public class CommitsApi extends AbstractApi {
"projects", getProjectIdOrPath(projectIdOrPath), "repository", "commits", sha, "revert");
return (response.readEntity(Commit.class));
}
/**
* Cherry picks a commit in a given branch.
*
......
......@@ -243,6 +243,28 @@ public interface Constants {
}
}
/** Enum to use for ordering the results of getDeployments. */
public static enum DeploymentOrderBy {
ID, IID, CREATED_AT, UPDATED_AT, REF;
private static JacksonJsonEnumHelper<DeploymentOrderBy> enumHelper = new JacksonJsonEnumHelper<>(DeploymentOrderBy.class);
@JsonCreator
public static DeploymentOrderBy forValue(String value) {
return enumHelper.forValue(value);
}
@JsonValue
public String toValue() {
return (enumHelper.toString(this));
}
@Override
public String toString() {
return (enumHelper.toString(this));
}
}
/** Enum to use for specifying the scope when calling getPipelines(). */
public enum PipelineScope {
......@@ -783,7 +805,9 @@ public interface Constants {
/** Enum to use for specifying the status of a deployment. */
public enum DeploymentStatus {
/**
* After some tests, {@link #CREATED} value is not a valid value.
*/
CREATED, RUNNING, SUCCESS, FAILED, CANCELED;
private static JacksonJsonEnumHelper<DeploymentStatus> enumHelper = new JacksonJsonEnumHelper<>(DeploymentStatus.class);
......@@ -826,6 +850,29 @@ public interface Constants {
}
}
/** Enum for the build_git_strategy of the project instance. */
enum SquashOption {
NEVER, ALWAYS, DEFAULT_ON, DEFAULT_OFF;
private static JacksonJsonEnumHelper<SquashOption> enumHelper = new JacksonJsonEnumHelper<>(SquashOption.class);
@JsonCreator
public static SquashOption forValue(String value) {
return enumHelper.forValue(value);
}
@JsonValue
public String toValue() {
return (enumHelper.toString(this));
}
@Override
public String toString() {
return (enumHelper.toString(this));
}
}
/** Enum for the build_git_strategy of the project instance. */
enum BuildGitStrategy {
......
package org.gitlab4j.api;
import java.util.List;
import java.util.Optional;
import java.util.stream.Stream;
import javax.ws.rs.core.Response;
import org.gitlab4j.api.models.Deployment;
import org.gitlab4j.api.models.DeploymentFilter;
import org.gitlab4j.api.models.MergeRequest;
/**
* This class implements the client side API for the GitLab Deployments API calls.
* See https://docs.gitlab.com/ee/api/deployments.html
*
*/
public class DeploymentsApi extends AbstractApi {
public DeploymentsApi(GitLabApi gitLabApi) {
super(gitLabApi);
}
/**
* Get a list of deployments for the specified project.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @return a list of Deployments
* @throws GitLabApiException if any exception occurs
*/
public List<Deployment> getProjectDeployments(Object projectIdOrPath) throws GitLabApiException {
return (getProjectDeployments(projectIdOrPath, null, getDefaultPerPage()).all());
}
/**
* Get a Pager of all deployments for the specified project.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param itemsPerPage the number of Deployments instances that will be fetched per page
* @return a Pager of Deployment
* @throws GitLabApiException if any exception occurs
*/
public Pager<Deployment> getProjectDeployments(Object projectIdOrPath, int itemsPerPage) throws GitLabApiException {
return (getProjectDeployments(projectIdOrPath, null, itemsPerPage));
}
/**
* Get a Pager of all deployments for the specified project.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param filter {@link DeploymentFilter} a DeploymentFilter instance with the filter settings
* @return a Pager of Deployment
* @throws GitLabApiException if any exception occurs
*/
public Pager<Deployment> getProjectDeployments(Object projectIdOrPath, DeploymentFilter filter) throws GitLabApiException {
return (getProjectDeployments(projectIdOrPath, filter, getDefaultPerPage()));
}
/**
* Get a Pager of all deployments for the specified project.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param filter {@link DeploymentFilter} a DeploymentFilter instance with the filter settings
* @param itemsPerPage the number of Deployments instances that will be fetched per page
* @return a Pager of Deployment
* @throws GitLabApiException if any exception occurs
*/
public Pager<Deployment> getProjectDeployments(Object projectIdOrPath, DeploymentFilter filter, int itemsPerPage) throws GitLabApiException {
GitLabApiForm formData = (filter != null ? filter.getQueryParams() : new GitLabApiForm());
return (new Pager<Deployment>(this, Deployment.class, itemsPerPage, formData.asMap(),
"projects", getProjectIdOrPath(projectIdOrPath), "deployments"));
}
/**
* Get a Stream of all deployments for the specified project.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @return a list of Deployment
* @throws GitLabApiException if any exception occurs
*/
public Stream<Deployment> getProjectDeploymentsStream(Object projectIdOrPath) throws GitLabApiException {
return (getProjectDeployments(projectIdOrPath, null, getDefaultPerPage()).stream());
}
/**
* Get a Stream of all deployments for the specified project.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param filter {@link DeploymentFilter} a DeploymentFilter instance with the filter settings
* @return a list of Deployment
* @throws GitLabApiException if any exception occurs
*/
public Stream<Deployment> getProjectDeploymentsStream(Object projectIdOrPath, DeploymentFilter filter) throws GitLabApiException {
return (getProjectDeployments(projectIdOrPath, filter, getDefaultPerPage()).stream());
}
/**
* Get a specific deployment.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments/:deployment_id</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param deploymentId the ID of a project's deployment
* @return the specified Deployment instance
* @throws GitLabApiException if any exception occurs
*/
public Deployment getDeployment(Object projectIdOrPath, Integer deploymentId) throws GitLabApiException {
Response response = get(Response.Status.OK, getDefaultPerPageParam(),
"projects", getProjectIdOrPath(projectIdOrPath), "deployments", deploymentId);
return (response.readEntity(Deployment.class));
}
/**
* Get a specific deployment as an Optional instance.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments/:deployment_id</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param deploymentId the ID of a project's deployment
* @return the specified Deployment as an Optional instance
*/
public Optional<Deployment> getOptionalDeployment(Object projectIdOrPath, Integer deploymentId) {
try {
return (Optional.ofNullable(getDeployment(projectIdOrPath, deploymentId)));
} catch (GitLabApiException glae) {
return (GitLabApi.createOptionalFromException(glae));
}
}
/**
* Creates a new deployment for a project.
*
* <pre><code>GitLab Endpoint: POST /projects/:id/deployments</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param environment The name of the environment to create the deployment for, required
* @param sha The SHA of the commit that is deployed, required
* @param ref The name of the branch or tag that is deployed, required
* @param tag A boolean that indicates if the deployed ref is a tag (true) or not (false), required
* @param status The status to filter deployments by, required
* @return a Deployment instance with info on the added deployment
* @throws GitLabApiException if any exception occurs
*/
public Deployment addDeployment(Object projectIdOrPath, String environment, String sha, String ref, Boolean tag, DeploymentStatus status) throws GitLabApiException {
GitLabApiForm formData = new GitLabApiForm()
.withParam("environment", environment, true)
.withParam("sha", sha, true)
.withParam("ref", ref, true)
.withParam("tag", tag, true)
.withParam("status", status, true);
Response response = post(Response.Status.CREATED, formData,
"projects", getProjectIdOrPath(projectIdOrPath), "deployments");
return (response.readEntity(Deployment.class));
}
/**
* Updates an existing project deploy key.
*
* <pre><code>GitLab Endpoint: PUT /projects/:id/deployments/:key_id</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param deploymentId The ID of the deployment to update, required
* @param status The new status of the deployment, required
* @return an updated Deployment instance
* @throws GitLabApiException if any exception occurs
*/
public Deployment updateDeployment(Object projectIdOrPath, Integer deploymentId, DeploymentStatus status) throws GitLabApiException {
if (deploymentId == null) {
throw new RuntimeException("deploymentId cannot be null");
}
final Deployment deployment = new Deployment();
deployment.setStatus(status);
final Response response = put(Response.Status.OK, deployment,
"projects", getProjectIdOrPath(projectIdOrPath), "deployments", deploymentId);
return (response.readEntity(Deployment.class));
}
/**
* Get a list of Merge Requests shipped with a given deployment.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments/:deployment_id/merge_requests</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param deploymentId The ID of the deployment to update, required
* @return a list containing the MergeRequest instances shipped with a given deployment
* @throws GitLabApiException GitLabApiException if any exception occurs during execution
*/
public List<MergeRequest> getMergeRequests(Object projectIdOrPath, Integer deploymentId) throws GitLabApiException {
return (getMergeRequests(projectIdOrPath, deploymentId, getDefaultPerPage()).all());
}
/**
* Get a Pager of Merge Requests shipped with a given deployment.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments/:deployment_id/merge_requests</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param deploymentId The ID of the deployment to update, required
* @param itemsPerPage the number of Commit instances that will be fetched per page
* @return a Pager containing the MergeRequest instances shipped with a given deployment
* @throws GitLabApiException GitLabApiException if any exception occurs during execution
*/
public Pager<MergeRequest> getMergeRequests(Object projectIdOrPath, Integer deploymentId, int itemsPerPage) throws GitLabApiException {
return (new Pager<MergeRequest>(this, MergeRequest.class, itemsPerPage, null,
"projects", getProjectIdOrPath(projectIdOrPath), "repository", "commits", deploymentId, "merge_requests"));
}
/**
* Get a Stream of Merge Requests shipped with a given deployment.
*
* <pre><code>GitLab Endpoint: GET /projects/:id/deployments/:deployment_id/merge_requests</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param deploymentId The ID of the deployment to update, required
* @return a Stream containing the MergeRequest instances shipped with a given deployment
* @throws GitLabApiException GitLabApiException if any exception occurs during execution
*/
public Stream<MergeRequest> getMergeRequestsStream(Object projectIdOrPath, Integer deploymentId) throws GitLabApiException {
return (getMergeRequests(projectIdOrPath, deploymentId, getDefaultPerPage()).stream());
}
}
......@@ -368,7 +368,7 @@ public class DiscussionsApi extends AbstractApi {
public void deleteMergeRequestDiscussionNote(Object projectIdOrPath, Integer mergeRequestIid,
String discussionId, Integer noteId) throws GitLabApiException {
delete(Response.Status.OK, null, "projects", getProjectIdOrPath(projectIdOrPath),
"merge_requests", mergeRequestIid, "discussions", noteId);
"merge_requests", mergeRequestIid, "discussions", discussionId, "notes", noteId);
}
/**
......@@ -754,4 +754,4 @@ public class DiscussionsApi extends AbstractApi {
delete(Response.Status.OK, null, "projects", getProjectIdOrPath(projectIdOrPath), "issues", issueIid, "discussions", discussionId, "notes", noteId);
}
}
\ No newline at end of file
}
......@@ -58,6 +58,7 @@ public class GitLabApi implements AutoCloseable {
private ContainerRegistryApi containerRegistryApi;
private DiscussionsApi discussionsApi;
private DeployKeysApi deployKeysApi;
private DeploymentsApi deploymentsApi;
private DeployTokensApi deployTokensApi;
private EnvironmentsApi environmentsApi;
private EpicsApi epicsApi;
......@@ -961,6 +962,25 @@ public class GitLabApi implements AutoCloseable {
return (deployKeysApi);
}
/**
* Gets the DeployKeysApi instance owned by this GitLabApi instance. The DeploymentsApi is used
* to perform all deployment related API calls.
*
* @return the DeploymentsApi instance owned by this GitLabApi instance
*/
public DeploymentsApi getDeploymentsApi() {
if (deploymentsApi == null) {
synchronized (this) {
if (deploymentsApi == null) {
deploymentsApi = new DeploymentsApi(this);
}
}
}
return (deploymentsApi);
}
/**
* Gets the DeployTokensApi instance owned by this GitLabApi instance. The DeployTokensApi is used
* to perform all deploy token related API calls.
......
......@@ -238,7 +238,8 @@ public class ImportExportApi extends AbstractApi {
.withParam("initialize_with_readme", overrideParams.getInitializeWithReadme())
.withParam("packages_enabled", overrideParams.getPackagesEnabled())
.withParam("build_git_strategy", overrideParams.getBuildGitStrategy())
.withParam("build_coverage_regex", overrideParams.getBuildCoverageRegex());
.withParam("build_coverage_regex", overrideParams.getBuildCoverageRegex())
.withParam("squash_option", overrideParams.getSquashOption());
}
Response response = upload(Response.Status.CREATED, "file", exportFile, null, formData, url);
......
......@@ -387,7 +387,7 @@ public class IssuesApi extends AbstractApi implements Constants {
* Create an issue for the project.
*
* <pre><code>GitLab Endpoint: POST /projects/:id/issues</code></pre>
*
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param title the title of an issue, required
* @param description the description of an issue, optional
......@@ -412,9 +412,9 @@ public class IssuesApi extends AbstractApi implements Constants {
* @param labels comma-separated label names for an issue, optional
* @param createdAt the date the issue was created at, optional
* @param dueDate the due date, optional
* @param mergeRequestToResolveId the IID of a merge request in which to resolve all issues. This will fill the issue with a default
* @param mergeRequestToResolveId the IID of a merge request in which to resolve all issues. This will fill the issue with a default
* description and mark all discussions as resolved. When passing a description or title, these values will take precedence over the default values. Optional
* @param discussionToResolveId the ID of a discussion to resolve. This will fill in the issue with a default description and mark the discussion as resolved.
* @param discussionToResolveId the ID of a discussion to resolve. This will fill in the issue with a default description and mark the discussion as resolved.
* Use in combination with merge_request_to_resolve_discussions_of. Optional
* @return an instance of Issue
* @throws GitLabApiException if any exception occurs
......@@ -434,7 +434,7 @@ public class IssuesApi extends AbstractApi implements Constants {
.withParam("merge_request_to_resolve_discussions_of", mergeRequestToResolveId)
.withParam("discussion_to_resolve", discussionToResolveId);
Response response = post(Response.Status.CREATED, formData, "projects", getProjectIdOrPath(projectIdOrPath), "issues");
return (response.readEntity(Issue.class));
return (response.readEntity(Issue.class));
}
/**
......@@ -453,9 +453,9 @@ public class IssuesApi extends AbstractApi implements Constants {
throw new RuntimeException("issue IID cannot be null");
}
GitLabApiForm formData = new GitLabApiForm().withParam("state_event", StateEvent.CLOSE);
GitLabApiForm formData = new GitLabApiForm().withParam("state_event", StateEvent.CLOSE);
Response response = put(Response.Status.OK, formData.asMap(), "projects", getProjectIdOrPath(projectIdOrPath), "issues", issueIid);
return (response.readEntity(Issue.class));
return (response.readEntity(Issue.class));
}
/**
......@@ -477,7 +477,7 @@ public class IssuesApi extends AbstractApi implements Constants {
* @return an instance of the updated Issue
* @throws GitLabApiException if any exception occurs
*/
public Issue updateIssue(Object projectIdOrPath, Integer issueIid, String title, String description, Boolean confidential, List<Integer> assigneeIds,
public Issue updateIssue(Object projectIdOrPath, Integer issueIid, String title, String description, Boolean confidential, List<Integer> assigneeIds,
Integer milestoneId, String labels, StateEvent stateEvent, Date updatedAt, Date dueDate) throws GitLabApiException {
if (issueIid == null) {
......@@ -495,7 +495,7 @@ public class IssuesApi extends AbstractApi implements Constants {
.withParam("updated_at", updatedAt)
.withParam("due_date", dueDate);
Response response = put(Response.Status.OK, formData.asMap(), "projects", getProjectIdOrPath(projectIdOrPath), "issues", issueIid);
return (response.readEntity(Issue.class));
return (response.readEntity(Issue.class));
}
/**
......@@ -541,9 +541,9 @@ public class IssuesApi extends AbstractApi implements Constants {
/**
* Sets an estimated time of work in this issue
*
*
* <pre><code>GitLab Endpoint: POST /projects/:id/issues/:issue_iid/time_estimate</code></pre>
*
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance, required
* @param issueIid the internal ID of a project's issue
* @param duration estimated time in seconds
......@@ -556,9 +556,9 @@ public class IssuesApi extends AbstractApi implements Constants {
/**
* Sets an estimated time of work in this issue
*
*
* <pre><code>GitLab Endpoint: POST /projects/:id/issues/:issue_iid/time_estimate</code></pre>
*
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance, required
* @param issueIid the internal ID of a project's issue
* @param duration Human readable format, e.g. 3h30m
......@@ -571,9 +571,9 @@ public class IssuesApi extends AbstractApi implements Constants {
/**
* Sets an estimated time of work in this issue
*
*
* <pre><code>GitLab Endpoint: POST /projects/:id/issues/:issue_iid/time_estimate</code></pre>
*
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param issueIid the internal ID of a project's issue
* @param duration set the estimate of time to this duration
......@@ -596,9 +596,9 @@ public class IssuesApi extends AbstractApi implements Constants {
/**
* Resets the estimated time for this issue to 0 seconds.
*
*
* <pre><code>GitLab Endpoint: POST /projects/:id/issues/:issue_iid/reset_time_estimate</code></pre>
*
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param issueIid the internal ID of a project's issue
* @return a TimeSTats instance
......@@ -617,9 +617,9 @@ public class IssuesApi extends AbstractApi implements Constants {
/**
* Adds spent time for this issue
*
*
* <pre><code>GitLab Endpoint: POST /projects/:id/issues/:issue_iid/add_spent_time</code></pre>
*
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param issueIid the internal ID of a project's issue
* @param duration the duration in seconds
......@@ -632,9 +632,9 @@ public class IssuesApi extends AbstractApi implements Constants {
/**
* Adds spent time for this issue
*
*
* <pre><code>GitLab Endpoint: POST /projects/:id/issues/:issue_iid/add_spent_time</code></pre>
*
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param issueIid the internal ID of a project's issue
* @param duration Human readable format, e.g. 3h30m
......@@ -647,9 +647,9 @@ public class IssuesApi extends AbstractApi implements Constants {
/**
* Adds spent time for this issue
*
*
* <pre><code>GitLab Endpoint: POST /projects/:id/issues/:issue_iid/add_spent_time</code></pre>
*
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param issueIid the internal ID of a project's issue
* @param duration the duration of time spent
......@@ -672,9 +672,9 @@ public class IssuesApi extends AbstractApi implements Constants {
/**
* Resets the total spent time for this issue to 0 seconds.
*
*
* <pre><code>GitLab Endpoint: POST /projects/:id/issues/:issue_iid/reset_spent_time</code></pre>
*
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param issueIid the internal ID of a project's issue
* @return a TimeSTats instance
......@@ -693,9 +693,9 @@ public class IssuesApi extends AbstractApi implements Constants {
/**
* Get time tracking stats.
*
*
* <pre><code>GitLab Endpoint: GET /projects/:id/issues/:issue_iid/time_stats</code></pre>
*
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance
* @param issueIid the internal ID of a project's issue
* @return a TimeStats instance
......@@ -983,9 +983,25 @@ public class IssuesApi extends AbstractApi implements Constants {
return (response.readEntity(IssuesStatistics.class));
}
/**
* Gets issues count statistics for given project.
*
* <pre><code>GitLab Endpoint: GET /projects/:projectId/issues_statistics</code></pre>
*
* @param projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instance, required
* @param filter {@link IssuesStatisticsFilter} a IssuesStatisticsFilter instance with the filter settings.
* @return an IssuesStatistics instance with the statistics for the matched issues
* @throws GitLabApiException if any exception occurs
*/
public IssuesStatistics geProjectIssuesStatistics(Object projectIdOrPath, IssuesStatisticsFilter filter) throws GitLabApiException {
GitLabApiForm formData = filter.getQueryParams();
Response response = get(Response.Status.OK, formData.asMap(), "projects", this.getProjectIdOrPath(projectIdOrPath), "issues_statistics");
return (response.readEntity(IssuesStatistics.class));
}
/**
* <p>Moves an issue to a different project. If the target project equals the source project or
* the user has insufficient permissions to move an issue, error 400 together with an
* the user has insufficient permissions to move an issue, error 400 together with an
* explaining error message is returned.</p>
*
* <p>If a given label and/or milestone with the same name also exists in the target project,
......@@ -1004,5 +1020,5 @@ public class IssuesApi extends AbstractApi implements Constants {
Response response = post(Response.Status.OK, formData,
"projects", this.getProjectIdOrPath(projectIdOrPath), "issues", issueIid, "move");
return (response.readEntity(Issue.class));
}
}
}
package org.gitlab4j.api;
import javax.ws.rs.core.Form;
import javax.ws.rs.core.Response;
import org.gitlab4j.api.GitLabApi.ApiVersion;
import org.gitlab4j.api.models.Markdown;
import org.gitlab4j.api.models.MarkdownRequest;
import javax.ws.rs.core.Response;
/**
* This class provides an entry point to all the GitLab API markdown calls.
......@@ -30,8 +31,26 @@ public class MarkdownApi extends AbstractApi {
throw new GitLabApiException("Api version must be v4");
}
Form formData = new GitLabApiForm().withParam("text", text, true);
Response response = post(Response.Status.OK, formData.asMap(), "markdown");
return getMarkdown(new MarkdownRequest(text, true));
}
/**
* Render an arbitrary Markdown document.
*
* <pre><code>GitLab Endpoint: POST /api/v4/markdown</code></pre>
*
* @param markdownRequest a request of markdown transformation
* @return a Markdown instance with transformed info
* @throws GitLabApiException if any exception occurs
* @since GitLab 11.0
*/
public Markdown getMarkdown(MarkdownRequest markdownRequest) throws GitLabApiException {
if (!isApiVersion(ApiVersion.V4)) {
throw new GitLabApiException("Api version must be v4");
}
Response response = post(Response.Status.OK, markdownRequest, "markdown");
return (response.readEntity(Markdown.class));
}
}
\ No newline at end of file
......@@ -306,12 +306,6 @@ public class Pager<T> implements Iterator<List<T>>, Constants {
*/
public List<T> page(int pageNumber) {
if (pageNumber > totalPages && pageNumber > kaminariNextPage) {
throw new NoSuchElementException();
} else if (pageNumber < 1) {
throw new NoSuchElementException();
}
if (currentPage == 0 && pageNumber == 1) {
currentPage = 1;
return (currentItems);
......@@ -321,6 +315,12 @@ public class Pager<T> implements Iterator<List<T>>, Constants {
return (currentItems);
}
if (pageNumber > totalPages && pageNumber > kaminariNextPage) {
throw new NoSuchElementException();
} else if (pageNumber < 1) {
throw new NoSuchElementException();
}
try {
setPageParam(pageNumber);
......
......@@ -924,7 +924,7 @@ public class ProjectApi extends AbstractApi implements Constants {
* @throws GitLabApiException if any exception occurs
*/
public Project createProject(String name, String path) throws GitLabApiException {
if ((name == null || name.trim().isEmpty()) && (path == null || path.trim().isEmpty())) {
throw new RuntimeException("Either name or path must be specified.");
}
......@@ -977,6 +977,7 @@ public class ProjectApi extends AbstractApi implements Constants {
* buildGitStrategy (optional) - set the build git strategy
* buildCoverageRegex (optional) - set build coverage regex
* ciConfigPath (optional) - Set path to CI configuration file
* squashOption (optional) - set squash option for merge requests
*
* @param project the Project instance with the configuration for the new project
* @param importUrl the URL to import the repository from
......@@ -1025,6 +1026,9 @@ public class ProjectApi extends AbstractApi implements Constants {
.withParam("build_git_strategy", project.getBuildGitStrategy())
.withParam("build_coverage_regex", project.getBuildCoverageRegex())
.withParam("ci_config_path", project.getCiConfigPath());
.withParam("suggestion_commit_message", project.getSuggestionCommitMessage())
.withParam("remove_source_branch_after_merge", project.getRemoveSourceBranchAfterMerge())
.withParam("squash_option", project.getSquashOption());
Namespace namespace = project.getNamespace();
if (namespace != null && namespace.getId() != null) {
......@@ -1224,12 +1228,12 @@ public class ProjectApi extends AbstractApi implements Constants {
* buildCoverageRegex (optional) - set build coverage regex
* ciConfigPath (optional) - Set path to CI configuration file
* ciForwardDeploymentEnabled (optional) - When a new deployment job starts, skip older deployment jobs that are still pending
* squashOption (optional) - set squash option for merge requests
*
* NOTE: The following parameters specified by the GitLab API edit project are not supported:
* import_url
* tag_list array
* avatar
* ci_config_path
* initialize_with_readme
*
* @param project the Project instance with the configuration for the new project
......@@ -1272,6 +1276,10 @@ public class ProjectApi extends AbstractApi implements Constants {
.withParam("build_coverage_regex", project.getBuildCoverageRegex())
.withParam("ci_config_path", project.getCiConfigPath())
.withParam("ci_forward_deployment_enabled", project.getCiForwardDeploymentEnabled());
.withParam("merge_method", project.getMergeMethod())
.withParam("suggestion_commit_message", project.getSuggestionCommitMessage())
.withParam("remove_source_branch_after_merge", project.getRemoveSourceBranchAfterMerge())
.withParam("squash_option", project.getSquashOption());
if (isApiVersion(ApiVersion.V3)) {
formData.withParam("visibility_level", project.getVisibilityLevel());
......@@ -2067,9 +2075,11 @@ public class ProjectApi extends AbstractApi implements Constants {
.withParam("confidential_note_events", enabledHooks.getConfidentialNoteEvents(), false)
.withParam("job_events", enabledHooks.getJobEvents(), false)
.withParam("pipeline_events", enabledHooks.getPipelineEvents(), false)
.withParam("wiki_events", enabledHooks.getWikiPageEvents(), false)
.withParam("wiki_page_events", enabledHooks.getWikiPageEvents(), false)
.withParam("enable_ssl_verification", enableSslVerification, false)
.withParam("repository_update_events", enabledHooks.getRepositoryUpdateEvents(), false)
.withParam("deployment_events", enabledHooks.getDeploymentEvents(), false)
.withParam("releases_events", enabledHooks.getReleasesEvents(), false)
.withParam("token", secretToken, false);
Response response = post(Response.Status.CREATED, formData, "projects", getProjectIdOrPath(projectIdOrPath), "hooks");
return (response.readEntity(ProjectHook.class));
......@@ -2147,7 +2157,7 @@ public class ProjectApi extends AbstractApi implements Constants {
.withParam("note_events", hook.getNoteEvents(), false)
.withParam("job_events", hook.getJobEvents(), false)
.withParam("pipeline_events", hook.getPipelineEvents(), false)
.withParam("wiki_events", hook.getWikiPageEvents(), false)
.withParam("wiki_page_events", hook.getWikiPageEvents(), false)
.withParam("enable_ssl_verification", hook.getEnableSslVerification(), false)
.withParam("token", hook.getToken(), false);
......
......@@ -80,12 +80,32 @@ public class SystemHooksApi extends AbstractApi {
* @param token secret token to validate received payloads, optional
* @param pushEvents when true, the hook will fire on push events, optional
* @param tagPushEvents when true, the hook will fire on new tags being pushed, optional
* @param enablSsslVerification do SSL verification when triggering the hook, optional
* @param enableSslVerification do SSL verification when triggering the hook, optional
* @return an SystemHookEvent instance with info on the added system hook
* @throws GitLabApiException if any exception occurs
*/
public SystemHook addSystemHook(String url, String token, Boolean pushEvents,
Boolean tagPushEvents, Boolean enablSsslVerification) throws GitLabApiException {
Boolean tagPushEvents, Boolean enableSslVerification) throws GitLabApiException {
SystemHook systemHook = new SystemHook().withPushEvents(pushEvents)
.withTagPushEvents(tagPushEvents)
.withEnableSslVerification(enableSslVerification);
return addSystemHook(url, token, systemHook);
}
/**
* Add a new system hook. This method requires admin access.
*
* <pre><code>GitLab Endpoint: POST /hooks</code></pre>
*
* @param url the hook URL, required
* @param token secret token to validate received payloads, optional
* @param systemHook the systemHook to create
* @return an SystemHookEvent instance with info on the added system hook
* @throws GitLabApiException if any exception occurs
*/
public SystemHook addSystemHook(String url, String token, SystemHook systemHook) throws GitLabApiException {
if (url == null) {
throw new RuntimeException("url cannot be null");
......@@ -94,9 +114,11 @@ public class SystemHooksApi extends AbstractApi {
GitLabApiForm formData = new GitLabApiForm()
.withParam("url", url, true)
.withParam("token", token)
.withParam("push_events", pushEvents)
.withParam("tag_push_events", tagPushEvents)
.withParam("enable_ssl_verification", enablSsslVerification);
.withParam("push_events", systemHook.getPushEvents())
.withParam("tag_push_events", systemHook.getTagPushEvents())
.withParam("merge_requests_events", systemHook.getMergeRequestsEvents())
.withParam("repository_update_events", systemHook.getRepositoryUpdateEvents())
.withParam("enable_ssl_verification", systemHook.getEnableSslVerification());
Response response = post(Response.Status.CREATED, formData, "hooks");
return (response.readEntity(SystemHook.class));
}
......
......@@ -424,7 +424,7 @@ public class TagsApi extends AbstractApi {
* @throws GitLabApiException if any exception occurs
*/
public ProtectedTag protectTag(Object projectIdOrPath, String name, AccessLevel createAccessLevel) throws GitLabApiException {
Form formData = new GitLabApiForm().withParam("name", name, true).withParam("create_access_Level", createAccessLevel);
Form formData = new GitLabApiForm().withParam("name", name, true).withParam("create_access_level", createAccessLevel);
Response response = post(Response.Status.OK, formData, "projects", getProjectIdOrPath(projectIdOrPath), "protected_tags");
return (response.readEntity(ProtectedTag.class));
}
......
......@@ -14,8 +14,10 @@ import javax.ws.rs.core.Response;
import org.gitlab4j.api.GitLabApi.ApiVersion;
import org.gitlab4j.api.models.CustomAttribute;
import org.gitlab4j.api.models.Email;
import org.gitlab4j.api.models.GpgKey;
import org.gitlab4j.api.models.ImpersonationToken;
import org.gitlab4j.api.models.ImpersonationToken.Scope;
import org.gitlab4j.api.models.Membership;
import org.gitlab4j.api.models.SshKey;
import org.gitlab4j.api.models.User;
import org.gitlab4j.api.utils.EmailChecker;
......@@ -511,6 +513,7 @@ public class UserApi extends AbstractApi {
* @throws GitLabApiException if any exception occurs
* @deprecated Will be removed in version 5.0, replaced by {@link #createUser(User, CharSequence, boolean)}
*/
@Deprecated
public User createUser(User user, CharSequence password, Integer projectsLimit) throws GitLabApiException {
Form formData = userToForm(user, projectsLimit, password, null, true);
Response response = post(Response.Status.CREATED, formData, "users");
......@@ -522,7 +525,7 @@ public class UserApi extends AbstractApi {
* Either password or resetPassword should be specified (resetPassword takes priority).</p>
*
* <pre><code>GitLab Endpoint: POST /users</code></pre>
*
*
* <p>The following properties of the provided User instance can be set during creation:<pre><code> email (required) - Email
* username (required) - Username
* name (required) - Name
......@@ -1211,4 +1214,101 @@ public class UserApi extends AbstractApi {
public void deleteEmail(final Object userIdOrUsername, final Long emailId) throws GitLabApiException {
delete(Response.Status.NO_CONTENT, null, "users", getUserIdOrUsername(userIdOrUsername), "emails", emailId);
}
/**
* Get all GPG keys for the current user.
*
* <pre><code>GitLab Endpoint: GET /user/gpg_keys</code></pre>
*
* @throws GitLabApiException if any exception occurs
*/
public List<GpgKey> listGpgKeys() throws GitLabApiException {
Response response = get(Response.Status.OK, null, "user", "gpg_keys");
return (response.readEntity(new GenericType<List<GpgKey>>() {}));
}
/**
* Add a GPG key for the current user
*
* <pre><code>GitLab Endpoint: POST /user/gpg_keys</code></pre>
*
* @param key the ASCII-armored exported public GPG key to add
* @throws GitLabApiException if any exception occurs
*/
public GpgKey addGpgKey(final String key) throws GitLabApiException {
GitLabApiForm formData = new GitLabApiForm()
.withParam("key", key, true);
Response response = post(Response.Status.CREATED, formData, "user", "gpg_keys");
return (response.readEntity(GpgKey.class));
}
/**
* Remove a specific GPG key for the current user
*
* <pre><code>GitLab Endpoint: DELETE /user/gpg_keys/:keyId</code></pre>
*
* @param keyId the key ID in the form if an Integer(ID)
* @throws GitLabApiException if any exception occurs
*/
public void deleteGpgKey(final Integer keyId) throws GitLabApiException {
delete(Response.Status.NO_CONTENT, null, "user", "gpg_keys", keyId);
}
/**
* Get all GPG keys for a given user.
*
* <pre><code>GitLab Endpoint: GET /users/:id/gpg_keys</code></pre>
*
* @param userId the user in the form of an Integer(ID)
* @throws GitLabApiException if any exception occurs
*/
public List<GpgKey> listGpgKeys(final Integer userId) throws GitLabApiException {
Response response = get(Response.Status.OK, null, "users", userId, "gpg_keys");
return (response.readEntity(new GenericType<List<GpgKey>>() {}));
}
/**
* Add a GPG key for a specific user
*
* <pre><code>GitLab Endpoint: POST /users/:id/gpg_keys</code></pre>
*
* @param userId the user in the form of an Integer(ID)
* @param key the ASCII-armored exported public GPG key to add
* @throws GitLabApiException if any exception occurs
*/
public GpgKey addGpgKey(final Integer userId, final String key) throws GitLabApiException {
GitLabApiForm formData = new GitLabApiForm()
.withParam("key", key, true);
Response response = post(Response.Status.CREATED, formData, "users", userId, "gpg_keys");
return (response.readEntity(GpgKey.class));
}
/**
* Remove a specific GPG key for a specific user
*
* <pre><code>GitLab Endpoint: DELETE /users/:id/gpg_keys/:keyId</code></pre>
*
* @param userId the user in the form of an Integer(ID)
* @param keyId the key ID in the form if an Integer(ID)
* @throws GitLabApiException if any exception occurs
*/
public void deleteGpgKey(final Integer userId, final Integer keyId) throws GitLabApiException {
delete(Response.Status.NO_CONTENT, null, "users", userId, "gpg_keys", keyId);
}
/**
* Lists all projects and groups a user is a member of. (admin only)
*
* <pre><code>GitLab Endpoint: GET /users/:id/memberships</code></pre>
*
* @param userId the ID of the user to get the memberships for
* @return the list of memberships of the given user
* @throws GitLabApiException if any exception occurs
* @since GitLab 12.8
*/
public List<Membership> getMemberships(Integer userId) throws GitLabApiException {
GitLabApiForm formData = new GitLabApiForm();
Response response = get(Response.Status.OK, formData.asMap(), "users", userId, "memberships");
return (response.readEntity(new GenericType<List<Membership>>() {}));
}
}
......@@ -5,7 +5,7 @@ import org.gitlab4j.api.utils.JacksonJson;
public class ArtifactsFile {
private String filename;
private Integer size;
private Long size;
public String getFilename() {
return filename;
......@@ -15,11 +15,11 @@ public class ArtifactsFile {
this.filename = filename;
}
public Integer getSize() {
public Long getSize() {
return size;
}
public void setSize(Integer size) {
public void setSize(Long size) {
this.size = size;
}
......
......@@ -30,6 +30,7 @@ public class Badge {
}
private Integer id;
private String name;
private String linkUrl;
private String imageUrl;
private String renderedLinkUrl;
......@@ -37,55 +38,63 @@ public class Badge {
private BadgeKind kind;
public Integer getId() {
return id;
return id;
}
public void setId(Integer id) {
this.id = id;
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getLinkUrl() {
return linkUrl;
return linkUrl;
}
public void setLinkUrl(String linkUrl) {
this.linkUrl = linkUrl;
this.linkUrl = linkUrl;
}
public String getImageUrl() {
return imageUrl;
return imageUrl;
}
public void setImageUrl(String imageUrl) {
this.imageUrl = imageUrl;
this.imageUrl = imageUrl;
}
public String getRenderedImageUrl() {
return renderedImageUrl;
return renderedImageUrl;
}
public void setRenderedImageUrl(String renderedImageUrl) {
this.renderedImageUrl = renderedImageUrl;
this.renderedImageUrl = renderedImageUrl;
}
public String getRenderedLinkUrl() {
return renderedLinkUrl;
return renderedLinkUrl;
}
public void setRenderedLinkUrl(String renderedLinkUrl) {
this.renderedLinkUrl = renderedLinkUrl;
this.renderedLinkUrl = renderedLinkUrl;
}
public BadgeKind getKind() {
return kind;
return kind;
}
public void setKind(BadgeKind kind) {
this.kind = kind;
this.kind = kind;
}
@Override
public String toString() {
return (JacksonJson.toJsonString(this));
return (JacksonJson.toJsonString(this));
}
}
......@@ -11,6 +11,9 @@ public class Branch {
private Boolean merged;
private String name;
private Boolean isProtected;
private Boolean isDefault;
private Boolean canPush;
private String webUrl;
public Commit getCommit() {
return commit;
......@@ -60,6 +63,30 @@ public class Branch {
this.isProtected = isProtected;
}
public Boolean getDefault() {
return isDefault;
}
public void setDefault(Boolean isDefault) {
this.isDefault = isDefault;
}
public Boolean getCanPush() {
return canPush;
}
public void setCanPush(Boolean canPush) {
this.canPush = canPush;
}
public String getWebUrl() {
return webUrl;
}
public void setWebUrl(String webUrl) {
this.webUrl = webUrl;
}
public static final boolean isValid(Branch branch) {
return (branch != null && branch.getName() != null);
}
......@@ -80,11 +107,23 @@ public class Branch {
return this;
}
/**
* Set the merged attribute
* @param merged
* @deprecated Use {@link #withMerged(Boolean)} instead
* @return Current branch instance
*/
@Deprecated
public Branch withDerged(Boolean merged) {
this.merged = merged;
return this;
}
public Branch withMerged(Boolean merged) {
this.merged = merged;
return this;
}
public Branch withName(String name) {
this.name = name;
return this;
......
package org.gitlab4j.api.models;
import java.util.Date;
import org.gitlab4j.api.Constants;
import org.gitlab4j.api.GitLabApiForm;
import org.gitlab4j.api.Constants.DeploymentOrderBy;
import org.gitlab4j.api.Constants.DeploymentStatus;
import org.gitlab4j.api.Constants.SortOrder;
import org.gitlab4j.api.utils.ISO8601;
import com.fasterxml.jackson.annotation.JsonIgnore;
public class DeploymentFilter {
/**
* Return deployments ordered by either one of id, iid, created_at, updated_at or ref fields. Default is id.
*/
private DeploymentOrderBy orderBy;
/**
* Return deployments sorted in asc or desc order. Default is asc.
*/
private SortOrder sortOrder;
/**
* Return deployments updated after the specified date. Expected in ISO 8601 format (2019-03-15T08:00:00Z).
*/
private Date finishedAfter;
/**
* Return deployments updated before the specified date. Expected in ISO 8601 format (2019-03-15T08:00:00Z).
*/
private Date finishedBefore;
/**
* The name of the environment to filter deployments by.
*/
private String environment;
/**
* The status to filter deployments by.
*/
private DeploymentStatus status;
public DeploymentOrderBy getOrderBy() {
return orderBy;
}
public void setOrderBy(DeploymentOrderBy orderBy) {
this.orderBy = orderBy;
}
public SortOrder getSortOrder() {
return sortOrder;
}
public void setSortOrder(SortOrder sortOrder) {
this.sortOrder = sortOrder;
}
public Date getFinishedAfter() {
return finishedAfter;
}
public void setFinishedAfter(Date finishedAfter) {
this.finishedAfter = finishedAfter;
}
public Date getFinishedBefore() {
return finishedBefore;
}
public void setFinishedBefore(Date finishedBefore) {
this.finishedBefore = finishedBefore;
}
public String getEnvironment() {
return environment;
}
public void setEnvironment(String environment) {
this.environment = environment;
}
public DeploymentStatus getStatus() {
return status;
}
public void setStatus(DeploymentStatus status) {
this.status = status;
}
public DeploymentFilter withOrderBy(DeploymentOrderBy orderBy) {
this.orderBy = orderBy;
return (this);
}
public DeploymentFilter withSortOrder(SortOrder sortOrder) {
this.sortOrder = sortOrder;
return (this);
}
public DeploymentFilter withFinishedAfter(Date finishedAfter) {
this.finishedAfter = finishedAfter;
return (this);
}
public DeploymentFilter withFinishedBefore(Date finishedBefore) {
this.finishedBefore = finishedBefore;
return (this);
}
public DeploymentFilter withEnvironment(String environment) {
this.environment = environment;
return (this);
}
public DeploymentFilter withStatus(DeploymentStatus status) {
this.status = status;
return (this);
}
@JsonIgnore
public GitLabApiForm getQueryParams(int page, int perPage) {
return (getQueryParams()
.withParam(Constants.PAGE_PARAM, page)
.withParam(Constants.PER_PAGE_PARAM, perPage));
}
@JsonIgnore
public GitLabApiForm getQueryParams() {
return (new GitLabApiForm()
.withParam("order_by", orderBy)
.withParam("sort", sortOrder)
.withParam("finished_after", ISO8601.toString(finishedAfter, false))
.withParam("finished_before", ISO8601.toString(finishedBefore, false))
.withParam("environment", environment)
.withParam("status", status));
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment