Category "jax-rs"

How to return custom response on javax.json.bind.JsonbException (Helidon project)

I'm trying to return a custom http response(400 bad request) instead of http 500 server error when json payload is not valid. The problem is that when I use jav

How to specify custom streaming parser in eclipse microprofile restclient?

I need to consume a large payload ( hundreds of MB's) and am using eclipse microprofile restclient to make REST call, but I am not aware how I can specify my ow

java.lang.NoSuchMethodError: javax.ws.rs.core.Application.getProperties()Ljava/util/Map;

I am unable to find answer through the following links One Two Three Following is my pom.xml dependency <dependencies> <dependency>

How to set @PartFilename of Entity field in @POST RESTEasy client method in runtime?

I am trying to write Resteasy Client Class to make simple POST multipart/form-data request to upload file. So POST request must contain Content-Disposition: for

java.lang.ClassCastException: org.glassfish.jersey.jackson.internal.JacksonAutoDiscoverable cannot be cast to spi.AutoDiscoverable

I am new to implementing REST API services. I have tried the simple resources to implement. unfortunately I stuck with this exception. I have googled and tried

Setting User Principal in filter

I have an authentication filter that implements filter. by typcasting ServletRequest to HTTPServletRequest i can get the userPrincipal. public void doFilter(

RESTful API resource returns 404 when added @QueryParam

My resource worked fine till now. I added @QueryParam there. If I make request without writing query param to uri it works fine. After I write query param to th

JAX-RS jersey ExceptionMapper: How to know the method who threw the exception

Im using JAX-RS jersey ExceptionMapper, and I'm wondering if there is a way to know inside the method toResponse(), which method (from the API) threw the except

Custom HTTP Header blocks Jersey CORS Filter

I am using a Jersey2 response filter to deal with CORS requests from the browser. At this point it pretty much looks like the one from Paul Samsotha in this que

why does tomcat show 404 response message for an existing resource?

I'm new to implementing web services and I'm doing it with jax-rs API using eclipse IDE for java-ee developers 2022. I have written a simple web service that re

Serialize Java 8 Stream with Jersey

How can I serialize a Java 8 java.util.Stream<T> with Jersey. I tried to write a MessageBodyWriter, but I need to know how to compose (decorate) existing