Solved

wcf on web application

Posted on 2011-03-12
3
255 Views
Last Modified: 2012-06-27
Hi

I have a generic handle .ashx page that will send request data via wcf to data server and then return data to the .ashx page.

As i try to design this .ashx page code behide. How can i avoid creating new connection to wcf server every time the .ashx page is requested?

Thanks,
0
Comment
Question by:JSW21
  • 2
3 Comments
 

Author Comment

by:JSW21
ID: 35116613
also may be my question was to ask - is it possible to have a web application that has a part that is running similar to a server application (which will not turn on and off when page requested/close).
0
 
LVL 18

Accepted Solution

by:
Gary Davis earned 500 total points
ID: 35118026
There is no reason to hold a connection from your web server to the WCF server. It just boils down to an HTTP request.

For your 2nd question, a web page can return a response to the user and continue to do processing. However, the browser will not be able to reconnect to that process since the response has been returned.

You can also fork off a thread for processing. Consider the context your prosess is running under.

You can do some tricks with cache to start up an asynchronous process periodically. What you do is stick an object (it doesn't matter what) into cache with an expiration time of when you want your process to run and set the cache expiration event to that process. The process should verify the reason it is being called if necessary (there are a few different reasons).

Gary
0
 

Author Closing Comment

by:JSW21
ID: 35455797
Many thanks
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

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

User art_snob (http://www.experts-exchange.com/M_6114203.html) encountered strange behavior of Android Web browser on his Mobile Web site. It took a while to find the true cause. It happens so, that the Android Web browser (at least up to OS ver. 2.…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

777 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