Padarn Opennetcf RESTful Services

138 views Asked by At

Hi I'm evaluating Padarn for my project and I implemented a very simple RESTful example(POST & GET). I need Padarn for my WIN CE 5.0 or 6.0 web project and I bought a license. The RESTful service works well, but it's performance is not good enough. According to firebug results, every requests completed in 80ms (average) but after 10 requests it was completed in more than 120ms and its repetitive over (10~15) requests. How can I improve performance and decrease response time?

This is my web server config :

<WebServer DefaultPort="80" MaxConnections="256" DocumentRoot="\NANDFlash\Inetpub\" Logging="false" UseSsl="false" >
<DefaultDocuments>
  <Document>index.html</Document>
</DefaultDocuments>

<httpHandlers>
  <assembly>WebAgent.dll</assembly>
  <add verb="POST" path="/mngmt" type="WebAgent.ManagmentHandler,WebAgent"/>
  <add verb="GET" path="/notif" type="WebAgent.NotifHandler,WebAgent"/>
</httpHandlers>

<VirtualDirectories />
<Cookies />
<Caching />
</WebServer>

And this is my handler class :

namespace WebAgent
{
class ManagmentHandler : IHttpHandler
{
    public bool IsReusable
    {
        get { return true; }
    }

    public void ProcessRequest(HttpContext context)
    {
        context.Response.Write("OK");
        context.Response.Flush();
    }
}
}

I need to prepare response faster than 80ms. The firebug shows details of response time and it's a kind of "waiting time" that related to server side code(RESTful service).

I would appreciate it if you help me.

1

There are 1 answers

1
ctacke On

I'm not certain there is much that can be done to improve the speed over what you already have done. The path to handle this is pretty straightforward - Padarn is reusing an existing socket and reusing an existing handler class instance, so most of the time you see here is likely the time required to run the code (you've not said what sort of processor you're using) and to push the data out the network stack.

Licensed builds perform slightly faster because the license check isn't done after the first pass, but I don't think it would gain you a 50% speed.