Skip to Content
avatar image
Former Member

How to implement Pessimistic lock in SAP Fiori through OData ?

Hi experts,

Same functionality is working in S4 Hana standard applications, How we can implement for our client ? I already suggested E-Tag, but client want pessimistic lock concept only. we stuck because of this thing and no answer to give.

Regards,

Rajendra Sharma

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • avatar image
    Former Member
    Nov 28, 2017 at 03:49 PM

    We have similar kind of requirement, As optimistic lock( Etag- via time stamp or Hashalgo) is just temporary control concurrency by holding data for time being not locking row, but if change request is coming from mobile device, same time some one is changing via ecc so in this case pessimistic lock seems good solution. as in REST architecture there is everything state less, making stateful also work with limitation of 120 second.

    we can call enque function directly in gateway and send error message if it is locked, and perform change operation, only limitation I found here is turnaround time.

    Regards

    Add comment
    10|10000 characters needed characters exceeded

  • Jan 03 at 08:19 AM

    Hello,

    I would suggest to use Soft State mode. Look at this link : How to use Soft-State support for OData services

    In that mode, you will be able to set a lcok for a while (depending on your timeout parameter). it is not a very streigth solution, but it's working. Do not forget to kill the session when the user leave the Business Object.

    Regards,

    Joseph

    Add comment
    10|10000 characters needed characters exceeded