Hi,
I'm trying to develop an application that uses CSLA.Net 3.5 and is using WCF for the application server. And, it doesn't help that I'm new to both.
The simple test that I have is to query 2,000 records from the database and show them in the grid. When I connect directly to the database from the client application, I get a very fast performance(under 1 second). But, when I connect to the WCF application server to retrieve the same data, it takes almost 9 seconds(and the application server and client application are both on the same machine). In the WCF app server, I'm testing with netTCPBinding, and I'm using read-only CSLA objects.
Any hints on how I can improve that performance. Especially considering that the application will have to connect via the internet. We are currently at the planning stage of the application and are wondering what would be the best approach, Winforms client application connecting to the server via the internet or having a ASP.Net client application.
Any hints and/or ideas are welcomed.
Daniel Rail
Assuming that the issue is WCF communication process, you can
try to modify settings for your binding to see if performance improves.
If you do not need security, turn it off. You can also increase buffer
size. I suspect though, you will not come even close to your 1 second
though, because there is an inherent overhead with WCF communications.
Here is an example:
<netTcpBinding>
<binding transferMode="Buffered" maxBufferSize="10000000" maxReceivedMessageSize="10000000" >
<security mode="None"/>
Sergey Barskiy
Principal Consultant
office: 678.405.0687 |
mobile: 404.388.1899
Microsoft Worldwide Partner of the Year | Custom
Development Solutions, Technical Innovation
From: danielrail
[mailto:cslanet@lhotka.net]
Sent: Wednesday, September 10, 2008 9:37 AM
To: Sergey Barskiy
Subject: [CSLA .NET] WCF Performance Question
Hi,
I'm trying to develop an application that uses CSLA.Net 3.5 and is using WCF
for the application server. And, it doesn't help that I'm new to
both.
The simple test that I have is to query 2,000 records from the database and
show them in the grid. When I connect directly to the database from the
client application, I get a very fast performance(under 1 second). But,
when I connect to the WCF application server to retrieve the same data, it
takes almost 9 seconds(and the application server and client application are
both on the same machine). In the WCF app server, I'm testing with
netTCPBinding, and I'm using read-only CSLA objects.
Any hints on how I can improve that performance. Especially
considering that the application will have to connect via the internet.
We are currently at the planning stage of the application and are wondering
what would be the best approach, Winforms client application connecting to the
server via the internet or having a ASP.Net client application.
Any hints and/or ideas are welcomed.
Daniel Rail
Thanks for the reply. But, I already have those kind of settings with improvement. I'm going to give SocketPro a try, their performance numbers seem promising. I'll know more when I have a chance to test it(hopefully within the next two days).
Daniel
As far as I know, you can control the message size in config
file without any issues.
Sergey Barskiy
Principal Consultant
office: 678.405.0687 |
mobile: 404.388.1899
Microsoft Worldwide Partner of the Year | Custom
Development Solutions, Technical Innovation
From: BillInPA
[mailto:cslanet@lhotka.net]
Sent: Wednesday, November 26, 2008 2:26 PM
To: Sergey Barskiy
Subject: Re: [CSLA .NET] RE: WCF Performance Question
Danial, how did you make out with SocketPro?
We are trying to use wcf, and are thinking we have to keep open to alternatives
As we got into it, the limitations in size of message are solveable only by
implementing alteernate bindings/channels/etc
IMO, this should have been basic functionality, not something the developer
would ever have to see
Copyright (c) Marimer LLC