Memory leak in RO SDK 6.0.55.957

Hello,

I have a server built with RO SDK 6.0.55.957 that runs on a Windows CE / .NET compact framework device. I have clients that run on Windows CE,Windows desktop PCs and JavaScript on tablet devices.

We are experiencing memory leaks when we are connected. I’m not certain if the problem is in RO SDK or in my server implementation. One thing that I do know is if I launch the client on my PC, make some requests, then close the client application the memory on the Windows CE server returns to what it was before I connected.

I have attempted to simulate this by creating the client channel, making some requests, then disposing of the client channel. Unfortunately the memory on the server side does go down a little bit but does not return to the original level. My open / close methods are below. Can you tell me if I am missing a step?

        private IpHttpClientChannel lClientChannel = null;
    private IDatabaseService lService;
    private BinMessage lMessage;

    public override void Close()
    {
        if (lMessage != null)
        {
            lMessage.Dispose();
        }

        if (lService != null)
        {
            lService = null;
        }

        if (lClientChannel != null)
        {
            lClientChannel.Dispose();

            lService = null;
            lClientChannel = null;
        }
    }

    public override void Open()
    {
        if (lClientChannel == null)
        {
            lClientChannel = new IpHttpClientChannel();
            lMessage = new BinMessage();

            lClientChannel.TargetUrl = string.Format("http://{0}:{1}/bin", Session.DataSource, Session.Port);
            //lClientChannel.TargetUrl = string.Format("http://{0}:{1}/soap", Session.DataSource, Session.Port);

            lService = CoDatabaseService.Create(lMessage, lClientChannel);
            //lService = CoDatabaseService.Create(new SoapMessage(), lClientChannel);
        }
    }

Hello

This is a quite old version. Memory consumption in .NET is a tricky thing. .NET application not necessarily frees the memory it doesn’t need anymore. Also some objects might be ‘dead’ but are still consuming memory until GC recycles them. Also one should be very careful if some objects are stored in the Session on the server side. These objects won’t be released until the session is destoyed.

The only advice here is to post your server app to desktop ,NET and tu run it under some memory profiler to pin down any possible leaking objects.