forked from quarkus-qe/quarkus-test-suite
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This is cover age for quarkusio/quarkus#43440
- Loading branch information
Showing
3 changed files
with
54 additions
and
0 deletions.
There are no files selected for viewing
10 changes: 10 additions & 0 deletions
10
...dvanced-reactive/src/main/java/io/quarkus/ts/http/advanced/reactive/GreetingResource.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,18 @@ | ||
package io.quarkus.ts.http.advanced.reactive; | ||
|
||
import jakarta.enterprise.inject.spi.CDI; | ||
import jakarta.ws.rs.Path; | ||
|
||
public class GreetingResource extends GreetingAbstractResource { | ||
@Override | ||
public String hello() { | ||
return "Hello from Quarkus REST"; | ||
} | ||
|
||
@Path("/sub-resource") | ||
public GreetingSubResources helloFromSubResource() { | ||
return CDI.current() | ||
.select(GreetingSubResources.class) | ||
.get(); | ||
} | ||
} |
14 changes: 14 additions & 0 deletions
14
...ced-reactive/src/main/java/io/quarkus/ts/http/advanced/reactive/GreetingSubResources.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package io.quarkus.ts.http.advanced.reactive; | ||
|
||
import jakarta.enterprise.context.RequestScoped; | ||
import jakarta.ws.rs.GET; | ||
|
||
@RequestScoped | ||
public class GreetingSubResources { | ||
|
||
@GET | ||
public String get() { | ||
return "Greeting from sub-resource"; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters