Package org.uddi.v3_service

Examples of org.uddi.v3_service.DispositionReportFaultMessage


      message.setSubject("UDDI Subscription Notification for subscription "
          + body.getSubscriptionResultsList().getSubscription().getSubscriptionKey());
      Transport.send(message);
     
    } catch (Exception e) {
      throw new DispositionReportFaultMessage(e.getMessage(), null);
    }
   
    DispositionReport dr = new DispositionReport();
    Result res = new Result();
    dr.getResult().add(res);
View Full Code Here


        public static boolean isExceptionExpiration(Exception ex) {
                if (ex == null) {
                        return false;
                }
                if (ex instanceof DispositionReportFaultMessage) {
                        DispositionReportFaultMessage f = (DispositionReportFaultMessage) ex;
                        if (f.getFaultInfo().countainsErrorCode(DispositionReport.E_AUTH_TOKEN_EXPIRED)
                             || ex.getMessage().contains(DispositionReport.E_AUTH_TOKEN_EXPIRED)
                             || ex.getMessage().toLowerCase().contains("expire")) {
                                return true;
                        }
                }
View Full Code Here

         * @param ex
         * @return string
         */
        private String HandleException(Exception ex) {
                if (ex instanceof DispositionReportFaultMessage) {
                        DispositionReportFaultMessage f = (DispositionReportFaultMessage) ex;
                        log.error(ex.getMessage() + (f.detail != null && f.detail.getMessage() != null ? StringEscapeUtils.escapeHtml(f.detail.getMessage()) : ""));
                        log.debug(ex.getMessage(), ex);
                        return ResourceLoader.GetResource(session, "errors.uddi") + " " + StringEscapeUtils.escapeHtml(ex.getMessage()) + " " + (f.detail != null && f.detail.getMessage() != null ? StringEscapeUtils.escapeHtml(f.detail.getMessage()) : "") + " " + ex.getClass().getCanonicalName();
                } else if (ex instanceof RemoteException) {
                        RemoteException f = (RemoteException) ex;
View Full Code Here

            + body.getSubscriptionResultsList().getSubscription().getSubscriptionKey());
        Transport.send(message);
      }
    } catch (Exception e) {
      log.error(e.getMessage(),e);
      throw new DispositionReportFaultMessage(e.getMessage(), null);
    }

    DispositionReport dr = new DispositionReport();
    Result res = new Result();
    dr.getResult().add(res);
View Full Code Here

                        throw new WebApplicationException(500);
                }
                log.error(ex.getMessage());
                log.debug(ex);
                if (ex instanceof DispositionReportFaultMessage) {
                        DispositionReportFaultMessage dr = (DispositionReportFaultMessage) ex;
                        if (dr.getFaultInfo() == null) {
                                throw new WebApplicationException(500);
                        }
                        if (dr.getFaultInfo().countainsErrorCode(UDDIErrorHelper.lookupErrCode(UDDIErrorHelper.E_AUTH_TOKEN_EXPIRED))) {
                                throw new WebApplicationException(ex, 401);
                        }
                        if (dr.getFaultInfo().countainsErrorCode(UDDIErrorHelper.lookupErrCode(UDDIErrorHelper.E_AUTH_TOKEN_REQUIRED))) {
                                throw new WebApplicationException(ex, 401);
                        }
                        if (dr.getFaultInfo().countainsErrorCode(UDDIErrorHelper.lookupErrCode(UDDIErrorHelper.E_FATAL_ERROR))) {
                                throw new WebApplicationException(ex, 500);
                        }
                }
                throw new WebApplicationException(ex, 400);
        }
View Full Code Here

            + body.getSubscriptionResultsList().getSubscription().getSubscriptionKey());
        Transport.send(message);
      }
    } catch (Exception e) {
      log.error(e.getMessage(),e);
      throw new DispositionReportFaultMessage(e.getMessage(), null);
    }
   
    DispositionReport dr = new DispositionReport();
    Result res = new Result();
    dr.getResult().add(res);
View Full Code Here

        public static DispositionReportFaultMessage MapException(DispositionReport ex) {
                org.uddi.api_v3.DispositionReport r = new org.uddi.api_v3.DispositionReport();
                r.setTruncated(ex.getFaultInfo().getTruncated() == Truncated.TRUE);
                r.getResult().addAll(MapResult(ex.getFaultInfo().getResult()));

                DispositionReportFaultMessage x = new DispositionReportFaultMessage(ex.getMessage(), r);
                return x;
        }
View Full Code Here

        public static DispositionReportFaultMessage MapException(SOAPFaultException ex) {
                org.uddi.api_v3.DispositionReport r = new org.uddi.api_v3.DispositionReport();
                r.setTruncated(false);
                r.getResult().addAll(MapFault(ex.getFault()));
                DispositionReportFaultMessage x = new DispositionReportFaultMessage(ex.getMessage(), r);
                return x;
        }
View Full Code Here

                r.setErrInfo(new ErrInfo());
                r.getErrInfo().setErrCode("E_invalidValue");
                r.getErrInfo().setValue("E_invalidValue");
               
                dispositionReport.getResult().add(r);
                throw new DispositionReportFaultMessage("error", dispositionReport);
        }
View Full Code Here

         * @param ex
         * @return
         */
        private String HandleException(Exception ex) {
                if (ex instanceof DispositionReportFaultMessage) {
                        DispositionReportFaultMessage f = (DispositionReportFaultMessage) ex;
                        log.error(ex.getMessage() + (f.detail != null && f.detail.getMessage() != null ? StringEscapeUtils.escapeHtml(f.detail.getMessage()) : ""));
                        log.debug(ex.getMessage(), ex);
                        return ResourceLoader.GetResource(session, "errors.uddi") + " " + StringEscapeUtils.escapeHtml(ex.getMessage()) + " " + (f.detail != null && f.detail.getMessage() != null ? StringEscapeUtils.escapeHtml(f.detail.getMessage()) : "");
                } else if (ex instanceof RemoteException) {
                        RemoteException f = (RemoteException) ex;
View Full Code Here

TOP

Related Classes of org.uddi.v3_service.DispositionReportFaultMessage

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.