Skip to content

Commit

Permalink
Improve error message when the client cannot be created.
Browse files Browse the repository at this point in the history
  • Loading branch information
metacosm committed Nov 30, 2023
1 parent 07ca9f7 commit 5e574ab
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,7 @@ public <T> T build(Class<T> aClass) throws IllegalStateException, RestClientDefi

ArcContainer arcContainer = Arc.container();
if (arcContainer == null) {
throw new IllegalStateException("The Reactive REST Client is not meant to be used outside of Quarkus");
throw new IllegalStateException("The Reactive REST Client needs to be built within the context of a Quarkus application with a valid ArC (CDI) context running.");
}

RestClientListeners.get().forEach(listener -> listener.onNewClient(aClass, this));
Expand Down

0 comments on commit 5e574ab

Please sign in to comment.