Solved

WCF Memory Issue

Posted on 2013-11-22
4
77 Views
Last Modified: 2015-12-28
Hi Experts,

     I have a Windows Mobile application running on a Motorola mobile device (Windows Mobile 6.5, .NET Compact Framework 3.5).  The application communicates with a WCF web service (http binding, XML format, hosted in a windows service (on the server side that is)).

     What I am noticing is that, on the client side, every time I make a call to the web service, the application takes a chunk of the memory and it never releases it back to the app.  The amount of data transferred in each call doesn't seem to make a difference in how much "bite" is taken out of the memory.  Now, we're only talking about maybe 500 KB each time, but when dealing with a mobile device that only has 250 MB of memory in the first place and it limits the amount of available memory per application, you run out of memory rather quickly and you start getting OutOfMemoryExceptions in the oddest places.  I don't think that it's any other part of my application, because even if all I do is start the app and do nothing else but fire the same web service call over and over again (with virtually no data being passed in each call (other than WCF overhead)), eventually the application runs out of memory.

      Has anyone else seen this before?  If yes, what's going on and how do I fix it?

      This problem is making the application completely unusable; I am in desperate need of help!

Thanks in advance!!!!
0
Comment
Question by:axnst2
[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
4 Comments
 
LVL 96

Accepted Solution

by:
Bob Learned earned 250 total points
ID: 39671392
Have you used a profiler to investigate this issue?

If you have the Ultimate edition, that version comes with a profiler.
0
 
LVL 2

Assisted Solution

by:Pavel_Kudishin
Pavel_Kudishin earned 250 total points
ID: 39672779
Check that you release managed and not-managed resources after every call, close connection.
0
 

Author Comment

by:axnst2
ID: 39757490
This is not a memory issue caused by me.  What I'm trying to find out is if there are any built in WCF settings that would cache/ hold on to data until I tell it to clear it....or anything else like that...
0
 

Author Closing Comment

by:axnst2
ID: 41386715
The question has not really been resolved, but I want to clean this up.  Thanks for the attempt anyways!
0

Featured Post

Get free NFR key for Veeam Availability Suite 9.5

Veeam is happy to provide a free NFR license (1 year, 2 sockets) to all certified IT Pros. The license allows for the non-production use of Veeam Availability Suite v9.5 in your home lab, without any feature limitations. It works for both VMware and Hyper-V environments

Question has a verified solution.

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

IP addresses can be stored in a database in any of several ways.  These ways may vary based on the volume of the data.  I was dealing with quite a large amount of data for user authentication purpose, and needed a way to minimize the storage.   …
More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…

617 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