Examples of Retry


Examples of net.sourceforge.marathon.util.Retry

    protected void waitForWindowActive(Window window) {
        if (window == null)
            return;
        try {
            if (window instanceof Dialog || window instanceof Frame)
                new Retry(new ComponentNotFoundException("The window containing the component is not active", scriptModel,
                        windowMonitor), 1000, 60, new RetryWindowActive(window));
        } catch (TestException e) {
            e.captureScreen();
            throw e;
        }
View Full Code Here

Examples of net.sourceforge.marathon.util.Retry

    public void play(final ComponentFinder resolver) {
        if (keyStrokeText == null) {
            try {
                RuntimeException err = new ComponentNotFoundException("couldn't open menu " + menuItems, scriptModel, windowMonitor);
                new Retry(err, ComponentFinder.getRetryInterval(), ComponentFinder.getRetryCount(), new Retry.Attempt() {
                    public void perform() {
                        String[] items = menuItems.split("\\>\\>");
                        ArrayList<ComponentId> ids = new ArrayList<ComponentId>();
                        for (int i = 0; i < items.length; i++) {
                            String s = items[i];
View Full Code Here

Examples of net.sourceforge.marathon.util.Retry

    }

    private void getInstantiator(final Client client) {
        final Exception[] passback = new Exception[1];
        try {
            new Retry("looking up runtime instantiator", 600, 100, new Retry.Attempt() {
                public void perform() {
                    try {
                        instantiator = (IJavaRuntimeInstantiator) client.lookup(IJavaRuntimeInstantiator.class);
                        instantiator.setProperties(getProperties());
                        passback[0] = null;// clear the exception
View Full Code Here

Examples of net.sourceforge.marathon.util.Retry

        }
    }

    private int findMatchWithRetries(final String text) {
        try {
            new Retry("Search for combobox item", ComponentFinder.getRetryInterval(), ComponentFinder.getRetryCount(),
                    new Retry.Attempt() {
                        public void perform() {
                            if (findMatch(text) == -1)
                                retry();
                        }
View Full Code Here

Examples of net.sourceforge.marathon.util.Retry

        return createPropertyMapString(new String[] { "Path" });
    }

    private TreePath getTreePath() {
        try {
            new Retry("Search for cell component", ComponentFinder.getRetryInterval(), ComponentFinder.getRetryCount(),
                    new Retry.Attempt() {
                        public void perform() {
                            if (findTreePath(new StringBuffer()) == null)
                                retry();
                        }
View Full Code Here

Examples of org.apache.falcon.entity.v0.process.Retry

    @Override
    public void handleRerun(String cluster, String entityType, String entityName,
                            String nominalTime, String runId, String wfId, long msgReceivedTime) {
        try {
            Entity entity = getEntity(entityType, entityName);
            Retry retry = getRetry(entity);

            if (retry == null) {
                LOG.warn("Retry not configured for entity:" + entityType + "("
                        + entity.getName() + "), ignoring failed retries");
                return;
            }

            int attempts = retry.getAttempts();
            Frequency delay = retry.getDelay();
            PolicyType policy = retry.getPolicy();
            int intRunId = Integer.parseInt(runId);

            if (attempts > intRunId) {
                AbstractRerunPolicy rerunPolicy = RerunPolicyFactory.getRetryPolicy(policy);
                long delayTime = rerunPolicy.getDelay(delay, Integer.parseInt(runId));
View Full Code Here

Examples of org.apache.falcon.entity.v0.process.Retry

    //SUSPEND CHECKSTYLE CHECK ParameterNumberCheck
    public void handleRerun(String clusterName, String entityType, String entityName, String nominalTime,
                            String runId, String wfId, String workflowUser, long msgReceivedTime) {
        try {
            Entity entity = getEntity(entityType, entityName);
            Retry retry = getRetry(entity);

            if (retry == null) {
                LOG.warn("Retry not configured for entity:" + entityType + "("
                        + entity.getName() + "), ignoring failed retries");
                return;
            }

            int attempts = retry.getAttempts();
            Frequency delay = retry.getDelay();
            PolicyType policy = retry.getPolicy();
            int intRunId = Integer.parseInt(runId);

            if (attempts > intRunId) {
                AbstractRerunPolicy rerunPolicy = RerunPolicyFactory.getRetryPolicy(policy);
                long delayTime = rerunPolicy.getDelay(delay, Integer.parseInt(runId));
View Full Code Here

Examples of org.apache.ivory.entity.v0.process.Retry

      if (!RuntimeProperties.get()
          .getProperty("feed.retry.allowed", "true")
          .equalsIgnoreCase("true")) {
        return null;
      }
      Retry retry = new Retry();
      retry.setAttempts(Integer.parseInt(RuntimeProperties.get()
          .getProperty("feed.retry.attempts", "3")));
      retry.setDelay(new Frequency(RuntimeProperties.get().getProperty(
          "feed.retry.frequency", "minutes(5)")));
      retry.setPolicy(PolicyType.fromValue(RuntimeProperties.get()
          .getProperty("feed.retry.policy", "exp-backoff")));
      return retry;
    case PROCESS:
      Process process = (Process) entity;
      return process.getRetry();
View Full Code Here

Examples of org.apache.ivory.entity.v0.process.Retry

  public void handleRerun(String cluster, String entityType,
      String entityName, String nominalTime, String runId, String wfId,
      long msgReceivedTime) {
    try {
      Entity entity = getEntity(entityType, entityName);
      Retry retry = getRetry(entity);

      if (retry == null) {
        LOG.warn("Retry not configured for entity:" + entityType + "("
            + entity.getName() + "), ignoring failed retries");
        return;
      }

      int attempts = retry.getAttempts();
      Frequency delay = retry.getDelay();
      PolicyType policy = retry.getPolicy();
      int intRunId = Integer.parseInt(runId);

      if (attempts > intRunId) {
        AbstractRerunPolicy rerunPolicy = RerunPolicyFactory
            .getRetryPolicy(policy);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.