Spring Framework
  1. Spring Framework
  2. SPR-8569

Proposition of a annotation for testing performance oriented sql

    Details

    • Last commented by a User:
      true

      Description

      It would be nice if the Spring TestContext Framework provided support for performance tests oriented sql.
      It is well know that some ORM in the hands of novice developer can produce methods in dao that will generate against with real datas a lot of queries.

      Actually it is possible but it is done programmatically,(start, call Mydao, stop and count...) so a lot of copy/paste is done.

      This performance testing need is more a cross-cutting concern.
      It will even able to reuse previous tess done for example againts legacy database dumped from the production.

      The annotation will prevent the arise of thoses issues by limiting the numbers of jdbc queries made by a specific test and will help new developers to spot more quickly any performance degradation newly introduced.

      Proposed Annotation Names

      @MaxQueries

      Code Examples

      @MaxQueries(10)
      public void testFindPersonsByName() throws Exception{
      
      }
      

      @Test

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            Sam Brannen
            Reporter:
            omar elmandour
            Last updater:
            Chris Beams
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Days since last comment:
              2 years, 37 weeks, 6 days ago