gnodet commented on code in PR #23194:
URL: https://github.com/apache/camel/pull/23194#discussion_r3235199096


##########
core/camel-api/src/main/java/org/apache/camel/ResolveEndpointFailedException.java:
##########
@@ -18,35 +18,33 @@
 
 import java.util.Objects;
 
-import org.jspecify.annotations.Nullable;
-
 import static org.apache.camel.util.URISupport.sanitizeUri;
 
 /**
  * A runtime exception thrown if an {@link Endpoint} cannot be resolved via URI
  */
 public class ResolveEndpointFailedException extends RuntimeCamelException {
 
-    private final @Nullable String uri;
+    private final String uri;
 
-    public ResolveEndpointFailedException(@Nullable String uri, Throwable 
cause) {
-        super("Failed to resolve endpoint: " + sanitizeUri(uri) + " due to: "
+    public ResolveEndpointFailedException(String uri, Throwable cause) {
+        super("Failed to resolve endpoint: " + 
sanitizeUri(Objects.requireNonNull(uri, "uri")) + " due to: "

Review Comment:
   If we could come up with a real value added message, that would be 
different, but here, we're just checking an argument, we don't have any 
information to provide.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to