Package org.eclipse.test.internal.performance.db

Examples of org.eclipse.test.internal.performance.db.Variations


 
  /*
   * -Declipse.perf.config=<varname1>=<varval1>;<varname2>=<varval2>;...;<varnameN>=<varvalN>
   */
  public static Variations getVariations() {
      Variations keys= new Variations();
    String configKey= System.getProperty(ECLIPSE_PERF_CONFIG);
    if (configKey != null)
        keys.parsePairs(configKey);
      return keys;
  }
View Full Code Here


   * Returns null if assertAgainst property isn't defined.
   */
  public static Variations getAssertAgainst() {
    String assertKey= System.getProperty(ECLIPSE_PERF_ASSERTAGAINST);
    if (assertKey != null) {
        Variations keys= getVariations();
        if (keys == null)
            keys= new Variations();
        keys.parsePairs(assertKey);
        return keys;
    }
      return null;
  }
View Full Code Here

     
    if (fCheckers == null)
        return// nothing to do
   
    // get reference build tag
    Variations refKeys= PerformanceTestPlugin.getAssertAgainst();
    if (refKeys == null)
        return// nothing to do
   
      if (!(performanceMeter instanceof InternalPerformanceMeter))
          return// we cannot handle this.
     
        InternalPerformanceMeter ipm= (InternalPerformanceMeter) performanceMeter;
      Sample session= ipm.getSample();
    Assert.assertTrue("metering session is null", session != null); //$NON-NLS-1$
      String scenarioName= session.getScenarioID();
   
    // determine all dimensions we need
    HashSet allDimensions= new HashSet();
    for (int i= 0; i < fCheckers.length; i++) {
      AssertChecker chk= fCheckers[i];
      Dim[] dims= chk.getDimensions();
      for (int j= 0; j < dims.length; j++)
        allDimensions.add(dims[j]);
    }
   
    // get data for this session
    DataPoint[] sessionDatapoints;
    Variations config= PerformanceTestPlugin.getVariations();
    if (config != null)
        sessionDatapoints= DB.queryDataPoints(config, scenarioName, allDimensions);
    else
      sessionDatapoints= session.getDataPoints();
      if (sessionDatapoints == null || sessionDatapoints.length == 0) {
View Full Code Here

   * @param config
   * @param jvm
   */
  public static Variations getVariations(String buildIdPattern, String config, String jvm) {
    String buildIdPatterns = buildIdPattern.replace(',', '%');
    Variations variations = new Variations();
    variations.put(PerformanceTestPlugin.CONFIG, config);
    variations.put(PerformanceTestPlugin.BUILD, buildIdPatterns);
    variations.put("jvm", jvm);
    return variations;
  }
View Full Code Here

  /*
   * -Declipse.perf.config=<varname1>=<varval1>;<varname2>=<varval2>;...;<varnameN>=<varvalN>
   */
  public static Variations getVariations() {
      Variations keys= new Variations();
    String configKey= System.getProperty(ECLIPSE_PERF_CONFIG);
    if (configKey != null)
        keys.parsePairs(configKey);
      return keys;
  }
View Full Code Here

   * Returns null if assertAgainst property isn't defined.
   */
  public static Variations getAssertAgainst() {
    String assertKey= System.getProperty(ECLIPSE_PERF_ASSERTAGAINST);
    if (assertKey != null) {
        Variations keys= getVariations();
        if (keys == null)
            keys= new Variations();
        keys.parsePairs(assertKey);
        return keys;
    }
      return null;
  }
View Full Code Here

      if (fSummaryDimensions != null) {
        sample.tagAsSummary(fSummaryIsGlobal, fShortName, fSummaryDimensions, fCommentType, fComment);
      } else if (this.fComment != null) {
        sample.setComment(this.fCommentType, this.fComment);
      }
      Variations variations= PerformanceTestPlugin.getVariations();
      if (variations != null)
        DB.store(variations, sample);
      if (!DB.isActive() || System.getProperty(VERBOSE_PERFORMANCE_METER_PROPERTY) != null) {
        printSample(System.out, sample);
//        printSampleCSV(System.out, sample);
View Full Code Here

   * -Declipse.perf.dbloc=net://localhost
   */
  public static String getDBLocation() {
    String dbloc= System.getProperty(ECLIPSE_PERF_DBLOC);
    if (dbloc != null) {
        Variations keys= new Variations();
        keys.parsePairs(ECLIPSE_PERF_DBLOC + '=' + dbloc);
        return keys.getProperty(ECLIPSE_PERF_DBLOC);
    }
    return null;
  }
View Full Code Here

  }

  public static String getDBName() {
    String dbloc= System.getProperty(ECLIPSE_PERF_DBLOC);
    if (dbloc != null) {
        Variations keys= new Variations();
        keys.parsePairs(ECLIPSE_PERF_DBLOC + '=' + dbloc);
        return keys.getProperty(DB_NAME, DEFAULT_DB_NAME);
    }
      return DEFAULT_DB_NAME;
  }
View Full Code Here

  }

  public static String getDBUser() {
    String dbloc= System.getProperty(ECLIPSE_PERF_DBLOC);
    if (dbloc != null) {
        Variations keys= new Variations();
        keys.parsePairs(ECLIPSE_PERF_DBLOC + '=' + dbloc);
        return keys.getProperty(DB_USER, DEFAULT_DB_USER);
    }
      return DEFAULT_DB_USER;
  }
View Full Code Here

TOP

Related Classes of org.eclipse.test.internal.performance.db.Variations

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.