Solved

wcf on web application

Posted on 2011-03-12
3
260 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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

Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

Question has a verified solution.

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

Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.

627 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