Package javax.ws.rs

Examples of javax.ws.rs.ProcessingException


            || actualEx instanceof IOException
                && outMessage.getExchange().get("client.redirect.exception") != null) {
            if (actualEx instanceof ProcessingException) {
                throw ex;
            } else if (actualEx != null) {
                throw new ProcessingException(actualEx);
            } else if (!outMessage.getExchange().isOneWay() || cfg.isResponseExpectedForOneway()) {
                waitForResponseCode(outMessage.getExchange());
            }
        }
    }
View Full Code Here


                return;
            }
        }
       
        if (getResponseCode(exchange) == null) {
            throw new ProcessingException("Response timeout");
        }
    }
View Full Code Here

        return pValue.toString();
    }
   
    protected static void reportMessageHandlerProblem(String name, Class<?> cls, MediaType ct, Throwable cause) {
        String errorMessage = JAXRSUtils.logMessageHandlerProblem("NO_MSG_WRITER", cls, ct);
        throw new ProcessingException(errorMessage, cause);
    }
View Full Code Here

            }
        } catch (Exception ex) {
            Throwable t = ex instanceof WebApplicationException
                ? (WebApplicationException)ex
                : ex instanceof ProcessingException
                ? (ProcessingException)ex : new ProcessingException(ex);
            cb.handleException(message, t);
            return;
        }
        if (r == null) {
            try {
View Full Code Here

            }
        } catch (Exception ex) {
            throw ex instanceof WebApplicationException
                ? (WebApplicationException)ex
                : ex instanceof ProcessingException
                ? (ProcessingException)ex : new ProcessingException(ex);
        }
       
        Response response = null;
        Object entity = null;
        try {
View Full Code Here

            getState().setResponse(r);
            ((ResponseImpl)r).setOutMessage(outMessage);
            return r;
        } catch (Throwable ex) {
            throw (ex instanceof ProcessingException) ? (ProcessingException)ex
                                                  : new ProcessingException(ex);
        } finally {
            ClientProviderFactory.getInstance(outMessage).clearThreadLocalProxies();
        }
    }
View Full Code Here

            return secConfig.getSslContext();
        } else if (secConfig.getTlsClientParams().getTrustManagers() != null) {
            try {
                return SSLUtils.getSSLContext(secConfig.getTlsClientParams());
            } catch (Exception ex) {
                throw new ProcessingException(ex);
            }
        } else {
            return null;
        }
    }
View Full Code Here

        try {
            final ResolvedViewable resolvedViewable = resolve(viewable, template);
            if (resolvedViewable == null) {
                throw new WebApplicationException(
                        new ProcessingException(LocalizationMessages.TEMPLATE_NAME_COULD_NOT_BE_RESOLVED(viewable.getTemplateName())),
                        Response.Status.NOT_FOUND);
            }

            httpHeaders.putSingle(HttpHeaders.CONTENT_TYPE, resolvedViewable.getMediaType());
            resolvedViewable.writeTo(entityStream);
View Full Code Here

                if (monitoringStatisticsProcessor != null) {
                    try {
                        monitoringStatisticsProcessor.shutDown();
                    } catch (final InterruptedException e) {
                        Thread.currentThread().interrupt();
                        throw new ProcessingException(LocalizationMessages.ERROR_MONITORING_SHUTDOWN_INTERRUPTED(), e);
                    }
                }

                // onDestroy
                final List<MonitoringStatisticsListener> listeners = serviceLocator
View Full Code Here

                    processResponseCodeEvents();
                    processExceptionMapperEvents();
                } catch (final Throwable t) {
                    LOGGER.log(Level.SEVERE, LocalizationMessages.ERROR_MONITORING_STATISTICS_GENERATION(), t);
                    // rethrowing exception stops further task execution
                    throw new ProcessingException(LocalizationMessages.ERROR_MONITORING_STATISTICS_GENERATION(), t);
                }

                final MonitoringStatisticsImpl immutableStats = statisticsBuilder.build();

                final Iterator<MonitoringStatisticsListener> iterator = statisticsCallbackList.iterator();
View Full Code Here

TOP

Related Classes of javax.ws.rs.ProcessingException

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.