Com makes my application slow

Results 1 to 6 of 6

Thread: Com makes my application slow

  1. #1
    Kevin Guest

    Default Com makes my application slow

    I just wasted a week of my life com enabling an asp application I had build a few months ago. I did this because I was having problems with performance. I basically made a few com objects to be the database accessors and then used asp to display the results. Well, after a week worth of work (and many, many, many reboots of IIS) I have finished my com development. To my surprise, the application runs twice as slow. Can anyone comment on this? Is com really slower than just straight asp? It doesn&#039t make sense...

  2. #2
    Richard A. Lowe Guest

    Default my take...

    Calling COM components for data access can have it&#039s purpose, but IMHO that purpose is not raw, one page access speed. COM data access just introduces another layer to the process, a process that is not helped by compilation. <BR><BR>Compiling a component is good for the following, IMO:<BR><BR>- speeding up certain computational logic (lot of if&#039s and calculations IIRC)<BR><BR>- lots of objects getting created and thrown around that may benefit from early binding.<BR><BR>- encapsulating logic/data to make it&#039s secure (if your app has a "secret sauce" in it&#039s business function here&#039s the place to put it)<BR><BR>- scaling an application by hosting components on an app server and using MTS / COM+<BR><BR>(And lots of other things I&#039ve neglected.)<BR><BR>Richard

  3. #3
    Kevin Guest

    Default RE: my take...

    Thanks Richard. It appears that adding any sort of extra objects to an Asp page just drags the performance down severely. I&#039m so happy we&#039re moving to J2EE.

  4. #4
    Join Date
    Dec 1969

    Default RE: my take...

    Since you are so happy to move to annother platform, maybe it doesn&#039t make a difference.<BR><BR>Just because you put something in a COM object, doesn&#039t make the whole site faster.<BR>Did you look at what was causing your perf problem? If all your com does is wrap the DB access and your performance issue is not related to DB access then yes your site might go a bit slower with 1 user.<BR>Also:COM won&#039t make your DB execute the queries any faster!<BR><BR>Maybe your COM obj is badly made... for example, how do you pass parameters ByVal/ByRef.Good asp is faster than bad COM.<BR><BR><BR>Stop rebooting - &#062; use MTS.<BR>Don&#039t assume the bottleneck, find it.<BR><BR><BR>

  5. #5
    Kevin Guest

    Default RE: my take...

    With MTS I don&#039t have to reboot IIS anymore?<BR><BR>My com basically just wraps the DB access, however I introduced a few extra objects to make my life easier:<BR><BR>For example, I made a project object to encapsulate all of the fields of my project table.<BR><BR>I think maybe adding an extra object or 2 may be a bottleneck.<BR><BR>Can you confirm that registering my components with MTS will make it run faster.<BR><BR>By the way, even though I am happy about moving to the J2EE platform, I still have to support asp applications. Part of supporting them is making them faster if people complain. Right now people are complaining big-time about the application I&#039m trying to improve.<BR><BR>

  6. #6
    Kevin Guest

    Default RE: my take...

    I pass in an array by reference so I can return an array of objects that basically consists of the recordset I got with my com object. Is this inefficient? If so, how can I make it better?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts