Examples of Owner


Examples of org.jclouds.vcloud.director.v1_5.domain.Owner

               .httpRequestBuilder().build(),
            new VcloudHttpResponsePrimer()
               .xmlFilePayload("/media/owner.xml", VCloudDirectorMediaType.OWNER)
               .httpResponseBuilder().build());
     
      Owner expected = owner().toBuilder()
               .link(Link.builder()
                        .rel("up")
                        .type("application/vnd.vmware.vcloud.media+xml")
                        .href(URI.create("https://mycloud.greenhousedata.com/api/media/794eb334-754e-4917-b5a0-5df85cbd61d1"))
                        .build())
View Full Code Here

Examples of org.jclouds.vcloud.director.v1_5.domain.Owner

      Checks.checkMediaFor(MEDIA, media);
   }

   @Test(description = "GET /media/{id}/owner", dependsOnMethods = { "testGetMedia" })
   public void testGetMediaOwner() {
      Owner directOwner = mediaApi.getOwner(media.getId());
      assertEquals(owner.toBuilder().user(owner.getUser()).build(),
               directOwner.toBuilder().links(ImmutableSet.<Link> of()).build(), String.format(
                        GETTER_RETURNS_SAME_OBJ, "getOwner()", "owner", "media.getOwner()", owner.toString(),
                        directOwner.toString()));

      // parent type
      Checks.checkResource(directOwner);

      // required
      assertNotNull(directOwner.getUser(), String.format(OBJ_FIELD_REQ, "Owner", "user"));
      Checks.checkReferenceType(directOwner.getUser());
   }
View Full Code Here

Examples of org.jclouds.vcloud.director.v1_5.domain.Owner

      return task;
   }

   public static Owner getOwner() {
      Owner owner = Owner.builder()
            .build();

      return owner;
   }
View Full Code Here

Examples of org.jclouds.vcloud.director.v1_5.domain.Owner

      return task;
   }

   public static Owner getOwner() {
      Owner owner = Owner.builder()
            .build();

      return owner;
   }
View Full Code Here

Examples of org.jgroups.blocks.locking.Owner

            processQueue();
        }

        protected synchronized void handleView(List<Address> members) {
            if(current_owner != null && !members.contains(current_owner.getAddress())) {
                Owner tmp=current_owner;
                setOwner(null);
                if(log.isDebugEnabled())
                    log.debug("unlocked \"" + lock_name + "\" because owner " + tmp + " left");
            }

            for(Iterator<Request> it=queue.iterator(); it.hasNext();) {
                Request req=it.next();
                if(!members.contains(req.owner.getAddress()))
                    it.remove();
            }
           
            for(Iterator<Owner> it=condition.queue.iterator(); it.hasNext();) {
                Owner own=it.next();
                if(!members.contains(own.getAddress())) {
                    it.remove();
                }
            }

            processQueue();
View Full Code Here

Examples of org.jgroups.blocks.locking.Owner

        }

        protected void setOwner(Owner owner) {
            if(owner == null) {
                if(current_owner != null) {
                    Owner tmp=current_owner;
                    current_owner=null;
                    notifyUnlocked(lock_name, tmp);
                }
            }
            else {
View Full Code Here

Examples of org.jgroups.blocks.locking.Owner

                    log.trace("Signal for [" + lock.lock_name +
                        "] ignored since, no one is waiting in queue.");
                }
            }
           
            Owner entry;
            if (all) {
                while ((entry = queue.poll()) != null) {
                    notifyAwaited(lock.lock_name, entry);
                    if (log.isTraceEnabled()) {
                        log.trace("Signalled " + entry + " for " + lock.lock_name);
View Full Code Here

Examples of org.jgroups.blocks.locking.Owner

    protected ClientLock createLock(String lock_name) {
        return new ClientLock(lock_name);
    }

    protected Owner getOwner() {
        return new Owner(local_addr, Thread.currentThread().getId());
    }
View Full Code Here

Examples of org.jgroups.protocols.Executing.Owner

        assert task instanceof DistributedFuture : "The task wasn't a distributed future like we thought";
        assert callable == ((DistributedFuture<?>)task).getCallable() : "The inner callable wasn't the same";
       
        Queue<Owner> requests = protocol.getRequestsFromCoordinator();
        assert requests.size() == 1 : "There is no request in the coordinator queue - " + requests.size();
        Owner owner = requests.iterator().next();
        assert owner.getAddress().equals(c2.getAddress()) : "The request Address doesn't match";
        assert owner.getRequestId() == 0 : "We only had 1 request so it should be zero still";
    }
View Full Code Here

Examples of org.jgroups.util.Owner

       
        public void signal(boolean all) {
            if (queue.isEmpty())
                log.trace("Signal for [%s] ignored since, no one is waiting in queue", lock.lock_name);

            Owner entry;
            if (all) {
                while ((entry = queue.poll()) != null) {
                    notifyAwaited(lock.lock_name, entry);
                    log.trace("Signalled %s for %s", entry, lock.lock_name);
                    sendSignalResponse(entry, lock.lock_name);
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.