use of com.hubspot.singularity.SingularityPendingRequestParent in project Singularity by HubSpot.
the class SingularityClient method updateAuthorizedGroups.
public SingularityPendingRequestParent updateAuthorizedGroups(String requestId, SingularityUpdateGroupsRequest updateGroupsRequest) {
final Function<String, String> requestUri = (host) -> String.format(REQUEST_GROUPS_UPDATE_FORMAT, getApiBase(host), requestId);
final HttpResponse response = post(requestUri, String.format("update authorized groups of request %s", requestId), Optional.of(updateGroupsRequest));
return response.getAs(SingularityPendingRequestParent.class);
}
use of com.hubspot.singularity.SingularityPendingRequestParent in project Singularity by HubSpot.
the class SingularityClient method runSingularityRequest.
public SingularityPendingRequestParent runSingularityRequest(String requestId, Optional<SingularityRunNowRequest> runNowRequest) {
final Function<String, String> requestUri = (host) -> String.format(REQUEST_RUN_FORMAT, getApiBase(host), requestId);
final HttpResponse response = post(requestUri, String.format("run of request %s", requestId), runNowRequest);
return response.getAs(SingularityPendingRequestParent.class);
}
Aggregations