Trying to get a very basic extension working that adds a REST resource, but the endpoint doesn't show up. The resource:
@Path("/kwark")
public class KwarkResource {
@GET
public String hello() {
return "Hello kwark";
}
}
and the deployment processor:
@BuildStep
public FeatureBuildItem feature() {
return new FeatureBuildItem("kwark");
}
@BuildStep
public AdditionalBeanBuildItem additionalBeanBuildItem() {
return AdditionalBeanBuildItem.builder()
.addBeanClass(KwarkResource.class)
.setDefaultScope(DotNames.APPLICATION_SCOPED)
.setUnremovable()
.build();
}
Only when I add an empty beans.xml
to META-INF
the endpoint shows up, but that defeats the idea of the buildsteps. (right?)
What am I missing?
(full code here)