Results 1 to 4 of 4

Thread: How to read some strange results shown by Spring insight

  1. #1
    Join Date
    Aug 2008
    Location
    Lodz, Poland
    Posts
    47

    Default How to read some strange results shown by Spring insight

    I'm trying to analyze performance of our application using Insight on tc server dev. edition. The tool is great, and it helped me find some bottlenecks in the running app.
    However, some results shown by Insight are strange, and I don't know how to explain them.
    First example (see attachment insight-result-web-dispatch.png) - the request takes about 100ms, but the spring dispatcher servlet needs almost half of this time to dispatch the request to the actual controller. Normally this time is unnoticeable. So why in this request such trivial task takes so long? There are no other request at the same time. Maybe GC turned on at the same time? Or Spring Insight simply is wrong from time to time?
    The second example - rendering the response (see second screenshot). Our JsonResponse view renderer class is extremely simple - it takes a String with json data, and prints it to output stream, using code response.getWriter().write(json); In 95% of request it takes no time at all to run it (insight shows time 0ms). But from time to time it shows times like this: 150ms, 200ms. How can it be explained? Is it tcserver fault, that it renders it so slowly sometimes? Or again, Insight is wrong about timing?
    Attached Images Attached Images

  2. #2
    Join Date
    Oct 2009
    Posts
    55

    Default

    When rendering jumps in time, it is usually due to a garbage collection. Insight traces the entry and exits to a method call, so it isn't really possible for it to be 'wrong' about how long it took, but it doesn't help you identify the true problem either. We are looking to add Garbage Collection overlays into Insight in a coming release.

  3. #3
    Join Date
    Aug 2008
    Location
    Lodz, Poland
    Posts
    47

    Default

    Quote Originally Posted by jtravis View Post
    When rendering jumps in time, it is usually due to a garbage collection. Insight traces the entry and exits to a method call, so it isn't really possible for it to be 'wrong' about how long it took, but it doesn't help you identify the true problem either. We are looking to add Garbage Collection overlays into Insight in a coming release.
    Cool idea! It would be very helpful I think in such cases.
    BTW: I already solved the second problem from those two I described (slow response rendering) - it looks like the time includes sending response to client - when response was long, and there was no gzip enabled, the response time was long. After turning gzip on, I no longer observe such long rendering times.

  4. #4
    Join Date
    Feb 2008
    Location
    Nashua, NH
    Posts
    78

    Default

    You will probably also be happy to hear that the next release will contain support for javax.servlet.Filters. So those free floating SQL queries will have a nice home.
    Scott Andrews

    Software Engineer, Web Products Team
    SpringSource

Posting Permissions

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