cancel
Showing results for 
Search instead for 
Did you mean: 
Subscribe

Hi guys,

Has anyone worked with SAP Backend with SUP generating Native Applications on Android /ios Platform.

When we call the beginsynchronize() and synchronize() API if you would have debugged on the SAP Side you would have seen that after beginsynchronize() the data is called twice in the SAP Backend.

Has anyone encountered this thing or seen this stuff.

How to avoid this this.

Any suggestions.. Please help..

0 Likes
View Entire Topic
miltonc
Product and Topic Expert
Product and Topic Expert
0 Likes

Rakshit,

Are you calling both beginSynchronize AND synchronize ?

Or is the BAPI being called twice with just beginSynchronize...

Thanks !

rakshit_doshi
Active Contributor
0 Likes

Yes i am calling both but i even tried calling commenting the other one but still the BAPI is called twice.

When both are open it is called 4 times.

miltonc
Product and Topic Expert
Product and Topic Expert
0 Likes

You dont need to call both beginSynchronize and Synchronize in your code.

Synchronize is a blocking call.  While beginSynchronize is a non-blocking call. 

But it is strange that the same BAPI wrapper is called twice with a single call to beginSynchronize. 

miltonc
Product and Topic Expert
Product and Topic Expert
0 Likes

Need some more information to troubleshoot this issue.  And just to confirm.  Its the same BAPI thats being called twice with a single call to beginSynchronize. 

1.  Comment both calls to beginSynchronize and Synchronize.  Make sure your BAPI is never called.  Just want to make sure there is no other call elsewhere in your code that is causing the BAPI to be called. 

2.  Lets comment out one of the calls (for example, Synchronize) going forward.  So you should only have beginSynchronize.  What kind of operation is being done before you call beginSynchronize (Create, Update, Delete). 

3.  Is there anything in there that might be invalidating the cache ?

4.  Are you changing the personalization keys, sync params etc. in your code ?

5.  Are you deriving from the DefaultCallbackHandler and handling the events.  If so, are there any clues that you are seeing there...

6.  And if you can post a snippet of your code that calls beginSynchronize, that will be nice too. 

rakshit_doshi
Active Contributor
0 Likes

Hi,

What is the difference between non blocking and blocking call and what are the significance of both??

rakshit_doshi
Active Contributor
0 Likes

Hi Milton,

1.Can you confirm without begin Synchronize and Synchronize can the BAPI be called in any other way.??

2.With Synchronize or BeginSynchronize i am calling a Create Operation. Not the default create operation but i have defined an operation on the MBO of the type create as my BAPI takes a structure as an input rather than single values.

3. How do we determine whether the cache is being invalidated or not.

4. I am not using any personalization and Sync params while calling the MBO on which i am calling create  operation

5. Yes i am trying to read it from both, the Default Callback handler and as well querying the MBO using Query

6. Drop your email id. I will mail you the code snippet.

Thanks,

Rakshit Doshi

miltonc
Product and Topic Expert
Product and Topic Expert
0 Likes

Blocking call is a synchronous call.  You call the method and the method 'blocks' your main thread until the result is returned. 

Non-blocking call is asynchronous.  You call the method and you are free to do other stuff on your main thread. 

miltonc
Product and Topic Expert
Product and Topic Expert
0 Likes

Email me your code snippet at [email protected]

Former Member
0 Likes

Thank You Very Much !!