Class ResultResource
java.lang.Object
com.atlassian.bamboo.plugins.rest.resource.ResultResource
@Path("result")
@Consumes({"application/xml","application/json"})
@Produces({"application/xml","application/json"})
@Singleton
public class ResultResource
extends Object
Provide build results information.
Available for anonymous and authenticated users, however proper permissions are enforced
-
Constructor Summary
ConstructorDescriptionResultResource
(BambooPermissionManager bambooPermissionManager, ResultService resultService, FeatureManager featureManager, RestAuthenticationContext restAuthenticationContext) -
Method Summary
Modifier and TypeMethodDescriptionvoid
addBuildComment
(String projectKey, String buildKey, String buildNumber, CreateCommentRequest comment, javax.ws.rs.core.UriInfo uriInfo) javax.ws.rs.core.Response
addBuildLabel
(String projectKey, String buildKey, String buildNumber, RestBuildLabel label, javax.ws.rs.core.UriInfo uriInfo) getBranchHistory
(String projectKey, String buildKey, String branchName, String expandParam, boolean favouriteParam, String labelParam, String issueKeyParam, boolean allStatesParam, String lifecycleStateParam, boolean continuableParam, boolean buildStateParam, int startIndexParam, int maxResultsParam, javax.ws.rs.core.UriInfo uriInfo) getBuild
(String projectKey, String buildKey, String buildNumber, String expandParam, boolean showBuildPositions, javax.ws.rs.core.UriInfo uriInfo) getBuildAlias
(String projectKey, String buildKey, String buildNumber, String expandParam, javax.ws.rs.core.UriInfo uriInfo) getBuildComments
(String projectKey, String buildKey, String buildNumber, javax.ws.rs.core.UriInfo uriInfo) getBuildHistory
(String projectKey, String buildKey, String expandParam, boolean favouriteParam, String labelParam, String issueKeyParam, boolean allStatesParam, String lifecycleStateParam, boolean continuableParam, boolean buildStateParam, int startIndexParam, int maxResultsParam, javax.ws.rs.core.UriInfo uriInfo) getBuildLabels
(String projectKey, String buildKey, String buildNumber, javax.ws.rs.core.UriInfo uriInfo) getBuildResultsForChangeset
(String changesetId, javax.ws.rs.core.UriInfo uriInfo) getBuildResultsForCheckoutChangeset
(String changesetId, javax.ws.rs.core.UriInfo uriInfo) getLatestBuildResults
(String expandParam, boolean favouriteParam, String labelParam, String issueKeyParam, boolean allStatesParam, String lifecycleStateParam, boolean continuableParam, String buildStateParam, int startIndexParam, int maxResultsParam, javax.ws.rs.core.UriInfo uriInfo) getLatestBuildResultsForProject
(String projectKey, String expandParam, boolean favouriteParam, String labelParam, String issueKeyParam, boolean allStatesParam, String lifecycleStateParam, boolean continuableParam, String buildStateParam, int startIndexParam, int maxResultsParam, javax.ws.rs.core.UriInfo uriInfo) getResultStatus
(String projectKey, String buildKey, String buildNumber, javax.ws.rs.core.UriInfo uriInfo) javax.ws.rs.core.Response
removeBuildComment
(String projectKey, String buildKey, String buildNumber, long commentId, javax.ws.rs.core.UriInfo uriInfo) javax.ws.rs.core.Response
removeBuildLabel
(String projectKey, String buildKey, String buildNumber, String labelName, javax.ws.rs.core.UriInfo uriInfo)
-
Constructor Details
-
ResultResource
@Inject public ResultResource(BambooPermissionManager bambooPermissionManager, ResultService resultService, FeatureManager featureManager, RestAuthenticationContext restAuthenticationContext)
-
-
Method Details
-
getLatestBuildResults
@GET public RestResults getLatestBuildResults(@QueryParam("expand") String expandParam, @QueryParam("favourite") boolean favouriteParam, @QueryParam("label") String labelParam, @QueryParam("issueKey") String issueKeyParam, @QueryParam("includeAllStates") boolean allStatesParam, @QueryParam("lifeCycleState") String lifecycleStateParam, @QueryParam("continuable") boolean continuableParam, @QueryParam("buildstate") String buildStateParam, @QueryParam("start-index") int startIndexParam, @QueryParam("max-results") int maxResultsParam, @Context javax.ws.rs.core.UriInfo uriInfo) -
getLatestBuildResultsForProject
@GET @Path("{projectKey : ([^-/]+)}") public RestResults getLatestBuildResultsForProject(@PathParam("projectKey") String projectKey, @QueryParam("expand") String expandParam, @QueryParam("favourite") boolean favouriteParam, @QueryParam("label") String labelParam, @QueryParam("issueKey") String issueKeyParam, @QueryParam("includeAllStates") boolean allStatesParam, @QueryParam("lifeCycleState") String lifecycleStateParam, @QueryParam("continuable") boolean continuableParam, @QueryParam("buildstate") String buildStateParam, @QueryParam("start-index") int startIndexParam, @QueryParam("max-results") int maxResultsParam, @Context javax.ws.rs.core.UriInfo uriInfo) -
getBuildResultsForChangeset
@GET @Path("byChangeset/{csid}") public RestResults getBuildResultsForChangeset(@PathParam("csid") String changesetId, @Context javax.ws.rs.core.UriInfo uriInfo) -
getBuildResultsForCheckoutChangeset
@GET @Path("byCheckoutChangeset/{csid}") public RestResults getBuildResultsForCheckoutChangeset(@PathParam("csid") String changesetId, @Context javax.ws.rs.core.UriInfo uriInfo) -
getBuildHistory
@GET @Path("{projectKey : ([^-]+)}-{buildKey}") public RestResults getBuildHistory(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @QueryParam("expand") String expandParam, @QueryParam("favourite") boolean favouriteParam, @QueryParam("label") String labelParam, @QueryParam("issueKey") String issueKeyParam, @QueryParam("includeAllStates") boolean allStatesParam, @QueryParam("lifeCycleState") String lifecycleStateParam, @QueryParam("continuable") boolean continuableParam, @QueryParam("buildstate") boolean buildStateParam, @QueryParam("start-index") int startIndexParam, @QueryParam("max-results") int maxResultsParam, @Context javax.ws.rs.core.UriInfo uriInfo) -
getBranchHistory
@GET @Path("{projectKey : ([^-/]+)}-{buildKey}/branch/{branchName}") public RestResults getBranchHistory(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @PathParam("branchName") String branchName, @QueryParam("expand") String expandParam, @QueryParam("favourite") boolean favouriteParam, @QueryParam("label") String labelParam, @QueryParam("issueKey") String issueKeyParam, @QueryParam("includeAllStates") boolean allStatesParam, @QueryParam("lifeCycleState") String lifecycleStateParam, @QueryParam("continuable") boolean continuableParam, @QueryParam("buildstate") boolean buildStateParam, @QueryParam("start-index") int startIndexParam, @QueryParam("max-results") int maxResultsParam, @Context javax.ws.rs.core.UriInfo uriInfo) -
getBuild
@GET @Path("{projectKey : ([^-/]+)}-{buildKey}-{buildNumber : ([0-9]+)|(latest)}") public Result getBuild(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @PathParam("buildNumber") String buildNumber, @QueryParam("expand") String expandParam, @QueryParam("buildPositions") boolean showBuildPositions, @Context javax.ws.rs.core.UriInfo uriInfo) -
getBuildAlias
@GET @Path("{projectKey : ([^-/]+)}-{buildKey}/{buildNumber : ([0-9]+)|(latest)}") public Result getBuildAlias(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @PathParam("buildNumber") String buildNumber, @QueryParam("expand") String expandParam, @Context javax.ws.rs.core.UriInfo uriInfo) -
getBuildComments
@GET @Path("{projectKey : ([^-/]+)}-{buildKey}-{buildNumber}/comment") public RestComments getBuildComments(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @PathParam("buildNumber") String buildNumber, @Context javax.ws.rs.core.UriInfo uriInfo) -
addBuildComment
@POST @Path("{projectKey : ([^-/]+)}-{buildKey}-{buildNumber}/comment") public void addBuildComment(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @PathParam("buildNumber") String buildNumber, CreateCommentRequest comment, @Context javax.ws.rs.core.UriInfo uriInfo) -
removeBuildComment
@DELETE @Path("{projectKey : ([^-/]+)}-{buildKey}-{buildNumber}/comment/{commentId}") public javax.ws.rs.core.Response removeBuildComment(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @PathParam("buildNumber") String buildNumber, @PathParam("commentId") long commentId, @Context javax.ws.rs.core.UriInfo uriInfo) -
getBuildLabels
@GET @Path("{projectKey : ([^-/]+)}-{buildKey}-{buildNumber}/label") public RestBuildLabels getBuildLabels(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @PathParam("buildNumber") String buildNumber, @Context javax.ws.rs.core.UriInfo uriInfo) -
addBuildLabel
@POST @Path("{projectKey : ([^-/]+)}-{buildKey}-{buildNumber}/label") public javax.ws.rs.core.Response addBuildLabel(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @PathParam("buildNumber") String buildNumber, RestBuildLabel label, @Context javax.ws.rs.core.UriInfo uriInfo) -
removeBuildLabel
@DELETE @Path("{projectKey : ([^-/]+)}-{buildKey}-{buildNumber}/label/{labelName}") public javax.ws.rs.core.Response removeBuildLabel(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @PathParam("buildNumber") String buildNumber, @PathParam("labelName") String labelName, @Context javax.ws.rs.core.UriInfo uriInfo) throws Exception - Throws:
Exception
-
getResultStatus
@GET @Path("/status/{projectKey : ([^-/]+)}-{buildKey}-{buildNumber : ([0-9]+)}") public RestResultStatus getResultStatus(@PathParam("projectKey") String projectKey, @PathParam("buildKey") String buildKey, @PathParam("buildNumber") String buildNumber, @Context javax.ws.rs.core.UriInfo uriInfo)
-