I have the following minimal Quarkus project example. Without the
Код: Выделить всё
quarkus-amazon-lambda-http
However when the
Код: Выделить всё
quarkus-amazon-lambda-http
Код: Выделить всё
pom.xml
When I run the project locally, the response code 200 OK is returned, but no body, and it just hangs trying to retrieve body indefinitely (tried through Postman, browser, curl).
I have tried with both reactive and non-reactive dependencies for the pom.xml and there is the same result with both. I have tried to use other versions of Quarkus also, such as 3.6.0.
Resource:
Код: Выделить всё
import jakarta.ws.rs.GET;
import jakarta.ws.rs.Path;
import jakarta.ws.rs.Produces;
import jakarta.ws.rs.core.MediaType;
@Path("/cars")
public class ExampleResource {
@GET
@Produces(MediaType.APPLICATION_JSON)
public List cars() {
List carList = new ArrayList();
//works if there are only 50 items in list
//without lambda dependency, works if there 10000+
for (int i = 0; i < 100; i++) {
carList.add(new Car(Long.valueOf(i), "Car(" + i + ")", Double.valueOf(i) * 100, Double.valueOf(i) + 100,
Double.valueOf(i), new Date(), new Date()));
}
return carList;
}
}
Код: Выделить всё
@Data
@AllArgsConstructor
public class Car {
private Long id;
private String name;
private Double weight;
private Double length;
private Double width;
private Date dateBuilt;
private Date dateAdded;
}
Код: Выделить всё
3.11.0
17
UTF-8
UTF-8
quarkus-bom
io.quarkus.platform
3.6.4
true
3.1.2
${quarkus.platform.group-id}
${quarkus.platform.artifact-id}
${quarkus.platform.version}
pom
import
io.quarkus
quarkus-arc
io.rest-assured
rest-assured
test
org.projectlombok
lombok
1.18.30
io.quarkus
quarkus-resteasy-reactive-jackson
io.quarkus
quarkus-resteasy-reactive-jsonb
io.quarkus
quarkus-amazon-lambda-http
Источник: https://stackoverflow.com/questions/777 ... dependency