Show TOC

Background documentationProgramming with Sequences at the Provider Side Locate this document in the navigation structure

 

A sequence protocol object can be accessed at both the consumer and the provider side. The sequence protocol can display the current sequence object. It provides methods for reading and changing properties of a sequence, including properties that describe the status of the sequence. This is helpful above all in error situations.

If a service fails due to a time-restricted error (for example, an enqueue lock), then this process is retriggered (repeatedly). Calling the IS_LAST_TRY method can be used to find out if the current attempt to perform the service is the last retry attempt.

data:

  l_server_context type ref to if_ws_server_context,

  l_sequ_prot type ref to if_wsprotocol_sequence,

  l_sequence type ref to if_ws_server_sequence.

l_server_context = cl_proxy_access=>get_server_context( ).

l_sequ_prot ?= server_context->get_protocol( if_wsprotocol=>sequence ).

l_sequence = l_sequ_prot->get_server_sequence( ).

if l_sequence->is_last_retry( ) eq 'X'.

...

endif.