Package org.apache.jorphan.util

Examples of org.apache.jorphan.util.JMeterError


            previousResult.addAssertionResult(ass);
            previousResult.setSuccessful(false);
        } catch (ParserConfigurationException e) {// Should not happen
            final String errrorMessage = "ParserConfigurationException while processing ("+getXPathQuery()+")";
            log.error(errrorMessage,e);
            throw new JMeterError(errrorMessage,e);
        } catch (SAXException e) {// Can happen for bad input document
            log.warn("SAXException while processing ("+getXPathQuery()+") "+e.getLocalizedMessage());
            addAssertionFailure(previousResult, e, false); // Should this also fail the sample?
        } catch (TransformerException e) {// Can happen for incorrect XPath expression
            log.warn("TransformerException while processing ("+getXPathQuery()+") "+e.getLocalizedMessage());
View Full Code Here


        try {
            r = m.invoke(bshInstance, o);
        } catch (IllegalArgumentException e) { // Programming error
            final String message = errorString + m.getName();
            log.error(message);
            throw new JMeterError(message, e);
        } catch (IllegalAccessException e) { // Also programming error
          final String message = errorString + m.getName();
            log.error(message);
            throw new JMeterError(message, e);
        } catch (InvocationTargetException e) { // Can occur at run-time
            // could be caused by the bsh Exceptions:
            // EvalError, ParseException or TargetError
          String message = errorString + m.getName();
            Throwable cause = e.getCause();
View Full Code Here

    log.debug("Sample occurred");
    try {
      listener.sampleOccurred(e);
    } catch (RemoteException err) {
      if (err.getCause() instanceof java.net.ConnectException){
        throw new JMeterError("Could not return sample",err);       
      }
      log.error("sampleOccurred", err);
    }
  }
View Full Code Here

      listClasses = ClassFinder.findClassesThatExtend(JMeterUtils.getSearchPaths(), new Class[] { Class
          .forName("org.apache.jmeter.gui.action.Command") });
      commands = new HashMap(listClasses.size());
      if (listClasses.size() == 0) {
        log.fatalError("!!!!!Uh-oh, didn't find any action handlers!!!!!");
        throw new JMeterError("No action handlers found - check JMeterHome and libraries");
      }
      iterClasses = listClasses.iterator();
      while (iterClasses.hasNext()) {
        String strClassName = (String) iterClasses.next();
                if (strClassName.startsWith("org.apache.jmeter.gui")) {
View Full Code Here

                    }
                }
            }
        } catch (IOException e) {
            log.fatalError("Bad saveservice properties file", e);
            throw new JMeterError("JMeter requires the saveservice properties file to continue");
        }
    }
View Full Code Here

                entry = i;
                break;
            }
        }
        if (entry == -1) {
            throw new JMeterError("Impossible state, data key not present in order: "+currentKey.getClass());
        }
        order.set(entry, newKey);
    }
View Full Code Here

    /** Get the nth variable value (zero-based) */
    public String getVarValue(int i){
        try {
            return values[i];
        } catch (ArrayIndexOutOfBoundsException e) {
            throw new JMeterError("Check the sample_variable settings!", e);
        }
    }
View Full Code Here

    Object r = null;
    try {
      r = m.invoke(bshInstance, new Object[] { s });
    } catch (IllegalArgumentException e) { // Programming error
      log.error("Error invoking bsh method " + m.getName() + "\n", e);
      throw new JMeterError("Error invoking bsh method " + m.getName(), e);
    } catch (IllegalAccessException e) { // Also programming error
      log.error("Error invoking bsh method " + m.getName() + "\n", e);
      throw new JMeterError("Error invoking bsh method " + m.getName(), e);
    } catch (InvocationTargetException e) { // Can occur at run-time
      // could be caused by the bsh Exceptions:
      // EvalError, ParseException or TargetError
      log.error("Error invoking bsh method " + m.getName() + "\n", e);
      throw new JMeterException("Error invoking bsh method " + m.getName(), e);
View Full Code Here

    Object r = null;
    try {
      r = m.invoke(bshInstance, new Object[] { s, o });
    } catch (IllegalArgumentException e) { // Programming error
      log.error("Error invoking bsh method " + m.getName() + "\n", e);
      throw new JMeterError("Error invoking bsh method " + m.getName(), e);
    } catch (IllegalAccessException e) { // Also programming error
      log.error("Error invoking bsh method " + m.getName() + "\n", e);
      throw new JMeterError("Error invoking bsh method " + m.getName(), e);
    } catch (InvocationTargetException e) { // Can occur at run-time
      // could be caused by the bsh Exceptions:
      // EvalError, ParseException or TargetError
      log.error("Error invoking bsh method " + m.getName() + "\n", e);
      throw new JMeterException("Error invoking bsh method " + m.getName(), e);
View Full Code Here

TOP

Related Classes of org.apache.jorphan.util.JMeterError

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.