Solved

Midas application server block client access

Posted on 2003-10-25
7
340 Views
Last Modified: 2010-04-05
The app server remote datamodule threading model is MultiInstance / Apartment,
and I connect to SQL server using ADO.

When a client connect to the app server and call a time consuming database query interface, then other clients all blocked until the query finished.

I have tried to connect using DCOM connection and Socket connection, same thing happens.

It seems that all job are queued by midas app server, and the server services client access one by one.

Why this happens? How to solve?
0
Comment
Question by:qdyoung
  • 4
7 Comments
 
LVL 6

Accepted Solution

by:
swift99 earned 500 total points
ID: 9622450
Your server is running a single thread.  To gain parallelism, you need to split the communications thread from the database connectivity thread, and actually run several concurrent database connection threads.  For an enterprise scale service with a robust back end, 100 to 200 connections might be a good range to support.  For a WIntel based DBMS back end (MS SQL, Interbase, etc) I generally suggest one or two database threads per CPU.

For something a bit more robust for the communications piece, check out Midware from overbyte.delphicenter.com.  Midware allows you to separate the command logic from the database logic so that you can serve long requests in a separate thread.  The TWSocket communication component itself is non-blocking, so you can serve several thousand users concurrently from one communications thread.
0
 
LVL 6

Expert Comment

by:swift99
ID: 9622468
Allow one connection for every 50 users
0
 
LVL 6

Expert Comment

by:swift99
ID: 9622490
What is your back end DBMS - does it multithread?  if not, then you're in trouble.
0
 

Author Comment

by:qdyoung
ID: 9626687
My backend DBMS is Microsoft SQL Server 2000.

Any real parallelism solution for Delphi MIDAS?
0
 
LVL 6

Expert Comment

by:swift99
ID: 9628835
I use the MIDAS piece in briefcase model, and use direct API calls to the DB2 system here.  The MIDAS provider interface was not scalable enough for my purposes.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

820 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question