Desktop application split into server/client modules

520 views
Skip to first unread message

Ottó Trapp

unread,
Apr 7, 2017, 7:52:16 AM4/7/17
to Harbour Users
Hello,

I am a developer of a desktop application formerly written in Cl*pper now maintained and enhanced in Xb*se++. The program uses DBF/NTX files opened in SHARED mode from a Samba or Windows shared folder. This type of database access became slower and more cumbersome with almost every Win OS release. Also, the need to access the database remotely (from outside the LAN) can now only be fulfilled with the help of Win (or other) terminal services.

I'm thinking of converting the application into a server and a rich client component. The client part would remain the Xb*se++ application with the GUI already familiar with the users, and the server part with most business logic could be a Harbour program run on Linux/Windows/other OS.

My goal/expectation with this setup is:
- to have a database (first the same DBF files, later maybe sqlite or something else if needed) close/local to the program containing business logic, this way speed up data processing.
- to have a single running process (the server part) that has access to a local database, eliminating file access through SMB, thus to have a more robust solution that is more error prone to network intermissions.
- to enable the clients to connect also remotely (from outside the LAN) without the use of terminal solutions.
- to have the option to choose from various operating systems the server component can run on.
- to have a reliable solution.

My questions are:
- Are the above goals valid?
- Have you experience in setting up a similar client/server solution in Harbour?
- What kind of communication would you recommend between the server and client processes?
- Should the server be multi-threaded?
- Which (contrib) modules of Harbour should one consider to use?
- What disadvantages does such a set up have?

Thank you for any help, idea, advice.

Best Regards,
Otto

Daniele Campagna

unread,
Apr 7, 2017, 8:15:23 AM4/7/17
to harbou...@googlegroups.com

A web application? Server Linux (or Windows etc, any supported OS) , CGI (Common Gateway Interface) written in Harbour. Access from clients everywhere via a browser, any os, and a lan or wan.

Ehm, of course it's not a breeze if you are not familiar with HTML, Javascript, etc.

Maybe LetoDB or NETIO or Mediator or ADS are interesting alternatives to look into.

Dan

--
--
You received this message because you are subscribed to the Google
Groups "Harbour Users" group.
Unsubscribe: harbour-user...@googlegroups.com
Web: http://groups.google.com/group/harbour-users

---
You received this message because you are subscribed to the Google Groups "Harbour Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to harbour-user...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Ottó Trapp

unread,
Apr 14, 2017, 12:55:26 AM4/14/17
to Harbour Users

Thanks for the answer. In the first step I thought to retain the rich desktop client, and provide the user with the same GUI on the client side. I don't think the users would tolerate such a big change in user experience what switching to a browser would mean. Such a change would turn the application into a new product in my opinion, and I don't want that for the time being.

What if the server part is a Harbour http or websocket server that accepts connections and requests, processes them, reads and writes the database and replies with result sets, data, files, messages? Are there some already built blocks in Harbour to achieve that? I mean classes, functions that are already written to accomplish such communication between processes.

Thnaks.

Otto


Serge Girard

unread,
Apr 14, 2017, 3:21:11 AM4/14/17
to Harbour Users
Otto,

NETIO or MYSQL would be my first choice. How many users you are talking about and how many data?

Serge

Op vrijdag 14 april 2017 06:55:26 UTC+2 schreef Ottó Trapp:

Ottó Trapp

unread,
Apr 17, 2017, 6:05:41 AM4/17/17
to Harbour Users
Serge,

The maximum number of users is around 15-20 that work concurrently on the database. The database consists of 90 dbf tables. We have such installations at different sites.
It seems I should study NETIO. Could you enlist in a few sentences what NETIO is capable of?
I also see that there is a hbnetio executable in my Harbour bin directory. What is it? How can I supplement it with my own server side functions?

Thanks,
Otto

Ron Christie

unread,
Apr 18, 2017, 12:15:24 AM4/18/17
to Harbour Users
Hi Otto,

For what it's worth, I'd recommend using Rolf's fork of the Leto DBserver package called LetoDBf. It's stable and will give you the performance you need, I expect. Of course, a great deal depends on your coding style, but given your description of your application LetoDBf could be a drop-in replacement for the dbfntx driver. You'd probably want to change to dbfcdx while you're at it, but again, using LetoDBf it's pretty much transparent to the application.

I'm using LetoDBf in production and don't have any complaints. Rolf responds quickly to issues and has always been helpful to me.

Cheers,
Ron
Reply all
Reply to author
Forward
0 new messages