I have an existing application, let’s say for example called MyApp. It accepts requests through an API endpoint called “v1/myapp”.
The API signature is as follows:
@Path(/v1/myapp)
public interface myapp {
//methods inside
}
Now, there is a new V2 API, which is created to separate out some business logic based on the API that the client is using. Note that the API methods for the new API would not change. Only the underlying business logic will differ.
As a result new API signature is as follows to avoid any sort of code duplication:
@Path(v2/myapp)
public interface myappv2 extends myapp {}
Note that the underlying resource class implements both the interfaces.
However, when I try to reach the new API via an ingress, I get a 404.
The error message is :
RESTEASY003210: Could not find resource for full path:
The question therefore is:
- Is it possible to extend an existing API in this way or do we need to add the individual methods in the new API interface as well.?
- Are there any other configurations which I am missing?