
Windev Magazine ((new)) May 2026
The challenge is not building the apps; it is . You cannot expose your on-premise HFSQL directly to the internet, and batch imports/exports are too slow for real-time inventory. 2. The Architecture: The "Reversé" Proxy Pattern Instead of the cloud pulling data from the premise (which requires opening firewall ports), we will use the premise pushing data to the cloud via secure REST APIs. We will also use HFSQL Native Replication for the read-only data.
// Download new cloud orders HTTPRequest("https://cloud.myapp.com/api/v1/pull?since=" + LastSyncDate) JsonArray = JSONParse(Request.Body) FOR EACH JsonElement OF JsonArray Local_CloudOrder.ID = JsonElement.ID IF HReadSeekFirst(Local_CloudOrder, ID, JsonElement.ID) = False THEN Local_CloudOrder = JsonElement HAdd(Local_CloudOrder) END END In hybrid sync, conflicts are inevitable. Do not use "Last write wins." windev magazine
// Return success ResponseWriteStatus(201, "OK") ResponseWriteJSON("{""result"": ""accepted""}") END What about data created on the Mobile app? You need a "Pull" mechanism. Use WebDev Scheduler to trigger a download. The challenge is not building the apps; it is
How to use HFSQL replication and WebDev services to keep your legacy desktop app in sync with a modern mobile portal. The Architecture: The "Reversé" Proxy Pattern Instead of
// Inside the "Save" button of an Order window HAdd(Outbox_Table, "TYPE", "ORDER_CREATED") HAdd(Outbox_Table, "PAYLOAD", JSONBuild(Order_Record)) HAdd(Outbox_Table, "STATUS", "PENDING") // Commit the local transaction immediately HTransactionEnd(Global_DB, hCommit)
This architecture respects the network boundaries: the cloud never touches your firewall, and the premise never blocks the user for network errors.