0

I have Vaadin v23.x on Quarkus application forked from: https://github.com/vaadin/base-starter-flow-quarkus/

I need to have a simple API endpoint as well

@Path("/hello")
public class GreetingResource {

  @GET
  @Produces(MediaType.TEXT_PLAIN)
  public String hello() {
    return "Hello from RESTEasy Reactive";
  }
}

Right now when I am loading http://localhost:8080/hello I am getting Vaadin error.

Error msg

Does someone know how to fix this?

ollitietavainen
  • 3,900
  • 13
  • 30
Mindaugas Jaraminas
  • 3,261
  • 2
  • 24
  • 37
  • Vaadin doesn't know the rest resoruces you have created, it just knows it's own routes. Maybe the last post here would help: https://github.com/quarkusio/quarkus/issues/14769 eg. set quarkus.resteasy.path or quarkus.resteasy-reactive.path to something not conflicting with Vaadin routes. – jon martin solaas Apr 13 '23 at 11:56

1 Answers1

0

To fix this problem configure quarkus.resteasy.path in application.propertie

For example: quarkus.resteasy.path=/api

And then API will be available at the URL: http://localhost:8080/api/hello

Mindaugas Jaraminas
  • 3,261
  • 2
  • 24
  • 37