You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by or...@apache.org on 2022/06/17 10:31:57 UTC

[camel] 02/14: (chores) camel-aws-xray: document a deliberate case of unused method parameter

This is an automated email from the ASF dual-hosted git repository.

orpiske pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 9dc7d860059bd28b216ff10d6294daf41bffdf11
Author: Otavio Rodolfo Piske <an...@gmail.com>
AuthorDate: Fri Jun 17 09:58:56 2022 +0200

    (chores) camel-aws-xray: document a deliberate case of unused method parameter
---
 .../messaging/AbstractMessagingSegmentDecorator.java    | 17 +++++++++++++++--
 1 file changed, 15 insertions(+), 2 deletions(-)

diff --git a/components/camel-aws/camel-aws-xray/src/main/java/org/apache/camel/component/aws/xray/decorators/messaging/AbstractMessagingSegmentDecorator.java b/components/camel-aws/camel-aws-xray/src/main/java/org/apache/camel/component/aws/xray/decorators/messaging/AbstractMessagingSegmentDecorator.java
index d67a02f77d8..c998ab0c806 100644
--- a/components/camel-aws/camel-aws-xray/src/main/java/org/apache/camel/component/aws/xray/decorators/messaging/AbstractMessagingSegmentDecorator.java
+++ b/components/camel-aws/camel-aws-xray/src/main/java/org/apache/camel/component/aws/xray/decorators/messaging/AbstractMessagingSegmentDecorator.java
@@ -42,11 +42,24 @@ public abstract class AbstractMessagingSegmentDecorator extends AbstractSegmentD
         }
     }
 
-    protected String getDestination(Exchange exchange, Endpoint endpoint) {
+    /**
+     * Gets the (component-specific) destination
+     *
+     * @param  exchange the exchange to extract the destination info from
+     * @param  endpoint the endpoint being used
+     * @return          A String with the destination
+     */
+    protected String getDestination(@SuppressWarnings("unused") Exchange exchange, Endpoint endpoint) {
         return stripSchemeAndOptions(endpoint);
     }
 
-    protected String getMessageId(Exchange exchange) {
+    /**
+     * Gets the message ID from the exchange
+     *
+     * @param  exchange the exchange from which to extract the message ID
+     * @return          A String with the message ID or null if not applicable
+     */
+    protected String getMessageId(@SuppressWarnings("unused") Exchange exchange) {
         return null;
     }
 }