Retrying Submissions

Given a list of submission IDs, retry those submissions

Introduction

Until the submission status changes to COMPLETE, the RetrySubmission query can be used. This can be helpful if there are intermittent issues with a file, or a submission is stuck in PROCESSING.

RetrySubmission

Inputs

submission_ids: List[int] The given submission IDs to retry.

Outputs

retries: list[SubmissionRetry] List of of previous submission attempts containing the following information:

  • id: int a retry attempt ID
  • retryErrors: str errors on retry
  • submissionId: int the ID of the submission

Try It Out

You can try out RetrySubmission below.

from indico.queries import RetrySubmission

# submission id to retry, must be a list even if a single id is provided
submission_ids = [4]

retries = client.call(RetrySubmission(submission_ids=submission_ids))
package com.indico;

import com.indico.entity.Submission;

import com.indico.mutation.RetrySubmission;

import java.util.*;

public class main {

    public IndicoClient client;
    private static String token_path = "./indico_api_token.txt";
    private static String host  =  "mycluster.indico.io"
    private static Integer failed_submission_id = 1;

    public static void main(String args[]) throws Exception {

        
        IndicoConfig config = new IndicoConfig.Builder().host(host)
                .protocol("https")
                .tokenPath(token_path)
                .build();
        client = new IndicoKtorClient(config);
      
      	List<Integer> failed_ids = new ArrayList<Integer>();
      	failed_ids.add(failed_submission_id);
      
        RetrySubmission retrySubmissionQuery = client.retrySubmission();
      	retrySubmissionQuery.ids(failed_ids);
      	List<SubmissionRetries> retryResults = retrySubmissionQuery.execute();

      	System.out.println("Retried " +  retryResults.size() + " submissions");

        System.exit(0);
    }
}