Package org.apache.juddi.model

Examples of org.apache.juddi.model.UddiEntityPublisher


                EntityManager em = PersistenceManager.getEntityManager();
                EntityTransaction tx = em.getTransaction();
                try {
                        tx.begin();

                        UddiEntityPublisher publisher = this.getEntityPublisher(em, body.getAuthInfo());

                        new ValidatePublish(publisher).validateDeletePublisher(em, body);

                        List<String> entityKeyList = body.getPublisherId();
                        for (String entityKey : entityKeyList) {
View Full Code Here


                EntityManager em = PersistenceManager.getEntityManager();
                EntityTransaction tx = em.getTransaction();
                try {
                        tx.begin();

                        UddiEntityPublisher publisher = this.getEntityPublisher(em, body.getAuthInfo());

                        new ValidatePublish(publisher).validateAdminDeleteTModel(em, body);

                        List<String> entityKeyList = body.getTModelKey();
                        for (String entityKey : entityKeyList) {
View Full Code Here

                EntityManager em = PersistenceManager.getEntityManager();
                EntityTransaction tx = em.getTransaction();
                try {
                        tx.begin();

                        UddiEntityPublisher publisher = this.getEntityPublisher(em, body.getAuthInfo());

                        new ValidateClientSubscriptionInfo(publisher).validateDeleteClientSubscriptionInfo(em, body);

                        List<String> entityKeyList = body.getSubscriptionKey();
                        for (String entityKey : entityKeyList) {
View Full Code Here

                EntityManager em = PersistenceManager.getEntityManager();
                EntityTransaction tx = em.getTransaction();
                try {
                        tx.begin();

                        UddiEntityPublisher publisher = this.getEntityPublisher(em, body.getAuthInfo());

                        new ValidateClientSubscriptionInfo(publisher).validateSaveClientSubscriptionInfo(em, body);

                        ClientSubscriptionInfoDetail result = new ClientSubscriptionInfoDetail();
View Full Code Here

                EntityManager em = PersistenceManager.getEntityManager();
                EntityTransaction tx = em.getTransaction();
                try {
                        tx.begin();

                        UddiEntityPublisher publisher = this.getEntityPublisher(em, body.getAuthInfo());

                        new ValidateClerk(publisher).validateSaveClerk(em, body);

                        ClerkDetail result = new ClerkDetail();
View Full Code Here

                EntityManager em = PersistenceManager.getEntityManager();
                EntityTransaction tx = em.getTransaction();
                try {
                        tx.begin();

                        UddiEntityPublisher publisher = this.getEntityPublisher(em, body.getAuthInfo());

                        new ValidateNode(publisher).validateSaveNode(em, body);

                        NodeDetail result = new NodeDetail();
View Full Code Here

    EntityManager em = PersistenceManager.getEntityManager();
    EntityTransaction tx = em.getTransaction();
    try {
      tx.begin();
 
      UddiEntityPublisher publisher = this.getEntityPublisher(em, body.getAuthInfo());
     
      new ValidateCustodyTransfer(publisher).validateDiscardTransferToken(em, body);
 
      org.uddi.custody_v3.TransferToken apiTransferToken = body.getTransferToken();
      if (apiTransferToken != null) {
View Full Code Here

    EntityManager em = PersistenceManager.getEntityManager();
    EntityTransaction tx = em.getTransaction();
    try {
      tx.begin();
     
      UddiEntityPublisher publisher = this.getEntityPublisher(em, authInfo);
     
      new ValidateCustodyTransfer(publisher).validateGetTransferToken(em, keyBag);
 
      int transferExpirationDays = DEFAULT_TRANSFEREXPIRATION_DAYS;
      try {
View Full Code Here

    EntityManager em = PersistenceManager.getEntityManager();
    EntityTransaction tx = em.getTransaction();
    try {
      tx.begin();
     
      UddiEntityPublisher publisher = this.getEntityPublisher(em, body.getAuthInfo());
     
      new ValidateCustodyTransfer(publisher).validateTransferEntities(em, body);
 
      // Once validated, the ownership transfer is as simple as switching the publisher
      KeyBag keyBag = body.getKeyBag();
      List<String> keyList = keyBag.getKey();
      for (String key : keyList) {
        UddiEntity uddiEntity = em.find(UddiEntity.class, key);
        uddiEntity.setAuthorizedName(publisher.getAuthorizedName());
       
        if (uddiEntity instanceof BusinessEntity) {
          BusinessEntity be = (BusinessEntity)uddiEntity;
         
          List<BusinessService> bsList = be.getBusinessServices();
          for (BusinessService bs : bsList) {
            bs.setAuthorizedName(publisher.getAuthorizedName());
           
            List<BindingTemplate> btList = bs.getBindingTemplates();
            for (BindingTemplate bt : btList)
              bt.setAuthorizedName(publisher.getAuthorizedName());
          }
        }
      }
 
      // After transfer is finished, the token can be removed
View Full Code Here

                        logger.error("unexpected error caught looking up requestor's ip address", ex);
                    }
                   
                }
    Authenticator authenticator = AuthenticatorFactory.getAuthenticator();
    UddiEntityPublisher entityPublisher = authenticator.identify(authInfo, modelAuthToken.getAuthorizedName());
   
    // Must make sure the returned publisher has all the necessary fields filled
    if (entityPublisher == null) {
                    logger.warn("AUDIT FAILURE - Auth token invalided, publisher does not exist "+ getRequestorsIPAddress());
      throw new AuthTokenRequiredException(new ErrorMessage("errors.auth.AuthInvalid"));
                }
    if (entityPublisher.getAuthorizedName() == null){
                    logger.warn("AUDIT FAILURE - Auth token invalided, username does exist"+ getRequestorsIPAddress());
      throw new AuthTokenRequiredException(new ErrorMessage("errors.auth.AuthInvalid"));
                }
    // Auth token is being used.  Adjust appropriate values so that it's internal 'expiration clock' is reset.
    modelAuthToken.setLastUsed(new Date());
View Full Code Here

TOP

Related Classes of org.apache.juddi.model.UddiEntityPublisher

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.