FW: Entity Sync

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

FW: Entity Sync

Nikita Shinde
Hey Sam,

 

Although, we can schedule the push and pull services at different times
through RecurrenceRule, there is still a possibility that push and pull
might run at the same time. To make sure this doesnt happen, you can write a
piece of code in both runPullEntitySync and runEntitySync services that
checks whether runEntitySync or runPullEntitySync service is running or not
through JobSandbox table. So when in runPullEntitySync, we check whether
runEntitySync service is running and if it is, we return an error and this
re-schedules runPullEntitySync service again for later.

 

This should make both services mutuallly exclusive. Its the first pull that
takes hours, but after that it should be quick enough. So scheduling push
pull service in a gap of 1-2 hours should work.

 

I am sure you must have referred this document -
http://docs.ofbiz.org/display/OFBIZ/Sync+Setup+Notes+and+Example but that
should be some information.

 

Also, on another note, I had an issue with Inventory when pushing data
across. The problem occurred when a new InventoryItem record was created on
POS. So now when that InventoryItem is created on MCS, it triggers an ECA
service 'createInventoryItemCheckSetAtpQoh' and this creates
InventoryItemDetail records again thus doubling the inventory as
InventoryItemDetail records for the same InventoryItem were being pushed as
well. I had to filter InventoryItemDetail records from the create records
list before push to avoid this problem.

 

 

Hope this helps,

Thanks,

 

Nikita Shinde

 

Amicon Technologies Pvt. Ltd., Mumbai, India.

India's No.1 OFBiz service provider

 

-----Original Message-----
From: Sam Hamilton [mailto:[hidden email]]
Sent: Wednesday, November 26, 2008 5:35 PM
To: [hidden email]
Subject: Entity Sync

 

Quick question - with the entity sync function can you run push and pull at
the same time?

I have a feeling that this is not a good idea but still trying to work out
how the sync works exactly.

 

We have it up and running between three locations.

We consider the master database in Hong Kong with remote servers in USA and
China.

 

Thanks

Sam=