Package org.eclipse.csi.codesign
Class SigningWorkflow
java.lang.Object
org.eclipse.csi.codesign.SigningWorkflow
Orchestrates the full signing workflow: submit an artifact → poll until a final status is
reached.
After a successful call to submitAndWait(java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.util.Map<java.lang.String, java.lang.String>, java.nio.file.Path), callers should download the signed artifact
via CodesignClient.downloadSignedArtifact(SigningRequestStatus, Path).
-
Constructor Summary
ConstructorsConstructorDescriptionSigningWorkflow(CodesignClient client, Duration pollInterval, Duration completionTimeout, Consumer<String> logger) Creates a workflow with an optional completion timeout.SigningWorkflow(CodesignClient client, Duration pollInterval, Consumer<String> logger) Creates a workflow that polls indefinitely (no completion deadline). -
Method Summary
-
Constructor Details
-
SigningWorkflow
Creates a workflow that polls indefinitely (no completion deadline).- Parameters:
client- the SignPath API clientpollInterval- how often to check signing statuslogger- consumer for informational progress messages;null= silent
-
SigningWorkflow
public SigningWorkflow(CodesignClient client, Duration pollInterval, Duration completionTimeout, Consumer<String> logger) Creates a workflow with an optional completion timeout.- Parameters:
client- the SignPath API clientpollInterval- how often to check signing statuscompletionTimeout- maximum time to wait for a final status;null= no limitlogger- consumer for informational progress messages;null= silent
-
-
Method Details
-
submitAndWait
public SigningRequestStatus submitAndWait(String projectId, String signingPolicy, String artifactConfiguration, String description, Map<String, String> parameters, Path artifactPath) throws CodesignException, IOExceptionSubmits an artifact for signing and polls until a final status is reached.- Parameters:
projectId- SignPath project slugsigningPolicy- SignPath signing policy slugartifactConfiguration- optional artifact configuration slug; may benulldescription- optional signing request description; may benullparameters- optional custom key/value parameters; may benullartifactPath- path to the artifact to sign- Returns:
- the final (terminal) signing request status
- Throws:
CodesignException- if the API fails or the deadline is exceeded before a final status is reachedIOException- on transport or thread-interruption errors
-