Package feign.codec

Examples of feign.codec.DecodeException


                if (HYSTRIX_CLASSES.contains(rawType)) {
                    //Let the Hystrix Proxy wrap this
                    return read(response, actualType);
                }
            } else if (HYSTRIX_CLASSES.contains(type)) {
                throw new DecodeException("Return type "+type+" must be parameterized");
            }

            return read(response, type);

        } catch(RuntimeJsonMappingException e) {
View Full Code Here


    public Object decode(Response response, Type type) throws IOException, FeignException {
        try {
            Unmarshaller unmarshaller = jaxbContextFactory.createUnmarshaller((Class) type);
            return unmarshaller.unmarshal(response.body().asInputStream());
        } catch (JAXBException e) {
            throw new DecodeException(e.toString(), e);
        } finally {
            if(response.body() != null) {
                response.body().close();
            }
        }
View Full Code Here

      } finally {
        ensureClosed(inputStream);
      }
      return handler.result();
    } catch (SAXException e) {
      throw new DecodeException(e.getMessage(), e);
    }
  }
View Full Code Here

    try {
      return decoder.decode(response, metadata.returnType());
    } catch (FeignException e) {
      throw e;
    } catch (RuntimeException e) {
      throw new DecodeException(e.getMessage(), e);
    }
  }
View Full Code Here

TOP

Related Classes of feign.codec.DecodeException

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.