Live Sync custom registers and blocks.
11-21-22
Operating system: macOS
Tested on:
Standard ERP 2022-10-22
Version: 85480640 for Mac OS
Last Published: 11-16-22 13:03:14, Package number 713003

Hello.

Is it possible to enable live sync custom registers and blocks defined in datadef.hal between server-client.


I see that registers like IVCashVc, that used in Live Sync mode, has next code rows in datadefs:
NewAutosyncRegister(kSyncDirectionToClient,true);
NewAutosyncBlock(kSyncDirectionToClient);
NewAutosyncRegister(kSyncDirectionToServer,true);
but this rows in custom registers has no affect for sync for me. I need to copy block with settings from server to livesync client, sync one register from server to client, and sync one register back from client to server.
Brittany McGrath
11-30-22
Hello, a Product Manager is looking into this and we hope to have an update to your post soon.
Thank you.
Simone M.
12-7-22
Hi,
I do confirm that:
- NewAutosyncRegister(kSyncDirectionFull,true);
- NewAutosyncBlock(kSyncDirectionToClient);

Are the functions to be used.
If that is not working as expected (which means data not synced), then it's a bug that has to be reported.
12-8-22
Thanks. I will test it and if not works then create bug report.
Jennifer
12-13-22
Hey can you confirm all is working as should for you?
12-13-22
Hi, Jennifer.
No, not working. Was create bug report: https://www.hansaworld.com/en/issue-tracking/view/1940289399
I solved sync with another way, but this is much more coding and I would like that this works in native live sync mechanism.
Paul Timms
12-19-22
Have you also added SynchronizationIndex; to the main index for those custom registers?

Also check VcRecordShouldBeSynchronised in source code.
12-19-22
Hello.
SynchronizationIndex; not working with NewAutosyncRegister(kSyncDirectionFull,true); because this function already added this index to main key. Compilation get error:
Key SyncIndex already exists on register SomeRegVc


I found that NewAutosyncRegister(kSyncDirectionFull,true); work in one way - from client to server if open one record and run Force Re-Sync from record menu. Only after this record uploaded to server side. Also I added RActions VcRecordSync and VcRecordShouldBeSynchronised to hal, but logs in this functions newer afected to hansa.log


After Force Re-sync to logs added next rows:

On client: 2022-12-19 22:14:23 PollSync took 1ms, record counts: 1 sent, 0 received, 0 updated, 0 equal, 0 ignored deletes, 0 without action since last message

On server: 2022-12-19 22:14:24 PollSync took 27ms, record counts: 0 sent, 1 received, 0 updated, 0 equal, 0 ignored deletes, 0 without action since last message
Leave Comment
You can subscribe to notifications for this post by selecting the 'star' icon on the top right corner of the post.
Back to the list
Latest Posts
David Delač
Hi Piotr, The log entry:
2024-12-14 08:40:43 0.000 CallHal(IsHansaWorldCustomer) appears because the server is running with the verbosity=debug-detailed setting in its parameters.txt file. Thi...
09:43 16 Dec 2024
Brittany McGrath
Hi Vaughn, I can confirm this has been fixed now and is live in Standard ERP 2024-11-20 Version: 85556786. Thank you. ...
10:04 10 Dec 2024