:doc:`MainframeModernization <../../m2>` / Client / list_batch_job_executions

*************************
list_batch_job_executions
*************************



.. py:method:: MainframeModernization.Client.list_batch_job_executions(**kwargs)

  

  Lists historical, current, and scheduled batch job executions for a specific application.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/m2-2021-04-28/ListBatchJobExecutions>`_  


  **Request Syntax**
  ::

    response = client.list_batch_job_executions(
        applicationId='string',
        executionIds=[
            'string',
        ],
        jobName='string',
        maxResults=123,
        nextToken='string',
        startedAfter=datetime(2015, 1, 1),
        startedBefore=datetime(2015, 1, 1),
        status='Submitting'|'Holding'|'Dispatching'|'Running'|'Cancelling'|'Cancelled'|'Succeeded'|'Failed'|'Purged'|'Succeeded With Warning'
    )
    
  :type applicationId: string
  :param applicationId: **[REQUIRED]** 

    The unique identifier of the application.

    

  
  :type executionIds: list
  :param executionIds: 

    The unique identifier of each batch job execution.

    

  
    - *(string) --* 

    

  :type jobName: string
  :param jobName: 

    The name of each batch job execution.

    

  
  :type maxResults: integer
  :param maxResults: 

    The maximum number of batch job executions to return.

    

  
  :type nextToken: string
  :param nextToken: 

    A pagination token to control the number of batch job executions displayed in the list.

    

  
  :type startedAfter: datetime
  :param startedAfter: 

    The time after which the batch job executions started.

    

  
  :type startedBefore: datetime
  :param startedBefore: 

    The time before the batch job executions started.

    

  
  :type status: string
  :param status: 

    The status of the batch job executions.

    

  
  
  :rtype: dict
  :returns: 
    
    **Response Syntax**

    
    ::

      {
          'batchJobExecutions': [
              {
                  'applicationId': 'string',
                  'batchJobIdentifier': {
                      'fileBatchJobIdentifier': {
                          'fileName': 'string',
                          'folderPath': 'string'
                      },
                      'restartBatchJobIdentifier': {
                          'executionId': 'string',
                          'jobStepRestartMarker': {
                              'fromProcStep': 'string',
                              'fromStep': 'string',
                              'skip': True|False,
                              'stepCheckpoint': 123,
                              'toProcStep': 'string',
                              'toStep': 'string'
                          }
                      },
                      's3BatchJobIdentifier': {
                          'bucket': 'string',
                          'identifier': {
                              'fileName': 'string',
                              'scriptName': 'string'
                          },
                          'keyPrefix': 'string'
                      },
                      'scriptBatchJobIdentifier': {
                          'scriptName': 'string'
                      }
                  },
                  'endTime': datetime(2015, 1, 1),
                  'executionId': 'string',
                  'jobId': 'string',
                  'jobName': 'string',
                  'jobType': 'VSE'|'JES2'|'JES3',
                  'returnCode': 'string',
                  'startTime': datetime(2015, 1, 1),
                  'status': 'Submitting'|'Holding'|'Dispatching'|'Running'|'Cancelling'|'Cancelled'|'Succeeded'|'Failed'|'Purged'|'Succeeded With Warning'
              },
          ],
          'nextToken': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **batchJobExecutions** *(list) --* 

        Returns a list of batch job executions for an application.

        
        

        - *(dict) --* 

          A subset of the possible batch job attributes. Used in the batch job list.

          
          

          - **applicationId** *(string) --* 

            The unique identifier of the application that hosts this batch job.

            
          

          - **batchJobIdentifier** *(dict) --* 

            The unique identifier of this batch job.

            .. note::    This is a Tagged Union structure. Only one of the     following top level keys will be set: ``fileBatchJobIdentifier``, ``restartBatchJobIdentifier``, ``s3BatchJobIdentifier``, ``scriptBatchJobIdentifier``.     If a client receives an unknown member it will     set ``SDK_UNKNOWN_MEMBER`` as the top level key,     which maps to the name or tag of the unknown     member. The structure of ``SDK_UNKNOWN_MEMBER`` is     as follows::

                        'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}


          
            

            - **fileBatchJobIdentifier** *(dict) --* 

              Specifies a file associated with a specific batch job.

              
              

              - **fileName** *(string) --* 

                The file name for the batch job identifier.

                
              

              - **folderPath** *(string) --* 

                The relative path to the file name for the batch job identifier.

                
          
            

            - **restartBatchJobIdentifier** *(dict) --* 

              Specifies the required information for restart, including ``executionId`` and ``JobStepRestartMarker``.

              
              

              - **executionId** *(string) --* 

                The ``executionId`` from the ``StartBatchJob`` response when the job ran for the first time.

                
              

              - **jobStepRestartMarker** *(dict) --* 

                The step/procedure step information for a restart batch job operation.

                
                

                - **fromProcStep** *(string) --* 

                  The procedure step name that a batch job was restarted from.

                  
                

                - **fromStep** *(string) --* 

                  The step name that a batch job was restarted from.

                  
                

                - **skip** *(boolean) --* 

                  The step-level checkpoint timestamp (creation or last modification) for an Amazon Web Services Blu Age application batch job.

                  
                

                - **stepCheckpoint** *(integer) --* 

                  Skip selected step and issue a restart from immediate successor step for an Amazon Web Services Blu Age application batch job.

                  
                

                - **toProcStep** *(string) --* 

                  The procedure step name that a batch job was restarted to.

                  
                

                - **toStep** *(string) --* 

                  The step name that a batch job was restarted to.

                  
            
          
            

            - **s3BatchJobIdentifier** *(dict) --* 

              Specifies an Amazon S3 location that identifies the batch jobs that you want to run. Use this identifier to run ad hoc batch jobs.

              
              

              - **bucket** *(string) --* 

                The Amazon S3 bucket that contains the batch job definitions.

                
              

              - **identifier** *(dict) --* 

                Identifies the batch job definition. This identifier can also point to any batch job definition that already exists in the application or to one of the batch job definitions within the directory that is specified in ``keyPrefix``.

                .. note::    This is a Tagged Union structure. Only one of the     following top level keys will be set: ``fileName``, ``scriptName``.     If a client receives an unknown member it will     set ``SDK_UNKNOWN_MEMBER`` as the top level key,     which maps to the name or tag of the unknown     member. The structure of ``SDK_UNKNOWN_MEMBER`` is     as follows::

                                'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}


              
                

                - **fileName** *(string) --* 

                  The name of the file that contains the batch job definition.

                  
                

                - **scriptName** *(string) --* 

                  The name of the script that contains the batch job definition.

                  
            
              

              - **keyPrefix** *(string) --* 

                The key prefix that specifies the path to the folder in the S3 bucket that has the batch job definitions.

                
          
            

            - **scriptBatchJobIdentifier** *(dict) --* 

              A batch job identifier in which the batch job to run is identified by the script name.

              
              

              - **scriptName** *(string) --* 

                The name of the script containing the batch job definition.

                
          
        
          

          - **endTime** *(datetime) --* 

            The timestamp when this batch job execution ended.

            
          

          - **executionId** *(string) --* 

            The unique identifier of this execution of the batch job.

            
          

          - **jobId** *(string) --* 

            The unique identifier of a particular batch job.

            
          

          - **jobName** *(string) --* 

            The name of a particular batch job.

            
          

          - **jobType** *(string) --* 

            The type of a particular batch job execution.

            
          

          - **returnCode** *(string) --* 

            The batch job return code from either the Blu Age or Micro Focus runtime engines. For more information, see `Batch return codes <https://www.ibm.com/docs/en/was/8.5.5?topic=model-batch-return-codes>`__ in the *IBM WebSphere Application Server* documentation.

            
          

          - **startTime** *(datetime) --* 

            The timestamp when a particular batch job execution started.

            
          

          - **status** *(string) --* 

            The status of a particular batch job execution.

            
      
    
      

      - **nextToken** *(string) --* 

        A pagination token that's returned when the response doesn't contain all batch job executions.

        
  
  **Exceptions**
  
  *   :py:class:`MainframeModernization.Client.exceptions.ResourceNotFoundException`

  
  *   :py:class:`MainframeModernization.Client.exceptions.ThrottlingException`

  
  *   :py:class:`MainframeModernization.Client.exceptions.AccessDeniedException`

  
  *   :py:class:`MainframeModernization.Client.exceptions.ValidationException`

  
  *   :py:class:`MainframeModernization.Client.exceptions.InternalServerException`

  