Examples of Reservation


Examples of org.globus.workspace.scheduler.Reservation

                    "co-scheduling group " + Lager.ensembleid(coschedid) +
                    " has no pending requests stored for it but done is" +
                    " being called?");
        }

        final Reservation res =
                this.slotManager.reserveCoscheduledSpace(reqs, coschedid);

        final String invalidResponse = "Implementation problem: slot " +
                "manager returned invalid response";

        if (res == null) {
            throw new ResourceRequestDeniedException(
                    invalidResponse + ": null response");
        }

        if (res.getResponseLength() == 0) {
           
            // Because reserveCoscheduledSpace should throw a request denied
            // exception if there was a problem asking for space, no node
            // assignments here we assume means best effort behavior is being
            // used. Check that assumption:

            if (!this.slotManager.isBestEffort()) {
                this.fatalityBackoutReservation(res);
                throw new ResourceRequestDeniedException(
                        invalidResponse + ": no address(es) but not a best " +
                                "effort manager");
            }
        }

        // If reserveCoscheduledSpace generated an exception we let it
        // fly and leave the option open to call done again, but from here
        // on it is now done for good.
        try {
            this.db.deleteNodeRequestsAndBeDone(coschedid);
        } catch (Throwable t) {
            String msg = "Problem removing node requests from co-scheduling " +
                    "tracking.  This is severe, should never happen.  " +
                    "Attempting backout of slot reservations, this will " +
                    "probably fail as well.  Problem: \"" + t.getMessage();

            logger.fatal(msg, t);

            final String fullResponse = msg + "\", Backout result: " +
                                  this.fatalityBackoutReservation(res);
            throw new WorkspaceDatabaseException(fullResponse);
        }

        if (!this.slotManager.isBestEffort()) {
           
            // NOTE: coscheduling creates a situation where otherwise
            // not-best-effort slot managers make the DefaultSchedulerAdapter
            // *appear* to the service as a best effort scheduler.  That is OK
            // and expected (because of the add, add, ..."done now" ensemble
            // mechanism).  But this in no way means that the particular slot
            // manager *plugin implementation* as plugin to the
            // DefaultSchedulerAdapter should behave any differently than we
            // expect it to.

            if (!res.hasDurationList()) {
                throw new ResourceRequestDeniedException(
                        invalidResponse + ": no durations");
            }

            final int len = res.getResponseLength();
            for (int i = 0; i < len; i++) {
                final IdHostnameTuple idhost = res.getIdHostnamePair(i);
                final Calendar start = Calendar.getInstance();
                final Calendar stop = Calendar.getInstance();
                stop.add(Calendar.SECOND, res.getDurationByIndex(i));

                try {
                    this.slotReserved(idhost.id,
                                      start,
                                      stop,
View Full Code Here

Examples of org.globus.workspace.scheduler.Reservation

            final String[] hostnames =
                    this.reserveSpace(vmids, req.getMemory(),
                                      req.getNeededAssociations(),
                                      req.getResourcePool(), preemptable);

            return new Reservation(vmids, hostnames);
        } finally {
            this.releaseWholeManagerLock();
        }
    }
View Full Code Here

Examples of org.globus.workspace.scheduler.Reservation

            all_ids[i] = ((Number)idInts.get(i)).intValue();
            all_hostnames[i] = (String)allHostnames.get(i);
            all_durations[i] = ((Integer)allDurations.get(i)).intValue();
        }

        return new Reservation(all_ids, all_hostnames, all_durations);
    }
View Full Code Here

Examples of org.globus.workspace.scheduler.Reservation

                          request.getCores(),
                          request.getDuration(),
                          request.getGroupid(),
                          request.getCreatorDN());

        return new Reservation(request.getIds());
    }
View Full Code Here

Examples of org.globus.workspace.scheduler.Reservation

        // Assume that the creator's DN is the same for each node
        final String creatorDN = requests[0].getCreatorDN();

        this.reserveSpace(all_ids, highestMemory, highestCores, highestDuration, coschedid, creatorDN);
        return new Reservation(all_ids, null, all_durations);
    }
View Full Code Here

Examples of pl.com.bottega.ecommerce.sales.domain.reservation.Reservation

  @Inject
  private SuggestionService suggestionService;

  // @Secured requires BUYER role
  public AggregateId createOrder() {
    Reservation reservation = reservationFactory.create(loadClient());
    reservationRepository.save(reservation);
    return reservation.getAggregateId();
  }
View Full Code Here

Examples of reserv.entity.Reservation

                p.setReservedPlace(true);       
                p.setReservation(reservationList.get(placesReserved.lastIndexOf(i)));
            }
            else
            {
                Reservation r = new Reservation();
                r.setPlace(i);
                p.setReservation(r);
            }
            placesList.add(p);
        }
        return placesList;
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.