Skip to content

/AWS1/CL_GLU=>GETWORKFLOWRUNS()

About GetWorkflowRuns

Retrieves metadata for all runs of a given workflow.

Method Signature

IMPORTING

Required arguments:

iv_name TYPE /AWS1/GLUNAMESTRING /AWS1/GLUNAMESTRING

Name of the workflow whose metadata of runs should be returned.

Optional arguments:

iv_includegraph TYPE /AWS1/GLUNULLABLEBOOLEAN /AWS1/GLUNULLABLEBOOLEAN

Specifies whether to include the workflow graph in response or not.

iv_nexttoken TYPE /AWS1/GLUGENERICSTRING /AWS1/GLUGENERICSTRING

The maximum size of the response.

iv_maxresults TYPE /AWS1/GLUPAGESIZE /AWS1/GLUPAGESIZE

The maximum number of workflow runs to be included in the response.

RETURNING

oo_output TYPE REF TO /aws1/cl_glugetworkflowrunsrsp /AWS1/CL_GLUGETWORKFLOWRUNSRSP

Domain /AWS1/RT_ACCOUNT_ID
Primitive Type NUMC

Examples

Syntax Example

This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.

DATA(lo_result) = lo_client->/aws1/if_glu~getworkflowruns(
  iv_includegraph = ABAP_TRUE
  iv_maxresults = 123
  iv_name = |string|
  iv_nexttoken = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  LOOP AT lo_result->get_runs( ) into lo_row.
    lo_row_1 = lo_row.
    IF lo_row_1 IS NOT INITIAL.
      lv_namestring = lo_row_1->get_name( ).
      lv_idstring = lo_row_1->get_workflowrunid( ).
      lv_idstring = lo_row_1->get_previousrunid( ).
      LOOP AT lo_row_1->get_workflowrunproperties( ) into ls_row_2.
        lv_key = ls_row_2-key.
        lo_value = ls_row_2-value.
        IF lo_value IS NOT INITIAL.
          lv_genericstring = lo_value->get_value( ).
        ENDIF.
      ENDLOOP.
      lv_timestampvalue = lo_row_1->get_startedon( ).
      lv_timestampvalue = lo_row_1->get_completedon( ).
      lv_workflowrunstatus = lo_row_1->get_status( ).
      lv_errorstring = lo_row_1->get_errormessage( ).
      lo_workflowrunstatistics = lo_row_1->get_statistics( ).
      IF lo_workflowrunstatistics IS NOT INITIAL.
        lv_integervalue = lo_workflowrunstatistics->get_totalactions( ).
        lv_integervalue = lo_workflowrunstatistics->get_timeoutactions( ).
        lv_integervalue = lo_workflowrunstatistics->get_failedactions( ).
        lv_integervalue = lo_workflowrunstatistics->get_stoppedactions( ).
        lv_integervalue = lo_workflowrunstatistics->get_succeededactions( ).
        lv_integervalue = lo_workflowrunstatistics->get_runningactions( ).
        lv_integervalue = lo_workflowrunstatistics->get_erroredactions( ).
        lv_integervalue = lo_workflowrunstatistics->get_waitingactions( ).
      ENDIF.
      lo_workflowgraph = lo_row_1->get_graph( ).
      IF lo_workflowgraph IS NOT INITIAL.
        LOOP AT lo_workflowgraph->get_nodes( ) into lo_row_3.
          lo_row_4 = lo_row_3.
          IF lo_row_4 IS NOT INITIAL.
            lv_nodetype = lo_row_4->get_type( ).
            lv_namestring = lo_row_4->get_name( ).
            lv_namestring = lo_row_4->get_uniqueid( ).
            lo_triggernodedetails = lo_row_4->get_triggerdetails( ).
            IF lo_triggernodedetails IS NOT INITIAL.
              lo_trigger = lo_triggernodedetails->get_trigger( ).
              IF lo_trigger IS NOT INITIAL.
                lv_namestring = lo_trigger->get_name( ).
                lv_namestring = lo_trigger->get_workflowname( ).
                lv_idstring = lo_trigger->get_id( ).
                lv_triggertype = lo_trigger->get_type( ).
                lv_triggerstate = lo_trigger->get_state( ).
                lv_descriptionstring = lo_trigger->get_description( ).
                lv_genericstring = lo_trigger->get_schedule( ).
                LOOP AT lo_trigger->get_actions( ) into lo_row_5.
                  lo_row_6 = lo_row_5.
                  IF lo_row_6 IS NOT INITIAL.
                    lv_namestring = lo_row_6->get_jobname( ).
                    LOOP AT lo_row_6->get_arguments( ) into ls_row_7.
                      lv_key_1 = ls_row_7-key.
                      lo_value_1 = ls_row_7-value.
                      IF lo_value_1 IS NOT INITIAL.
                        lv_genericstring = lo_value_1->get_value( ).
                      ENDIF.
                    ENDLOOP.
                    lv_timeout = lo_row_6->get_timeout( ).
                    lv_namestring = lo_row_6->get_securityconfiguration( ).
                    lo_notificationproperty = lo_row_6->get_notificationproperty( ).
                    IF lo_notificationproperty IS NOT INITIAL.
                      lv_notifydelayafter = lo_notificationproperty->get_notifydelayafter( ).
                    ENDIF.
                    lv_namestring = lo_row_6->get_crawlername( ).
                  ENDIF.
                ENDLOOP.
                lo_predicate = lo_trigger->get_predicate( ).
                IF lo_predicate IS NOT INITIAL.
                  lv_logical = lo_predicate->get_logical( ).
                  LOOP AT lo_predicate->get_conditions( ) into lo_row_8.
                    lo_row_9 = lo_row_8.
                    IF lo_row_9 IS NOT INITIAL.
                      lv_logicaloperator = lo_row_9->get_logicaloperator( ).
                      lv_namestring = lo_row_9->get_jobname( ).
                      lv_jobrunstate = lo_row_9->get_state( ).
                      lv_namestring = lo_row_9->get_crawlername( ).
                      lv_crawlstate = lo_row_9->get_crawlstate( ).
                    ENDIF.
                  ENDLOOP.
                ENDIF.
                lo_eventbatchingcondition = lo_trigger->get_eventbatchingcondition( ).
                IF lo_eventbatchingcondition IS NOT INITIAL.
                  lv_batchsize = lo_eventbatchingcondition->get_batchsize( ).
                  lv_batchwindow = lo_eventbatchingcondition->get_batchwindow( ).
                ENDIF.
              ENDIF.
            ENDIF.
            lo_jobnodedetails = lo_row_4->get_jobdetails( ).
            IF lo_jobnodedetails IS NOT INITIAL.
              LOOP AT lo_jobnodedetails->get_jobruns( ) into lo_row_10.
                lo_row_11 = lo_row_10.
                IF lo_row_11 IS NOT INITIAL.
                  lv_idstring = lo_row_11->get_id( ).
                  lv_attemptcount = lo_row_11->get_attempt( ).
                  lv_idstring = lo_row_11->get_previousrunid( ).
                  lv_namestring = lo_row_11->get_triggername( ).
                  lv_namestring = lo_row_11->get_jobname( ).
                  lv_jobmode = lo_row_11->get_jobmode( ).
                  lv_nullableboolean = lo_row_11->get_jobrunqueuingenabled( ).
                  lv_timestampvalue = lo_row_11->get_startedon( ).
                  lv_timestampvalue = lo_row_11->get_lastmodifiedon( ).
                  lv_timestampvalue = lo_row_11->get_completedon( ).
                  lv_jobrunstate = lo_row_11->get_jobrunstate( ).
                  LOOP AT lo_row_11->get_arguments( ) into ls_row_7.
                    lv_key_1 = ls_row_7-key.
                    lo_value_1 = ls_row_7-value.
                    IF lo_value_1 IS NOT INITIAL.
                      lv_genericstring = lo_value_1->get_value( ).
                    ENDIF.
                  ENDLOOP.
                  lv_errorstring = lo_row_11->get_errormessage( ).
                  LOOP AT lo_row_11->get_predecessorruns( ) into lo_row_12.
                    lo_row_13 = lo_row_12.
                    IF lo_row_13 IS NOT INITIAL.
                      lv_namestring = lo_row_13->get_jobname( ).
                      lv_idstring = lo_row_13->get_runid( ).
                    ENDIF.
                  ENDLOOP.
                  lv_integervalue = lo_row_11->get_allocatedcapacity( ).
                  lv_executiontime = lo_row_11->get_executiontime( ).
                  lv_timeout = lo_row_11->get_timeout( ).
                  lv_nullabledouble = lo_row_11->get_maxcapacity( ).
                  lv_workertype = lo_row_11->get_workertype( ).
                  lv_nullableinteger = lo_row_11->get_numberofworkers( ).
                  lv_namestring = lo_row_11->get_securityconfiguration( ).
                  lv_genericstring = lo_row_11->get_loggroupname( ).
                  lo_notificationproperty = lo_row_11->get_notificationproperty( ).
                  IF lo_notificationproperty IS NOT INITIAL.
                    lv_notifydelayafter = lo_notificationproperty->get_notifydelayafter( ).
                  ENDIF.
                  lv_glueversionstring = lo_row_11->get_glueversion( ).
                  lv_nullabledouble = lo_row_11->get_dpuseconds( ).
                  lv_executionclass = lo_row_11->get_executionclass( ).
                  lv_maintenancewindow = lo_row_11->get_maintenancewindow( ).
                  lv_namestring = lo_row_11->get_profilename( ).
                  lv_orchestrationmessagestr = lo_row_11->get_statedetail( ).
                ENDIF.
              ENDLOOP.
            ENDIF.
            lo_crawlernodedetails = lo_row_4->get_crawlerdetails( ).
            IF lo_crawlernodedetails IS NOT INITIAL.
              LOOP AT lo_crawlernodedetails->get_crawls( ) into lo_row_14.
                lo_row_15 = lo_row_14.
                IF lo_row_15 IS NOT INITIAL.
                  lv_crawlstate = lo_row_15->get_state( ).
                  lv_timestampvalue = lo_row_15->get_startedon( ).
                  lv_timestampvalue = lo_row_15->get_completedon( ).
                  lv_descriptionstring = lo_row_15->get_errormessage( ).
                  lv_loggroup = lo_row_15->get_loggroup( ).
                  lv_logstream = lo_row_15->get_logstream( ).
                ENDIF.
              ENDLOOP.
            ENDIF.
          ENDIF.
        ENDLOOP.
        LOOP AT lo_workflowgraph->get_edges( ) into lo_row_16.
          lo_row_17 = lo_row_16.
          IF lo_row_17 IS NOT INITIAL.
            lv_namestring = lo_row_17->get_sourceid( ).
            lv_namestring = lo_row_17->get_destinationid( ).
          ENDIF.
        ENDLOOP.
      ENDIF.
      lo_startingeventbatchcondi = lo_row_1->get_startingeventbatchcond( ).
      IF lo_startingeventbatchcondi IS NOT INITIAL.
        lv_nullableinteger = lo_startingeventbatchcondi->get_batchsize( ).
        lv_nullableinteger = lo_startingeventbatchcondi->get_batchwindow( ).
      ENDIF.
    ENDIF.
  ENDLOOP.
  lv_genericstring = lo_result->get_nexttoken( ).
ENDIF.