Jump to content

How to make three tier system


surensiddhi

Recommended Posts

I am application software developer using Delphi since long time back from Delphi 5 to RAD Studio. My development includes Core Banking, Insurance, Accounting, POS, Inventory etc. All of them are thick client desktop application.

 

After going through the demo and forum, uniGUI looks great components and tools  for porting desktop application to web applications in Delphi as there are more demands from customer to change to web enabled application.

 

Now I would like to know following so that I can convert Banking and Insurance software to web enabled application using uniGUI:

 

1. How to make three tier system ? UI in uniGUI, Logic in DB Server using procedure and also in Application server. Looking for best practice to be followed.

 

2. It looks that MainModule is loaded in server for each session. If I place ClientDataset in MainModule where does it load ? I assume that it will be loaded in Server memory. I found it somewhere written, that dataset should be placed in form to load to client memory which means I am breaking multi tier rules and mixing UI and business logic. Is it possible to create datamodule which loads into client memory so that I can place all Clientdataset into that module for load balancing ?

Link to comment
Share on other sites

1. That's my exact approach. All logic is performed in stored procedures on server including verification of input parameters (user's input), UniGUI app is just an empty UI shell calling stored procs and catching returned exceptions to show error messages to the users, it doesn't have a single SQL request. Since UniGUI is stateful and you can't update your code without restarting it and thus interrupting work of all currently connected users, this is the best approach as it allows a lot of flexibility and seemless updating just by working with DB server.

 

2. "Client memory" doesn't exist in UniGUI, all sessions and data are stored in the server's memory and web browser is simply a canvas to display the current state like RDP. MainModule is per session (user), dynamically created when each user connects and destroyed when disconnects. ServerModule is a single instance created when you launch UniGUI app. Never put your data on ServerModule or you'll have concurrency issues.

  • Upvote 2
Link to comment
Share on other sites

Thanks Zilav.

 

If we have a method or solution to load lookup data into client memory from DB tables, we would be able reduce network traffic.

I though using Clientdataset as listsource of DBLookupCombobox, it can be achieved. 

 

My application is very big and my main objective is to achieve smooth operation for 300 to 700+ concurrent users per institutions.

 

So I want to have stacked architecture using uniGUI as far as possible so that it will make easy for multi device accesses with minimum changes.

 

Any suggestions are appreciated.

Link to comment
Share on other sites

Ive been using the UniGui demo so far, and like what im seeing.. I have my UniGui server talking to my middleware (KBMMW) and KBM talks to my firebird server. Most of my DB Queries/logic is in Stored procedures or KBM, Not in UniGui.

So far, works nice.

 

Gordon

Link to comment
Share on other sites

  • 4 years later...

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...