Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Die Implementierung der Operation GetStatus ist Implementation of the GetStatus operation is optional.

Die Operation GetStatus kann innerhalb jeder beliebigen Transaktion angewendet werden, um den Status der Transaktion zu ermitteln. Zur Erinnerung: Eine Transaktion wird als endlicher Automat modelliert, die jeweiligen Zustände dieses Automaten sind mit den Zahlen 1 bis 199 bezeichnet, wobei 1 der Startzustand ist.

Die Anfrage in der GetStatus-Operation ist das Element vct:GetStatusRequest. Dieses ist vom Typ vct:RequestType. Die Antwort ist das Element vct:GetStatusResponse. Dieses erweitert den Typ vct:ResponseType um das Element vct:TransactionStatus vom Typ vct:TransactionStatusType, welches beliebig oft wiederholt werden kann. Dieses Element ist eine Folge bestehend aus den Elementen vct:TransactionId (Typ: xsd:normalizedString) und dem Element vct:StatusCode vom Typ vct:StatusCodeType. Dieser Typ ist eine Einschränkung von xsd:integer auf die Zahlen 1 bis 199.

Regel: GetStatus.

...

Wird in der Anfrage eine TransactionID übermittelt und gibt es hierzu eine Transaktionsinstanz, so enthält die Antwort den ResponseCode 200 und ein Element TransactionStatus mit dieser TransactionId und dem aktuellen Status der Transaktionsinstanz. Falls es keine Transaktionsinstanz gibt, wo wird der ResponseCode 420 zurückgeliefert.

...

Wird in der Anfrage keine TransactionID übermittelt, so ermittelt der Server alle Transaktionsinstanzen, deren Transaktionskontext hinsichtlich BuyersID mit der Anfrage übereinstimmen. Für jede dieser Transaktionsinstanzen wird ein Element TransactionStatus in die Antwort eingefügt, das die TransactionId und den Status dieser Transaktionsinstanz enthält. Der ResponseCode ist 200.

...

The GetStatus operation can be used within any transaction to determine the transaction's status. Reminder: A transaction is modelled as a finite-state machine whose respective states are represented by the numbers 1 to 199, where 1 is the initial state.

The request in the GetStatus operation is the element vct:GetStatusRequest. It is of type vct:RequestType. The response is the element vct:GetStatusResponse. It extends the type vct:ResponseType with the element vct:TransactionStatus of type vct:TransactionStatusType, which can be repeated as often as necessary. This element is a sequence consisting of the elements vct:TransactionId (type: xsd:normalizedString) and the element vct:StatusCode of type vct:StatusCodeType. This type is a limitation of xsd:integer to the numbers 1 to 199.

Rule: GetStatus.

  1. If a transactionID is submitted in the request, and there is a transaction instance in this connection, the response contains ResponseCode 200, a TransactionStatus element with this TransactionID, and the transaction instance's current status. If there is no transaction instance, ResponseCode 420 is returned.

  2. If no transactionID is submitted in the request, the server determines all transaction instances whose transaction context matches the request with respect to BuyersID. For each of these transaction instances, the response includes a TransactionStatus element indicating the TransactionID and status of the respective transaction instance. The ResponseCode is 200.

  3. If the client's request is not appropriate for determining which operation should be executed, the server can return ResponseCode 400 or 405 with a GetStatusResponse element. Alternatively, http error code 404 can be returned.