Skip to content

Commit

Permalink
RestClient Reactive: Support inheritance of sub resources
Browse files Browse the repository at this point in the history
Allow to use sub resources in client resources:

Usage for first level:
```java
@path("/path")
@RegisterRestClient(baseUri = "http://localhost:8081")
@consumes("text/plain")
@produces("text/plain")
public interface RootResource {

    @path("/sub")
    SubClient sub();
}
```

Second level:
```
@consumes("text/plain")
@produces("text/plain")
interface SubClient {
    @path("/sub")
    SubSubClient sub();
}
```

Third and N levels (this was unsupported and now it's supported):
```
@consumes("text/plain")
@produces("text/plain")
interface SubSubClient {
    @get
    @path("/simple")
    String simpleGet();
}
```

Fix #22055
  • Loading branch information
Sgitario committed Dec 20, 2021
1 parent d9f25a2 commit 62706f7
Show file tree
Hide file tree
Showing 3 changed files with 448 additions and 323 deletions.
Loading

0 comments on commit 62706f7

Please sign in to comment.