ASF GitHub Bot commented on SCB-300:

zhfeng commented on issue #173: [SCB-300] acceptance test for @Compensable 
event timeout
   what is the purpose of this test ? I think it would like to show the 
scenario that when the saga transaction is timeout, the alpha server call the 
compensate method is failed and will retry ?
   The booking service looks like the following steps:
   1) saga start
   2) call the car booking
   3) call the hotel booking
   4) postBooking wait 10s until the transaction timeout (injected by the 
byteman rules)
   5) return failure message with the information of timeout ( I think it is 
still an issue when we are sending the SAGA_ENDED in the 
 I think we should check the return value and throws the Exception if the 
transaction is timeout. Also the alpha server handles the message in 
 currently it only check if the transaction is aborted and I think it should 
also check if the transaction is timeout.
   For this test, if we want to simulate the alpha server retries the 
compensate method when the transaction is timeout, I think it would like to use 
the byteman rule in the cancel method of HotelBooking 
   RULE create counter
   CLASS org.apache.servicecomb.saga.demo.pack.hotel.HotelBooking
   METHOD <init>
   DO createCountDown($0, 1)
   RULE throws the exception when calling the cancel method at the first time
   CLASS org.apache.servicecomb.saga.demo.pack.hotel.HotelBookingService
   MEHTOD cancel(HotelBooking)
   IF !countDown($0)
   DO throw exception

This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:

> [pack] acceptance tests of transaction timeout and retry
> --------------------------------------------------------
>                 Key: SCB-300
>                 URL: https://issues.apache.org/jira/browse/SCB-300
>             Project: Apache ServiceComb
>          Issue Type: Sub-task
>          Components: Saga
>            Reporter: Yin Xiang
>            Assignee: Zheng Feng
>            Priority: Major
>             Fix For: saga-0.2.0

This message was sent by Atlassian JIRA

Reply via email to